LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_get_symbol
const char *
aiger_get_symbol (aiger * public, unsigned lit)
{
  IMPORT_private_FROM (public);
  aiger_symbol *symbol;
  aiger_type *type;
  unsigned var;

  assert (!aiger_error (public));

  assert (lit);
  assert (!aiger_sign (lit));

  var = aiger_lit2var (lit);
  assert (var <= public->maxvar);
  type = private->types + var;

  if (type->input)
    symbol = public->inputs;
  else if (type->latch)
    symbol = public->latches;
  else
    return 0;

  return symbol[type->idx].name;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
cmpq $0x0, 0xd0(%rdi)
jne 0x67d7
testl %esi, %esi
je 0x67f6
testb $0x1, %sil
jne 0x6815
shrl %esi
cmpl (%rdi), %esi
ja 0x6834
movq 0x70(%rdi), %rax
movl %esi, %ecx
movb (%rax,%rcx,8), %sil
movl $0x28, %edx
testb $0x1, %sil
jne 0x67c4
movl $0x30, %edx
testb $0x2, %sil
jne 0x67c4
xorl %eax, %eax
jmp 0x67d5
movq (%rdi,%rdx), %rdx
movl 0x4(%rax,%rcx,8), %eax
shlq $0x5, %rax
movq 0x18(%rdx,%rax), %rax
popq %rbp
retq
leaq 0x1b63(%rip), %rdi      # 0x8341
leaq 0x1b0e(%rip), %rsi      # 0x82f3
leaq 0x2101(%rip), %rcx      # 0x88ed
movl $0xa43, %edx            # imm = 0xA43
callq 0x10f0
leaq 0x1c2a(%rip), %rdi      # 0x8427
leaq 0x1aef(%rip), %rsi      # 0x82f3
leaq 0x20e2(%rip), %rcx      # 0x88ed
movl $0xa45, %edx            # imm = 0xA45
callq 0x10f0
leaq 0x1b75(%rip), %rdi      # 0x8391
leaq 0x1ad0(%rip), %rsi      # 0x82f3
leaq 0x20c3(%rip), %rcx      # 0x88ed
movl $0xa46, %edx            # imm = 0xA46
callq 0x10f0
leaq 0x20e6(%rip), %rdi      # 0x8921
leaq 0x1ab1(%rip), %rsi      # 0x82f3
leaq 0x20a4(%rip), %rcx      # 0x88ed
movl $0xa49, %edx            # imm = 0xA49
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_lit2tag
int
aiger_lit2tag (aiger * public, unsigned lit) 
{
  aiger_type * type;
  lit = aiger_strip (lit);
  if (!lit) return 0;
  type = aiger_lit2type (public, lit);
  if (type->input) return 1;
  if (type->latch) return 2;
  return 3;
}

// Assembly:
andl $-0x2, %esi
je 0x687a
pushq %rbp
movq %rsp, %rbp
callq 0x687d
movb (%rax), %cl
movl $0x1, %eax
testb $0x1, %cl
popq %rbp
jne 0x6879
andb $0x2, %cl
xorl %eax, %eax
cmpb $0x1, %cl
adcl $0x2, %eax
retq
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_lit2type
static aiger_type *
aiger_lit2type (aiger * public, unsigned lit)
{
  IMPORT_private_FROM (public);
  aiger_type *type;
  unsigned var;

  assert (!aiger_sign (lit));
  var = aiger_lit2var (lit);
  assert (var <= public->maxvar);
  type = private->types + var;

  return type;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
testb $0x1, %sil
jne 0x6899
shrl %esi
cmpl (%rdi), %esi
ja 0x68b8
movl %esi, %eax
shlq $0x3, %rax
addq 0x70(%rdi), %rax
popq %rbp
retq
leaq 0x1af1(%rip), %rdi      # 0x8391
leaq 0x1a4c(%rip), %rsi      # 0x82f3
leaq 0x2db8(%rip), %rcx      # 0x9666
movl $0xa5d, %edx            # imm = 0xA5D
callq 0x10f0
leaq 0x2062(%rip), %rdi      # 0x8921
leaq 0x1a2d(%rip), %rsi      # 0x82f3
leaq 0x2d99(%rip), %rcx      # 0x9666
movl $0xa5f, %edx            # imm = 0xA5F
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_is_input
aiger_symbol *
aiger_is_input (aiger * public, unsigned lit)
{
  aiger_type *type;
  aiger_symbol *res;

  assert (!aiger_error (public));
  type = aiger_lit2type (public, lit);
  if (!type->input)
    return 0;

  res = public->inputs + type->idx;

  return res;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
cmpq $0x0, 0xd0(%rdi)
jne 0x690a
movq %rdi, %rbx
callq 0x687d
testb $0x1, (%rax)
jne 0x68f8
xorl %eax, %eax
jmp 0x6903
movl 0x4(%rax), %eax
shlq $0x5, %rax
addq 0x28(%rbx), %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x1a30(%rip), %rdi      # 0x8341
leaq 0x19db(%rip), %rsi      # 0x82f3
leaq 0x2018(%rip), %rcx      # 0x8937
movl $0xa77, %edx            # imm = 0xA77
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_is_latch
aiger_symbol *
aiger_is_latch (aiger * public, unsigned lit)
{
  aiger_symbol *res;
  aiger_type *type;

  assert (!aiger_error (public));
  type = aiger_lit2type (public, lit);
  if (!type->latch)
    return 0;

  res = public->latches + type->idx;

  return res;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
cmpq $0x0, 0xd0(%rdi)
jne 0x695c
movq %rdi, %rbx
callq 0x687d
testb $0x2, (%rax)
jne 0x694a
xorl %eax, %eax
jmp 0x6955
movl 0x4(%rax), %eax
shlq $0x5, %rax
addq 0x30(%rbx), %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x19de(%rip), %rdi      # 0x8341
leaq 0x1989(%rip), %rsi      # 0x82f3
leaq 0x1ffa(%rip), %rcx      # 0x896b
movl $0xa87, %edx            # imm = 0xA87
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_is_and
aiger_and *
aiger_is_and (aiger * public, unsigned lit)
{
  aiger_type *type;
  aiger_and *res;

  assert (!aiger_error (public));
  type = aiger_lit2type (public, lit);
  if (!type->and)
    return 0;

  res = public->ands + type->idx;

  return res;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
cmpq $0x0, 0xd0(%rdi)
jne 0x69b2
movq %rdi, %rbx
callq 0x687d
testb $0x4, (%rax)
jne 0x699c
xorl %eax, %eax
jmp 0x69ab
movl 0x4(%rax), %eax
leaq (%rax,%rax,2), %rax
shlq $0x2, %rax
addq 0x60(%rbx), %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x1988(%rip), %rdi      # 0x8341
leaq 0x1933(%rip), %rsi      # 0x82f3
leaq 0x1fd8(%rip), %rcx      # 0x899f
movl $0xa97, %edx            # imm = 0xA97
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_literal_defined
static int
aiger_literal_defined (aiger_private * private, unsigned lit)
{
  unsigned var = aiger_lit2var (lit);
#ifndef NDEBUG
  EXPORT_public_FROM (private);
#endif
  aiger_type *type;

  assert (var <= public->maxvar);
  if (!var)
    return 1;

  type = private->types + var;

  return type->and || type->input || type->latch;
}

// Assembly:
movl %esi, %ecx
shrl %ecx
cmpl (%rdi), %ecx
ja 0x69f3
movl $0x1, %eax
cmpl $0x2, %esi
jb 0x69f2
movq 0x70(%rdi), %rdx
movl %ecx, %ecx
xorl %eax, %eax
testb $0x7, (%rdx,%rcx,8)
setne %al
retq
pushq %rbp
movq %rsp, %rbp
leaq 0x1f23(%rip), %rdi      # 0x8921
leaq 0x18ee(%rip), %rsi      # 0x82f3
leaq 0x205e(%rip), %rcx      # 0x8a6a
movl $0x27c, %edx            # imm = 0x27C
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_error_uu
static const char *
aiger_error_uu (aiger_private * private, const char *s, unsigned a,
		unsigned b)
{
  unsigned tmp_len, error_len;
  char *tmp;
  assert (!private->error);
  tmp_len = strlen (s) + sizeof (a) * 4 + sizeof (b) * 4 + 1;
  NEWN (tmp, tmp_len);
  sprintf (tmp, s, a, b);
  error_len = strlen (tmp) + 1;
  NEWN (private->error, error_len);
  memcpy (private->error, tmp, error_len);
  DELETEN (tmp, tmp_len);
  return private->error;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %ecx, -0x2c(%rbp)
cmpq $0x0, 0xd0(%rdi)
jne 0x6ae8
movl %edx, %r13d
movq %rsi, %r12
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x10b0
leal 0x21(%rax), %r14d
movq 0xb8(%rbx), %rdi
movq %r14, %rsi
callq *0xc0(%rbx)
movq %rax, %r15
movq %rax, %rdi
xorl %esi, %esi
movq %r14, %rdx
callq 0x1100
movq %r15, %rdi
movq %r12, %rsi
movl %r13d, %edx
movl -0x2c(%rbp), %ecx
xorl %eax, %eax
callq 0x1180
movq %r15, %rdi
callq 0x10b0
leal 0x1(%rax), %r12d
movq 0xb8(%rbx), %rdi
movq %r12, %rsi
callq *0xc0(%rbx)
movq %rax, 0xd0(%rbx)
movq %rax, %rdi
xorl %esi, %esi
movq %r12, %rdx
callq 0x1100
movq 0xd0(%rbx), %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x1140
movq 0xb8(%rbx), %rdi
movq %r15, %rsi
movq %r14, %rdx
callq *0xc8(%rbx)
movq 0xd0(%rbx), %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x1fb4(%rip), %rdi      # 0x8aa3
leaq 0x17fd(%rip), %rsi      # 0x82f3
leaq 0x1fb6(%rip), %rcx      # 0x8ab3
movl $0x250, %edx            # imm = 0x250
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_error_u
static const char *
aiger_error_u (aiger_private * private, const char *s, unsigned u)
{
  unsigned tmp_len, error_len;
  char *tmp;
  assert (!private->error);
  tmp_len = strlen (s) + sizeof (u) * 4 + 1;
  NEWN (tmp, tmp_len);
  sprintf (tmp, s, u);
  error_len = strlen (tmp) + 1;
  NEWN (private->error, error_len);
  memcpy (private->error, tmp, error_len);
  DELETEN (tmp, tmp_len);
  return private->error;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
cmpq $0x0, 0xd0(%rdi)
jne 0x6bd3
movl %edx, %r12d
movq %rsi, %r13
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x10b0
leal 0x11(%rax), %r14d
movq 0xb8(%rbx), %rdi
movq %r14, %rsi
callq *0xc0(%rbx)
movq %rax, %r15
movq %rax, %rdi
xorl %esi, %esi
movq %r14, %rdx
callq 0x1100
movq %r15, %rdi
movq %r13, %rsi
movl %r12d, %edx
xorl %eax, %eax
callq 0x1180
movq %r15, %rdi
callq 0x10b0
leal 0x1(%rax), %r12d
movq 0xb8(%rbx), %rdi
movq %r12, %rsi
callq *0xc0(%rbx)
movq %rax, 0xd0(%rbx)
movq %rax, %rdi
xorl %esi, %esi
movq %r12, %rdx
callq 0x1100
movq 0xd0(%rbx), %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x1140
movq 0xb8(%rbx), %rdi
movq %r15, %rsi
movq %r14, %rdx
callq *0xc8(%rbx)
movq 0xd0(%rbx), %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x1ec9(%rip), %rdi      # 0x8aa3
leaq 0x1712(%rip), %rsi      # 0x82f3
leaq 0x1f35(%rip), %rcx      # 0x8b1d
movl $0x23f, %edx            # imm = 0x23F
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_check_right_hand_side_defined
static void
aiger_check_right_hand_side_defined (aiger_private * private, aiger_and * and,
				     unsigned rhs)
{
  if (private->error)
    return;

  assert (and);
  if (!aiger_literal_defined (private, rhs))
    aiger_error_uu (private, "literal %u in AND %u undefined", rhs, and->lhs);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
cmpq $0x0, 0xd0(%rdi)
jne 0x6c1e
movq %rsi, %r15
testq %rsi, %rsi
je 0x6c47
movl %edx, %ebx
movq %rdi, %r14
movl %edx, %esi
callq 0x69d1
testl %eax, %eax
je 0x6c29
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movl (%r15), %ecx
leaq 0x1fda(%rip), %rsi      # 0x8c0d
movq %r14, %rdi
movl %ebx, %edx
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x6a16
leaq 0x1776(%rip), %rdi      # 0x83c4
leaq 0x169e(%rip), %rsi      # 0x82f3
leaq 0x1f5c(%rip), %rcx      # 0x8bb8
movl $0x2a6, %edx            # imm = 0x2A6
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_write_symbols_aux
static int
aiger_write_symbols_aux (aiger * public,
			 void *state, aiger_put put,
			 const char *type,
			 aiger_symbol * symbols, unsigned size)
{
  unsigned i;

  for (i = 0; i < size; i++)
    {
      if (!symbols[i].name)
	continue;

      assert (symbols[i].name[0]);

      if (aiger_put_s (state, put, type) == EOF ||
	  aiger_put_u (state, put, i) == EOF ||
	  put (' ', state) == EOF ||
	  aiger_put_s (state, put, symbols[i].name) == EOF ||
	  put ('\n', state) == EOF)
	return 0;
    }

  return 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, -0x30(%rbp)
testl %r8d, %r8d
je 0x6d76
movq %rsi, %r15
movq %rdi, %r12
movl %r8d, %edx
xorl %r14d, %r14d
movq %rcx, -0x38(%rbp)
movq %rdx, -0x40(%rbp)
movq %r14, %r13
shlq $0x5, %r13
movq 0x18(%rcx,%r13), %rax
testq %rax, %rax
je 0x6d6a
cmpb $0x0, (%rax)
je 0x6d8e
movq -0x30(%rbp), %rbx
movb (%rbx), %al
testb %al, %al
je 0x6ce0
movq -0x30(%rbp), %rbx
movsbl %al, %edi
movq %r12, %rsi
callq *%r15
cmpl $-0x1, %eax
je 0x6d7d
movb 0x1(%rbx), %al
incq %rbx
testb %al, %al
jne 0x6cc4
subl -0x30(%rbp), %ebx
xorl %eax, %eax
cmpl $-0x1, %ebx
je 0x6d7f
movq %r12, %rdi
movq %r15, %rsi
movl %r14d, %edx
callq 0x6dad
cmpl $-0x1, %eax
je 0x6d7d
movl $0x20, %edi
movq %r12, %rsi
callq *%r15
cmpl $-0x1, %eax
je 0x6d7d
movq -0x38(%rbp), %rax
addq %r13, %rax
addq $0x18, %rax
movq (%rax), %r13
movb (%r13), %al
movq %r13, %rbx
testb %al, %al
je 0x6d45
movq %r13, %rbx
movsbl %al, %edi
movq %r12, %rsi
callq *%r15
cmpl $-0x1, %eax
je 0x6d7d
movb 0x1(%rbx), %al
incq %rbx
testb %al, %al
jne 0x6d2d
subl %r13d, %ebx
cmpl $-0x1, %ebx
je 0x6d7d
movl $0xa, %edi
movq %r12, %rsi
callq *%r15
cmpl $-0x1, %eax
movq -0x38(%rbp), %rcx
movq -0x40(%rbp), %rdx
movl $0x0, %eax
je 0x6d7f
incq %r14
cmpq %rdx, %r14
jne 0x6c98
movl $0x1, %eax
jmp 0x6d7f
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x1f33(%rip), %rdi      # 0x8cc8
leaq 0x1557(%rip), %rsi      # 0x82f3
leaq 0x1f38(%rip), %rcx      # 0x8cdb
movl $0x498, %edx            # imm = 0x498
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_next_ch
static int
aiger_next_ch (aiger_reader * reader)
{
  int res;

  res = reader->get (reader->state);

  if (isspace (reader->ch) && !isspace (res))
    reader->lineno_at_last_token_start = reader->lineno;

  reader->ch = res;

  if (reader->done_with_reading_header && reader->looks_like_aag)
    {
      if (!isspace (res) && !isdigit (res) && res != EOF)
	reader->looks_like_aag = 0;
    }

  if (res == '\n')
    reader->lineno++;

  if (res != EOF)
    reader->charno++;

  return res;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rdi
callq *0x8(%rbx)
movl %eax, %r14d
callq 0x11b0
movq (%rax), %rax
movslq 0x10(%rbx), %rcx
testb $0x20, 0x1(%rax,%rcx,2)
je 0x747f
movslq %r14d, %rcx
testb $0x20, 0x1(%rax,%rcx,2)
jne 0x747f
movl 0x14(%rbx), %ecx
movl %ecx, 0x1c(%rbx)
movl %r14d, 0x10(%rbx)
cmpl $0x0, 0x20(%rbx)
je 0x74b8
cmpl $0x0, 0x24(%rbx)
je 0x74b8
movslq %r14d, %rcx
movzwl (%rax,%rcx,2), %eax
btl $0xd, %eax
jb 0x74b8
btl $0xb, %eax
setae %al
cmpl $-0x1, %r14d
setne %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x74b8
movl $0x0, 0x24(%rbx)
cmpl $-0x1, %r14d
je 0x74ca
cmpl $0xa, %r14d
jne 0x74c7
incl 0x14(%rbx)
incl 0x18(%rbx)
movl %r14d, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_already_defined
static const char *
aiger_already_defined (aiger * public, aiger_reader * reader, unsigned lit)
{
  IMPORT_private_FROM (public);
  aiger_type *type;
  unsigned var;

  assert (lit);
  assert (!aiger_sign (lit));

  var = aiger_lit2var (lit);

  if (public->maxvar < var)
    return 0;

  type = private->types + var;

  if (type->input)
    return aiger_error_uu (private,
			   "line %u: literal %u already defined as input",
			   reader->lineno_at_last_token_start, lit);

  if (type->latch)
    return aiger_error_uu (private,
			   "line %u: literal %u already defined as latch",
			   reader->lineno_at_last_token_start, lit);

  if (type->and)
    return aiger_error_uu (private,
			   "line %u: literal %u already defined as AND",
			   reader->lineno_at_last_token_start, lit);
  return 0;
}

// Assembly:
movl %edx, %ecx
testb $0x1, %cl
jne 0x7684
movl %ecx, %eax
shrl %eax
cmpl %eax, (%rdi)
jae 0x764b
xorl %eax, %eax
retq
movq 0x70(%rdi), %rdx
movl %eax, %eax
movb (%rdx,%rax,8), %al
testb $0x1, %al
jne 0x7669
testb $0x2, %al
jne 0x7672
testb $0x4, %al
je 0x7648
leaq 0x1cf3(%rip), %rax      # 0x935a
jmp 0x7679
leaq 0x1c90(%rip), %rax      # 0x9300
jmp 0x7679
leaq 0x1cb4(%rip), %rax      # 0x932d
movl 0x1c(%rsi), %edx
movq %rax, %rsi
jmp 0x6a16
pushq %rbp
movq %rsp, %rbp
leaq 0xd02(%rip), %rdi       # 0x8391
leaq 0xc5d(%rip), %rsi       # 0x82f3
leaq 0x1c1a(%rip), %rcx      # 0x92b7
movl $0x7c4, %edx            # imm = 0x7C4
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_read_delta
static const char *
aiger_read_delta (aiger_private * private, aiger_reader * reader,
		  unsigned *res_ptr)
{
  unsigned res, i, charno;
  unsigned char ch;

  if (reader->ch == EOF)
  UNEXPECTED_EOF:
    return aiger_error_u (private,
			  "character %u: unexpected end of file",
			  reader->charno);
  i = 0;
  res = 0;
  ch = reader->ch;

  charno = reader->charno;

  while ((ch & 0x80))
    {
      assert (sizeof (unsigned) == 4);

      if (i == 5)
      INVALID_CODE:
	return aiger_error_u (private, "character %u: invalid code", charno);

      res |= (ch & 0x7f) << (7 * i++);
      aiger_next_ch (reader);
      if (reader->ch == EOF)
	goto UNEXPECTED_EOF;

      ch = reader->ch;
    }

  if (i == 5 && ch >= 8)
    goto INVALID_CODE;

  res |= ch << (7 * i);
  *res_ptr = res;

  aiger_next_ch (reader);

  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, -0x40(%rbp)
movq %rsi, %rbx
movq %rdi, -0x38(%rbp)
movl 0x10(%rsi), %r15d
cmpl $-0x1, %r15d
je 0x7744
movl 0x18(%rbx), %eax
movl %eax, -0x2c(%rbp)
xorl %r12d, %r12d
testb %r15b, %r15b
js 0x76e3
movl %r15d, %eax
xorl %r14d, %r14d
jmp 0x7720
xorl %r13d, %r13d
xorl %r14d, %r14d
xorl %r12d, %r12d
cmpl $-0x5, %r14d
je 0x7734
movq %rbx, %rdi
callq 0x7449
movl 0x10(%rbx), %eax
cmpl $-0x1, %eax
je 0x7744
andl $0x7f, %r15d
movl %r13d, %ecx
shll %cl, %r15d
orl %r15d, %r12d
decl %r14d
addl $0x7, %r13d
movl %eax, %r15d
testb %al, %al
js 0x76ec
negl %r14d
movzbl %al, %eax
cmpl $0x5, %r14d
sete %cl
cmpl $0x8, %eax
setae %dl
testb %dl, %cl
je 0x7765
leaq 0x1cb9(%rip), %rsi      # 0x93f4
movq -0x38(%rbp), %rdi
movl -0x2c(%rbp), %edx
jmp 0x7752
movl 0x18(%rbx), %edx
leaq 0x1c81(%rip), %rsi      # 0x93cf
movq -0x38(%rbp), %rdi
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x6b07
leal (,%r14,8), %ecx
subl %r14d, %ecx
shll %cl, %eax
orl %r12d, %eax
movq -0x40(%rbp), %rcx
movl %eax, (%rcx)
movq %rbx, %rdi
callq 0x7449
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_error_usu
static const char *
aiger_error_usu (aiger_private * private,
		 const char *s, unsigned a, const char *t, unsigned b)
{
  unsigned tmp_len, error_len;
  char *tmp;
  assert (!private->error);
  tmp_len = strlen (s) + strlen (t) + sizeof (a) * 4 + sizeof (b) * 4 + 1;
  NEWN (tmp, tmp_len);
  sprintf (tmp, s, a, t, b);
  error_len = strlen (tmp) + 1;
  NEWN (private->error, error_len);
  memcpy (private->error, tmp, error_len);
  DELETEN (tmp, tmp_len);
  return private->error;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r8d, -0x30(%rbp)
movl %edx, -0x2c(%rbp)
cmpq $0x0, 0xd0(%rdi)
jne 0x787c
movq %rcx, %r13
movq %rsi, %r12
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x10b0
movq %rax, %r14
movq %r13, %rdi
callq 0x10b0
addl %eax, %r14d
addl $0x21, %r14d
movq 0xb8(%rbx), %rdi
movq %r14, %rsi
callq *0xc0(%rbx)
movq %rax, %r15
movq %rax, %rdi
xorl %esi, %esi
movq %r14, %rdx
callq 0x1100
movq %r15, %rdi
movq %r12, %rsi
movl -0x2c(%rbp), %edx
movq %r13, %rcx
movl -0x30(%rbp), %r8d
xorl %eax, %eax
callq 0x1180
movq %r15, %rdi
callq 0x10b0
leal 0x1(%rax), %r12d
movq 0xb8(%rbx), %rdi
movq %r12, %rsi
callq *0xc0(%rbx)
movq %rax, 0xd0(%rbx)
movq %rax, %rdi
xorl %esi, %esi
movq %r12, %rdx
callq 0x1100
movq 0xd0(%rbx), %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x1140
movq 0xb8(%rbx), %rdi
movq %r15, %rsi
movq %r14, %rdx
callq *0xc8(%rbx)
movq 0xd0(%rbx), %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x1220(%rip), %rdi      # 0x8aa3
leaq 0xa69(%rip), %rsi       # 0x82f3
leaq 0x1d29(%rip), %rcx      # 0x95ba
movl $0x261, %edx            # imm = 0x261
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O1/yurrriq[P]knrc/src/wc.c
// Function: char_count
double char_count()
{
    double nc = 0;

    while (getchar() != EOF)
        ++nc;

    return nc;
}

// Assembly:
pushq %rax
callq 0x1040
xorpd %xmm0, %xmm0
cmpl $-0x1, %eax
je 0x1174
addsd 0xea5(%rip), %xmm0      # 0x2008
movsd %xmm0, (%rsp)
callq 0x1040
movsd (%rsp), %xmm0
jmp 0x1156
popq %rax
retq
// File: /workspace/github_c_makefile_star2_O1/yurrriq[P]knrc/src/wc.c
// Function: ws_count
double ws_count()
{
    double ns = 0;
    int c = 0;

    while ((c = getchar()) != EOF)
        if (is_whitespace(c))
            ++ns;

    return ns;
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
xorpd %xmm0, %xmm0
movsd %xmm0, 0x8(%rsp)
movb $0x1, %bl
callq 0x1040
leal -0x9(%rax), %ecx
cmpl $0x2, %ecx
jb 0x11da
cmpl $0x20, %eax
movsd 0x8(%rsp), %xmm0
je 0x11e0
cmpl $-0x1, %eax
je 0x11fc
xorl %ebx, %ebx
jmp 0x11e0
movsd 0x8(%rsp), %xmm0
movapd %xmm0, %xmm1
addsd 0xe1c(%rip), %xmm1      # 0x2008
testb %bl, %bl
jne 0x11f4
movapd %xmm0, %xmm1
movsd %xmm1, 0x8(%rsp)
jmp 0x11b7
addq $0x10, %rsp
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/yurrriq[P]knrc/src/wc.c
// Function: main
int main()
{
    int c, nl, nw, nc, state;

    state = OUT;
    nl = nw = nc = 0;
    while ((c = getchar()) != EOF) {
        ++nc;
        if (c == '\n')
            ++nl;
        if (c == ' ' || c == '\n' || c == '\t')
            state = OUT;
        else if (state == OUT) {
            state = IN;
            ++nw;
        }
    }

    printf("%7d%8d%8d\n", nl, nw, nc);

    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
callq 0x1040
cmpl $-0x1, %eax
je 0x1262
xorl %r12d, %r12d
movabsq $0x100000600, %r15      # imm = 0x100000600
xorl %ebx, %ebx
xorl %ebp, %ebp
xorl %r14d, %r14d
xorl %ecx, %ecx
cmpl $0xa, %eax
sete %dl
cmpl $0x20, %eax
ja 0x1242
movl %eax, %eax
btq %rax, %r15
jae 0x1242
xorl %r12d, %r12d
jmp 0x124f
cmpl $0x1, %r12d
adcl $0x0, %ebp
movl $0x1, %r12d
movb %dl, %cl
addl %ecx, %r14d
callq 0x1040
incl %ebx
cmpl $-0x1, %eax
jne 0x1228
jmp 0x1269
xorl %r14d, %r14d
xorl %ebp, %ebp
xorl %ebx, %ebx
leaq 0xda0(%rip), %rdi       # 0x2010
movl %r14d, %esi
movl %ebp, %edx
movl %ebx, %ecx
xorl %eax, %eax
callq 0x1030
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/diaxen[P]fft-garden/ct_dit_dr.c
// Function: ct_fft_dr
static inline void
ct_fft_dr(const complex double * restrict in,
           complex double * restrict out,
           int s, int log2_N)
{
  unsigned l = 1 << (log2_N - s - 1);
  unsigned stride = 1 << s;

  switch (l)
    {
    case 1:                     /* size 2 base case  */
      ct_dit_bf2_0(1, stride, out, in);
      break;

    default:
      ct_fft_dr(in, out, s + 1, log2_N);
      ct_fft_dr(in + stride, out + l, s + 1, log2_N);

      for (unsigned k = 0; k < l; k++)
        ct_dit_bf2(l, out + k, get_twiddle(k << s, log2_N));
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %ecx, %ebp
movl %edx, %r14d
movq %rsi, %rbx
movl %edx, %eax
notl %eax
movl $0x1, %r15d
movl %r14d, %ecx
shll %cl, %r15d
movl $0x1, %r12d
shlq $0x4, %r15
addq %rdi, %r15
addl %ebp, %eax
je 0x1b64
movl %eax, %ecx
shll %cl, %r12d
leal 0x1(%r14), %edx
movl %edx, 0x8(%rsp)
movq %rbx, %rsi
movl %ebp, %ecx
callq 0x1a1e
movq %r12, %r13
shlq $0x4, %r13
leaq (%rbx,%r13), %rsi
movq %r15, %rdi
movl 0x8(%rsp), %edx
movl %ebp, %ecx
callq 0x1a1e
xorl %r15d, %r15d
leaq 0x25ed(%rip), %rbp      # 0x4080
movl %r15d, %eax
movl %r14d, %ecx
shll %cl, %eax
movq (%rbp), %rcx
shlq $0x4, %rax
movsd (%rcx,%rax), %xmm2
movsd 0x8(%rcx,%rax), %xmm3
movsd (%rbx), %xmm7
movsd 0x8(%rbx), %xmm8
movsd (%rbx,%r13), %xmm4
movsd 0x8(%rbx,%r13), %xmm5
movapd %xmm2, %xmm0
mulsd %xmm4, %xmm0
movapd %xmm3, %xmm1
mulsd %xmm5, %xmm1
subsd %xmm1, %xmm0
movapd %xmm3, %xmm6
mulsd %xmm4, %xmm6
movapd %xmm2, %xmm1
mulsd %xmm5, %xmm1
addsd %xmm6, %xmm1
ucomisd %xmm0, %xmm0
jp 0x1b35
movapd %xmm7, %xmm2
addsd %xmm0, %xmm2
movapd %xmm8, %xmm3
addsd %xmm1, %xmm3
movsd %xmm2, (%rbx)
movsd %xmm3, 0x8(%rbx)
subsd %xmm0, %xmm7
subsd %xmm1, %xmm8
movsd %xmm7, (%rbx,%r13)
movsd %xmm8, 0x8(%rbx,%r13)
incq %r15
addq $0x10, %rbx
cmpq %r15, %r12
jne 0x1a93
jmp 0x1ba3
ucomisd %xmm1, %xmm1
jnp 0x1af3
movapd %xmm4, %xmm0
movapd %xmm5, %xmm1
movsd %xmm7, 0x8(%rsp)
movsd %xmm8, 0x10(%rsp)
callq 0x1bd0
movsd 0x10(%rsp), %xmm8
movsd 0x8(%rsp), %xmm7
jmp 0x1af3
movsd (%rdi), %xmm0
movsd 0x8(%rdi), %xmm1
movsd (%r15), %xmm2
movsd 0x8(%r15), %xmm3
movapd %xmm0, %xmm4
addsd %xmm2, %xmm4
movapd %xmm1, %xmm5
addsd %xmm3, %xmm5
movsd %xmm4, (%rbx)
movsd %xmm5, 0x8(%rbx)
subsd %xmm2, %xmm0
subsd %xmm3, %xmm1
movsd %xmm0, 0x10(%rbx)
movsd %xmm1, 0x18(%rbx)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_5/exercise_5_13/tail.c
// Function: main
int main(int argc, char *argv[])
{
  if (!is_arg_list_valid(argc, argv))
  {
    puts("Error: invalid arguments.\n");
    return EXIT_FAILURE;
  }

  size_t nr_of_lines_to_print = DEFAULT_NR_OF_LINES_TO_PRINT;

  if (argc == 2)
  {
    nr_of_lines_to_print = atoi(argv[argc - 1] + 1);
  }

  size_t total_nr_of_lines;
  char *line_ptr[MAX_NR_OF_LINES];

  if ((total_nr_of_lines = read_lines(line_ptr, MAX_NR_OF_LINES)) != -1)
  {
    write_lines(line_ptr, nr_of_lines_to_print, total_nr_of_lines);
  }
  else
  {
    puts("Error: input too large.\n");
    return EXIT_FAILURE;
  }

  return EXIT_SUCCESS;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x9c48, %rsp           # imm = 0x9C48
cmpl $0x2, %edi
jle 0x11ae
leaq 0xe62(%rip), %rdi       # 0x2004
callq 0x1040
movl $0x1, %eax
jmp 0x1200
movl $0xa, %r14d
jne 0x11dd
movq %rsi, %rbx
movq 0x8(%rsi), %rdi
cmpb $0x2d, (%rdi)
jne 0x119b
incq %rdi
callq 0x13a0
testl %eax, %eax
je 0x119b
movq 0x8(%rbx), %rdi
incq %rdi
callq 0x1060
movslq %eax, %r14
movq %rsp, %rdi
movl $0x1388, %esi           # imm = 0x1388
callq 0x123c
cmpq $-0x1, %rax
je 0x120b
movq %rsp, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x1330
xorl %eax, %eax
addq $0x9c48, %rsp           # imm = 0x9C48
popq %rbx
popq %r14
retq
leaq 0xe0d(%rip), %rdi       # 0x201f
jmp 0x11a2
// File: /workspace/github_c_makefile_star2_O1/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_5/exercise_5_13/tail.c
// Function: write_lines
void write_lines(char *line_ptr[], const size_t nr_of_lines_to_print, const size_t total_nr_of_lines)
{
  size_t start_pos = 0;

  if (total_nr_of_lines >= nr_of_lines_to_print)
  {
    start_pos = total_nr_of_lines - nr_of_lines_to_print;
  }

  for (size_t i = start_pos; i < total_nr_of_lines; ++i)
  {
    puts(line_ptr[i]);
    afree(line_ptr[i]);
  }
}

// Assembly:
xorl %eax, %eax
movq %rdx, %rcx
subq %rsi, %rcx
cmovaeq %rcx, %rax
cmpq %rdx, %rax
jae 0x139f
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
cmpq %rsi, %rdx
cmovbq %rdx, %rbx
negq %rbx
leaq (%rdi,%rdx,8), %r14
leaq 0x2d0f(%rip), %r15      # 0x4070
leaq 0x2710(%r15), %r12
movq (%r14,%rbx,8), %rdi
callq 0x1040
movq (%r14,%rbx,8), %rax
cmpq %r15, %rax
setae %cl
cmpq %r12, %rax
setb %dl
andb %cl, %dl
cmpb $0x1, %dl
jne 0x138f
movq %rax, 0x2cc9(%rip)      # 0x4058
incq %rbx
jne 0x1368
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/asford[P]tmalign/./basic_fun.h
// Function: dist(double*, double*)
double dist(double x[3], double y[3])
{
	double d1=x[0]-y[0];
	double d2=x[1]-y[1];
	double d3=x[2]-y[2];	
 
    return (d1*d1 + d2*d2 + d3*d3);
}

// Assembly:
movsd (%rdi), %xmm1
subsd (%rsi), %xmm1
mulsd %xmm1, %xmm1
movupd 0x8(%rdi), %xmm0
movupd 0x8(%rsi), %xmm2
subpd %xmm2, %xmm0
mulpd %xmm0, %xmm0
addsd %xmm0, %xmm1
unpckhpd %xmm0, %xmm0            # xmm0 = xmm0[1,1]
addsd %xmm1, %xmm0
retq
// File: /workspace/github_c_makefile_star2_O1/asford[P]tmalign/./basic_fun.h
// Function: output_align1(int*, int)
void output_align1(int *invmap0, int len)
{
	for(int i=0; i<len; i++)
	{
		if(invmap0[i]>=0)
		{
			cout << invmap0[i]+1 << " ";
		}			
		else
			cout << invmap0[i] << " ";

	}	
	cout << endl << endl;	
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
testl %esi, %esi
jle 0x405a25
movq %rdi, %rbx
movl %esi, %r12d
xorl %r13d, %r13d
movq $0x605d20, %r14         # imm = 0x605D20
leaq 0x17f71f(%rip), %r15    # 0x585117
movl (%rbx,%r13,4), %eax
movl %eax, %esi
notl %esi
shrl $0x1f, %esi
addl %eax, %esi
movq %r14, %rdi
callq 0x4766b0
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x475de0
incq %r13
cmpq %r13, %r12
jne 0x4059f8
movq $0x605d20, %rbx         # imm = 0x605D20
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x456f30
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4758e0
movq %rax, %rdi
callq 0x474eb0
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x456f30
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4758e0
movq %rax, %rdi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x474eb0
// File: /workspace/github_c_makefile_star2_O1/asford[P]tmalign/./basic_fun.h
// Function: output_align(int*, int)
int output_align(int *invmap0, int len)
{
	int n_ali=0;
	for(int i=0; i<len; i++)
	{		
		cout <<  invmap0[i] << " ";
		n_ali++;		
	}	
	cout << endl << endl;	

	return n_ali;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testl %esi, %esi
jle 0x405ad3
movl %esi, %ebx
movq %rdi, %r14
movl %esi, %r13d
xorl %ebp, %ebp
movq $0x605d20, %r15         # imm = 0x605D20
leaq 0x17f66a(%rip), %r12    # 0x585117
movl (%r14,%rbp,4), %esi
movq %r15, %rdi
callq 0x4766b0
movl $0x1, %edx
movq %rax, %rdi
movq %r12, %rsi
callq 0x475de0
incq %rbp
cmpq %rbp, %r13
jne 0x405aad
jmp 0x405ad5
xorl %ebx, %ebx
movq $0x605d20, %r14         # imm = 0x605D20
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x456f30
movsbl %al, %esi
movq %r14, %rdi
callq 0x4758e0
movq %rax, %rdi
callq 0x474eb0
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x456f30
movsbl %al, %esi
movq %r14, %rdi
callq 0x4758e0
movq %rax, %rdi
callq 0x474eb0
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/asford[P]tmalign/./TMalign.h
// Function: free_memory()
void free_memory()
{
	DeleteArray(&path, xlen+1);
	DeleteArray(&val, xlen+1);
	DeleteArray(&score, xlen+1);
	DeleteArray(&xa, xlen);
	DeleteArray(&xt, xlen);
	DeleteArray(&ya, ylen);
	DeleteArray(&r1, minlen);
	DeleteArray(&r2, minlen);
	DeleteArray(&xtm, minlen);
	DeleteArray(&ytm, minlen);
    
    
    delete [] seqx;
    delete [] seqy;
    delete [] secx;
    delete [] secy;
    delete [] xresno;
    delete [] yresno;
    
}

// Assembly:
pushq %rax
movl 0x1fb2fb(%rip), %esi    # 0x6025b0
incl %esi
leaq 0x1fb2e2(%rip), %rdi    # 0x6025a0
callq 0x40c189
movl 0x1fb2e7(%rip), %esi    # 0x6025b0
incl %esi
leaq 0x1fb2d6(%rip), %rdi    # 0x6025a8
callq 0x40c1db
movl 0x1fb2d3(%rip), %esi    # 0x6025b0
incl %esi
leaq 0x1fb2b2(%rip), %rdi    # 0x602598
callq 0x40c1db
movl 0x1fb2bf(%rip), %esi    # 0x6025b0
leaq 0x1fb2c8(%rip), %rdi    # 0x6025c0
callq 0x40c1db
movl 0x1fb2ad(%rip), %esi    # 0x6025b0
leaq 0x1fb2e6(%rip), %rdi    # 0x6025f0
callq 0x40c1db
movl 0x1fb29f(%rip), %esi    # 0x6025b4
leaq 0x1fb2ac(%rip), %rdi    # 0x6025c8
callq 0x40c1db
movl 0x1fb291(%rip), %esi    # 0x6025b8
leaq 0x1fb2ea(%rip), %rdi    # 0x602618
callq 0x40c1db
movl 0x1fb27f(%rip), %esi    # 0x6025b8
leaq 0x1fb2e0(%rip), %rdi    # 0x602620
callq 0x40c1db
movl 0x1fb26d(%rip), %esi    # 0x6025b8
leaq 0x1fb28e(%rip), %rdi    # 0x6025e0
callq 0x40c1db
movl 0x1fb25b(%rip), %esi    # 0x6025b8
leaq 0x1fb284(%rip), %rdi    # 0x6025e8
callq 0x40c1db
movq 0x1fb288(%rip), %rdi    # 0x6025f8
testq %rdi, %rdi
je 0x40737a
callq 0x40c360
movq 0x1fb27f(%rip), %rdi    # 0x602600
testq %rdi, %rdi
je 0x40738b
callq 0x40c360
movq 0x1fb276(%rip), %rdi    # 0x602608
testq %rdi, %rdi
je 0x40739c
callq 0x40c360
movq 0x1fb26d(%rip), %rdi    # 0x602610
testq %rdi, %rdi
je 0x4073ad
callq 0x40c360
movq 0x1fb21c(%rip), %rdi    # 0x6025d0
testq %rdi, %rdi
je 0x4073be
callq 0x40c360
movq 0x1fb213(%rip), %rdi    # 0x6025d8
testq %rdi, %rdi
je 0x4073d0
popq %rax
jmp 0x40c360
popq %rax
retq
// File: /workspace/github_c_makefile_star2_O1/asford[P]tmalign/./TMalign.h
// Function: score_fun8(double**, double**, int, double, int*, double*, int)
int score_fun8( double **xa, 
                double **ya, 
                int n_ali,
                double d,
                int i_ali[], 
                double *score1,
                int score_sum_method
              )
{
    double score_sum=0, di;
    double d_tmp=d*d;
	double d02=d0*d0;
	double score_d8_cut = score_d8*score_d8;
    
    int i, n_cut, inc=0;

    while(1)
    {
		n_cut=0;
        score_sum=0;
        for(i=0; i<n_ali; i++)
        {
            di = dist(xa[i], ya[i]);
            if(di<d_tmp)
            {
                i_ali[n_cut]=i;
                n_cut++;
            }
            if(score_sum_method==8)
            {				
                if(di<=score_d8_cut)
                {					
                    score_sum += 1/(1+di/d02);
                }                
            }
            else
            {
				score_sum += 1/(1+di/d02);
            }
        }
        //there are not enough feasible pairs, reliefe the threshold 		
        if(n_cut<3 && n_ali>3)
        {
			inc++;
			double dinc=(d+inc*0.5);
			d_tmp = dinc * dinc;
        }
        else
        {
            break;
        }

    }  

    *score1=score_sum/Lnorm;

    return n_cut;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movapd %xmm0, %xmm5
mulsd %xmm0, %xmm5
movsd 0x1fb199(%rip), %xmm4   # 0x602580
mulsd %xmm4, %xmm4
movsd 0x1fb185(%rip), %xmm1   # 0x602578
mulsd %xmm1, %xmm1
movl %edx, %r10d
movsd 0x17cc06(%rip), %xmm2   # 0x584008
movapd %xmm2, %xmm3
divsd %xmm4, %xmm3
xorl %r11d, %r11d
movsd 0x17cc03(%rip), %xmm4   # 0x584018
testl %edx, %edx
jle 0x407495
xorl %ebx, %ebx
xorpd %xmm6, %xmm6
xorl %eax, %eax
movq (%rdi,%rbx,8), %r14
movq (%rsi,%rbx,8), %r15
movsd (%r14), %xmm8
subsd (%r15), %xmm8
mulsd %xmm8, %xmm8
movupd 0x8(%r14), %xmm7
movupd 0x8(%r15), %xmm9
subpd %xmm9, %xmm7
mulpd %xmm7, %xmm7
addsd %xmm7, %xmm8
unpckhpd %xmm7, %xmm7            # xmm7 = xmm7[1,1]
addsd %xmm8, %xmm7
ucomisd %xmm5, %xmm7
jae 0x407468
cltq
movl %ebx, (%rcx,%rax,4)
incl %eax
cmpl $0x8, %r9d
jne 0x407474
ucomisd %xmm1, %xmm7
ja 0x40748b
mulsd %xmm3, %xmm7
addsd %xmm2, %xmm7
movapd %xmm2, %xmm8
divsd %xmm7, %xmm8
addsd %xmm8, %xmm6
incq %rbx
cmpq %rbx, %r10
jne 0x407421
jmp 0x40749b
xorpd %xmm6, %xmm6
xorl %eax, %eax
cmpl $0x4, %edx
jl 0x4074c1
cmpl $0x2, %eax
jg 0x4074c1
incl %r11d
xorps %xmm5, %xmm5
cvtsi2sd %r11d, %xmm5
mulsd %xmm4, %xmm5
addsd %xmm0, %xmm5
mulsd %xmm5, %xmm5
jmp 0x407415
divsd 0x1fb0a7(%rip), %xmm6   # 0x602570
movsd %xmm6, (%r8)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/asford[P]tmalign/./TMalign.h
// Function: detailed_search(double**, double**, int, int, int*, double*, double (*) [3], int, int)
double detailed_search( double **x,
                        double **y, 
                        int x_len, 
                        int y_len, 
                        int invmap0[],
                        double t[3],
                        double u[3][3],
                        int simplify_step,
                        int score_sum_method                        
                       )
{
    //x is model, y is template, try to superpose onto y
    int i, j, k;     
    double tmscore;
    double rmsd;



    k=0;
    for(i=0; i<y_len; i++) 
    {
        j=invmap0[i];
        if(j>=0) //aligned
        {
            xtm[k][0]=x[j][0];
            xtm[k][1]=x[j][1];
            xtm[k][2]=x[j][2];
                
            ytm[k][0]=y[i][0];
            ytm[k][1]=y[i][1];
            ytm[k][2]=y[i][2];
            k++;
        }
    }
    
    //detailed search 40-->1
    tmscore=TMscore8_search(xtm, ytm, k, t, u, simplify_step, score_sum_method, &rmsd);  
   
    return tmscore;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %r9, %rax
movq %r8, %r10
movl 0x50(%rsp), %r11d
movl 0x48(%rsp), %r9d
movq 0x40(%rsp), %r8
testl %ecx, %ecx
jle 0x407b12
movq 0x1fab50(%rip), %rbx    # 0x6025e0
movq 0x1fab51(%rip), %r14    # 0x6025e8
movl %ecx, %ecx
xorl %r15d, %r15d
xorl %edx, %edx
movslq (%r10,%r15,4), %r12
testq %r12, %r12
js 0x407b08
movq (%rdi,%r12,8), %r12
movsd (%r12), %xmm0
movslq %edx, %rdx
movq (%rbx,%rdx,8), %r13
movsd %xmm0, (%r13)
movsd 0x8(%r12), %xmm0
movsd %xmm0, 0x8(%r13)
movsd 0x10(%r12), %xmm0
movsd %xmm0, 0x10(%r13)
movq (%rsi,%r15,8), %r12
movsd (%r12), %xmm0
movq (%r14,%rdx,8), %r13
movsd %xmm0, (%r13)
movsd 0x8(%r12), %xmm0
movsd %xmm0, 0x8(%r13)
movsd 0x10(%r12), %xmm0
movsd %xmm0, 0x10(%r13)
incl %edx
incq %r15
cmpq %r15, %rcx
jne 0x407a9e
jmp 0x407b14
xorl %edx, %edx
movq 0x1faac5(%rip), %rdi    # 0x6025e0
movq 0x1faac6(%rip), %rsi    # 0x6025e8
leaq 0x8(%rsp), %r10
movq %rax, %rcx
pushq %r10
pushq %r11
callq 0x4074d4
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/asford[P]tmalign/./TMalign.h
// Function: sec_str(double, double, double, double, double, double)
int sec_str(double dis13, double dis14, double dis15, double dis24, double dis25, double dis35)
{
	int s=1;
	
	double delta=2.1;
	if(fabs(dis15-6.37)<delta)
	{
		if(fabs(dis14-5.18)<delta)
		{
			if(fabs(dis25-5.18)<delta)
			{
				if(fabs(dis13-5.45)<delta)
				{
					if(fabs(dis24-5.45)<delta)
					{
						if(fabs(dis35-5.45)<delta)
						{
							s=2; //helix						
							return s;
						}
					}
				}
			}
		}
	}

	delta=1.42;
	if(fabs(dis15-13)<delta)
	{
		if(fabs(dis14-10.4)<delta)
		{
			if(fabs(dis25-10.4)<delta)
			{
				if(fabs(dis13-6.1)<delta)
				{
					if(fabs(dis24-6.1)<delta)
					{
						if(fabs(dis35-6.1)<delta)
						{
							s=4; //strand
							return s;
						}
					}
				}
			}
		}
	}

	if(dis15 < 8)
	{
		s=3; //turn
	}	  


	return s;
}

// Assembly:
movsd 0x17bcc7(%rip), %xmm6   # 0x584038
addsd %xmm2, %xmm6
andpd 0x17bdf3(%rip), %xmm6   # 0x584170
ucomisd 0x17bcbb(%rip), %xmm6   # 0x584040
jae 0x40842e
movsd 0x17bcb5(%rip), %xmm6   # 0x584048
addsd %xmm1, %xmm6
andpd 0x17bdd1(%rip), %xmm6   # 0x584170
ucomisd 0x17bc99(%rip), %xmm6   # 0x584040
jae 0x40842e
movsd 0x17bc93(%rip), %xmm6   # 0x584048
addsd %xmm4, %xmm6
andpd 0x17bdaf(%rip), %xmm6   # 0x584170
ucomisd 0x17bc77(%rip), %xmm6   # 0x584040
jae 0x40842e
movsd 0x17bc7d(%rip), %xmm6   # 0x584050
addsd %xmm0, %xmm6
andpd 0x17bd91(%rip), %xmm6   # 0x584170
ucomisd 0x17bc59(%rip), %xmm6   # 0x584040
jae 0x40842e
movsd 0x17bc5f(%rip), %xmm6   # 0x584050
addsd %xmm3, %xmm6
andpd 0x17bd73(%rip), %xmm6   # 0x584170
ucomisd 0x17bc3b(%rip), %xmm6   # 0x584040
jae 0x40842e
movsd 0x17bc41(%rip), %xmm6   # 0x584050
addsd %xmm5, %xmm6
andpd 0x17bd55(%rip), %xmm6   # 0x584170
movl $0x2, %eax
ucomisd 0x17bc18(%rip), %xmm6   # 0x584040
jb 0x4084eb
movsd 0x17bc22(%rip), %xmm6   # 0x584058
addsd %xmm2, %xmm6
andpd 0x17bd2e(%rip), %xmm6   # 0x584170
ucomisd 0x17bc16(%rip), %xmm6   # 0x584060
jae 0x4084d7
addsd 0x17bc10(%rip), %xmm1   # 0x584068
andpd 0x17bd10(%rip), %xmm1   # 0x584170
ucomisd 0x17bbf8(%rip), %xmm1   # 0x584060
jae 0x4084d7
addsd 0x17bbf6(%rip), %xmm4   # 0x584068
andpd 0x17bcf6(%rip), %xmm4   # 0x584170
ucomisd 0x17bbde(%rip), %xmm4   # 0x584060
jae 0x4084d7
addsd 0x17bbe4(%rip), %xmm0   # 0x584070
andpd 0x17bcdc(%rip), %xmm0   # 0x584170
ucomisd 0x17bbc4(%rip), %xmm0   # 0x584060
jae 0x4084d7
addsd 0x17bbca(%rip), %xmm3   # 0x584070
andpd 0x17bcc2(%rip), %xmm3   # 0x584170
ucomisd 0x17bbaa(%rip), %xmm3   # 0x584060
jae 0x4084d7
addsd 0x17bbb0(%rip), %xmm5   # 0x584070
andpd 0x17bca8(%rip), %xmm5   # 0x584170
movl $0x4, %eax
ucomisd 0x17bb8b(%rip), %xmm5   # 0x584060
jb 0x4084eb
xorl %eax, %eax
ucomisd 0x17bb97(%rip), %xmm2   # 0x584078
setb %al
leal 0x1(,%rax,2), %eax
retq
// File: /workspace/github_c_makefile_star2_O1/asford[P]tmalign/./TMalign.h
// Function: make_sec(double**, int, int*)
void make_sec(double **x, int len, int *sec)
{
    int j1, j2, j3, j4, j5;
	double d13, d14, d15, d24, d25, d35;
    for(int i=0; i<len; i++)
    { 	
		sec[i]=1;
        j1=i-2;
        j2=i-1;
        j3=i;
        j4=i+1;
        j5=i+2;		
        
        if(j1>=0 && j5<len)
		{
			d13=sqrt(dist(x[j1], x[j3]));
			d14=sqrt(dist(x[j1], x[j4]));
			d15=sqrt(dist(x[j1], x[j5]));
			d24=sqrt(dist(x[j2], x[j4]));
			d25=sqrt(dist(x[j2], x[j5]));
			d35=sqrt(dist(x[j3], x[j5]));
			sec[i]=sec_str(d13, d14, d15, d24, d25, d35);			
		}    
    } 
	smooth(sec, len);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movl %esi, %ebx
testl %esi, %esi
jle 0x408687
movq %rdi, %r15
movl %ebx, %r12d
xorl %r13d, %r13d
movl $0x1, (%r14,%r13,4)
cmpq $0x2, %r13
setae %al
leaq 0x2(%r13), %rbp
cmpl %ebx, %ebp
setl %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x408678
movq (%r15,%r13,8), %rcx
movq -0x10(%r15,%r13,8), %rdx
movq -0x8(%r15,%r13,8), %rax
movsd (%rdx), %xmm2
movsd (%rcx), %xmm5
movapd %xmm2, %xmm0
subsd %xmm5, %xmm0
mulsd %xmm0, %xmm0
movupd 0x8(%rdx), %xmm3
movupd 0x8(%rcx), %xmm6
movapd %xmm3, %xmm1
subpd %xmm6, %xmm1
mulpd %xmm1, %xmm1
addsd %xmm1, %xmm0
unpckhpd %xmm1, %xmm1            # xmm1 = xmm1[1,1]
addsd %xmm0, %xmm1
xorps %xmm0, %xmm0
sqrtsd %xmm1, %xmm0
movq 0x8(%r15,%r13,8), %rcx
movsd (%rcx), %xmm4
movapd %xmm2, %xmm1
subsd %xmm4, %xmm1
mulsd %xmm1, %xmm1
movupd 0x8(%rcx), %xmm9
movapd %xmm3, %xmm7
subpd %xmm9, %xmm7
mulpd %xmm7, %xmm7
addsd %xmm7, %xmm1
unpckhpd %xmm7, %xmm7            # xmm7 = xmm7[1,1]
addsd %xmm1, %xmm7
xorps %xmm1, %xmm1
sqrtsd %xmm7, %xmm1
movq 0x10(%r15,%r13,8), %rcx
movsd (%rcx), %xmm7
subsd %xmm7, %xmm2
mulsd %xmm2, %xmm2
movupd 0x8(%rcx), %xmm8
subpd %xmm8, %xmm3
mulpd %xmm3, %xmm3
addsd %xmm3, %xmm2
unpckhpd %xmm3, %xmm3            # xmm3 = xmm3[1,1]
addsd %xmm2, %xmm3
xorps %xmm2, %xmm2
sqrtsd %xmm3, %xmm2
movsd (%rax), %xmm10
movapd %xmm10, %xmm3
subsd %xmm4, %xmm3
mulsd %xmm3, %xmm3
movupd 0x8(%rax), %xmm4
movapd %xmm4, %xmm11
subpd %xmm9, %xmm11
mulpd %xmm11, %xmm11
addsd %xmm11, %xmm3
unpckhpd %xmm11, %xmm11          # xmm11 = xmm11[1,1]
addsd %xmm3, %xmm11
xorps %xmm3, %xmm3
sqrtsd %xmm11, %xmm3
subsd %xmm7, %xmm10
mulsd %xmm10, %xmm10
subpd %xmm8, %xmm4
mulpd %xmm4, %xmm4
addsd %xmm4, %xmm10
unpckhpd %xmm4, %xmm4            # xmm4 = xmm4[1,1]
addsd %xmm10, %xmm4
sqrtsd %xmm4, %xmm4
subsd %xmm7, %xmm5
mulsd %xmm5, %xmm5
subpd %xmm8, %xmm6
mulpd %xmm6, %xmm6
addsd %xmm6, %xmm5
unpckhpd %xmm6, %xmm6            # xmm6 = xmm6[1,1]
addsd %xmm5, %xmm6
xorps %xmm5, %xmm5
sqrtsd %xmm6, %xmm5
callq 0x408369
movl %eax, (%r14,%r13,4)
decq %rbp
movq %rbp, %r13
cmpq %r12, %rbp
jne 0x40850d
movq %r14, %rdi
movl %ebx, %esi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x408263
// File: /workspace/github_c_makefile_star2_O1/asford[P]tmalign/TMalign.cpp
// Function: parameter_set4search(int, int)
void parameter_set4search(int xlen, int ylen)
{
	//parameter initilization for searching: D0_MIN, Lnorm, d0, d0_search, score_d8
	D0_MIN=0.5; 
	dcu0=4.25;                       //update 3.85-->4.25
 
	Lnorm=getmin(xlen, ylen);        //normaliz TMscore by this in searching
    if(Lnorm<=19)                    //update 15-->19
    {
        d0=0.168;                   //update 0.5-->0.168
    }
    else
    {
        d0=(1.24*pow((Lnorm*1.0-15), 1.0/3)-1.8);
    }
	D0_MIN=d0+0.8;              //this should be moved to above
    d0=D0_MIN;                  //update: best for search    


	d0_search=d0;	
	if(d0_search>8) d0_search=8;
	if(d0_search<4.5) d0_search=4.5;


    score_d8=1.5*pow(Lnorm*1.0, 0.3)+3.5; //remove pairs with dis>d8 during search & final
}

// Assembly:
pushq %rax
movabsq $0x3fe0000000000000, %rax # imm = 0x3FE0000000000000
movq %rax, 0x1f77b2(%rip)    # 0x602568
movabsq $0x4011000000000000, %rax # imm = 0x4011000000000000
movq %rax, 0x1f77c9(%rip)    # 0x602590
cmpl %esi, %edi
cmovll %edi, %esi
cvtsi2sd %esi, %xmm2
movsd %xmm2, 0x1f7798(%rip)   # 0x602570
cmpl $0x14, %esi
jge 0x40ade7
movsd 0x1792bb(%rip), %xmm0   # 0x5840a0
jmp 0x40ae0d
addl $-0xf, %esi
cvtsi2sd %esi, %xmm0
movsd %xmm2, (%rsp)
callq 0x4aac40
movsd (%rsp), %xmm2
mulsd 0x1792a3(%rip), %xmm0   # 0x5840a8
addsd 0x1792a3(%rip), %xmm0   # 0x5840b0
addsd 0x1792a3(%rip), %xmm0   # 0x5840b8
movsd %xmm0, 0x1f774b(%rip)   # 0x602568
movsd %xmm0, 0x1f775b(%rip)   # 0x602580
minsd 0x17924b(%rip), %xmm0   # 0x584078
maxsd 0x17928b(%rip), %xmm0   # 0x5840c0
movsd %xmm0, 0x1f774b(%rip)   # 0x602588
movsd 0x179283(%rip), %xmm1   # 0x5840c8
movapd %xmm2, %xmm0
callq 0x4ab8d0
mulsd 0x17922a(%rip), %xmm0   # 0x584080
addsd 0x179272(%rip), %xmm0   # 0x5840d0
movsd %xmm0, 0x1f7712(%rip)   # 0x602578
popq %rax
retq
// File: /workspace/github_c_makefile_star2_O1/asford[P]tmalign/TMalign.cpp
// Function: parameter_set4final(double)
void parameter_set4final(double len)
{
	D0_MIN=0.5; 
 
	Lnorm=len;            //normaliz TMscore by this in searching
    if(Lnorm<=21)         
    {
        d0=0.5;          
    }
    else
    {
        d0=(1.24*pow((Lnorm*1.0-15), 1.0/3)-1.8);
    }
    if(d0<D0_MIN) d0=D0_MIN;   

	d0_search=d0;	
	if(d0_search>8) d0_search=8;
	if(d0_search<4.5) d0_search=4.5;  

}

// Assembly:
pushq %rax
movabsq $0x3fe0000000000000, %rax # imm = 0x3FE0000000000000
movq %rax, 0x1f76ee(%rip)    # 0x602568
movsd %xmm0, 0x1f76ee(%rip)   # 0x602570
ucomisd 0x17924e(%rip), %xmm0   # 0x5840d8
jbe 0x40aeab
addsd 0x17924c(%rip), %xmm0   # 0x5840e0
callq 0x4aac40
mulsd 0x179207(%rip), %xmm0   # 0x5840a8
addsd 0x179207(%rip), %xmm0   # 0x5840b0
jmp 0x40aeb3
movsd 0x179165(%rip), %xmm0   # 0x584018
maxsd 0x17915d(%rip), %xmm0   # 0x584018
movsd %xmm0, 0x1f76bd(%rip)   # 0x602580
minsd 0x1791ad(%rip), %xmm0   # 0x584078
maxsd 0x1791ed(%rip), %xmm0   # 0x5840c0
movsd %xmm0, 0x1f76ad(%rip)   # 0x602588
popq %rax
retq
// File: /workspace/github_c_makefile_star2_O1/asford[P]tmalign/./basic_fun.h
// Function: void DeleteArray<bool>(bool***, int)
void DeleteArray(A *** array, int Narray)
{
  for(int i=0; i<Narray; i++)
    if(*(*array+i)) delete [] *(*array+i);
  if(Narray) delete [] (*array);
  (*array)=NULL;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
testl %esi, %esi
jle 0x40c1b8
movl %ebp, %r14d
xorl %r15d, %r15d
movq (%rbx), %rax
movq (%rax,%r15,8), %rdi
testq %rdi, %rdi
je 0x40c1b0
callq 0x40c360
incq %r15
cmpq %r15, %r14
jne 0x40c19f
testl %ebp, %ebp
je 0x40c1c9
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x40c1c9
callq 0x40c360
movq $0x0, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/ramirezsebas[P]TP-LISTINGS/./src/capitulo_4/4.12/job-queue3.c
// Function: main
int main(){
	//Add jobs to the queue
	create_files(NUM_FILES);

	pthread_t threads_id[NUM_THREADS];
	
	int i;

	enqueue_job("file1.txt", 0);
	enqueue_job("file2.txt", 1);
	enqueue_job("file3.txt", 0);
	enqueue_job("file4.txt", 1);
	enqueue_job("file5.txt", 0);
	enqueue_job("file6.txt", 1);
	enqueue_job("file7.txt", 0);
	enqueue_job("file8.txt", 1);

	for(i = 0; i < NUM_THREADS; ++i){
		pthread_create(&threads_id[i], NULL, &thread_function, NULL);
	}

	for(i = 0; i < NUM_THREADS; ++i){
		pthread_join(threads_id[i], NULL);
	}

	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x20, %rsp
movl $0x8, %edi
callq 0x1347
leaq 0xd7c(%rip), %rdi       # 0x2004
xorl %r14d, %r14d
xorl %esi, %esi
callq 0x147e
leaq 0xd75(%rip), %rdi       # 0x200e
movl $0x1, %esi
callq 0x147e
leaq 0xd6e(%rip), %rdi       # 0x2018
xorl %esi, %esi
callq 0x147e
leaq 0xd6a(%rip), %rdi       # 0x2022
movl $0x1, %esi
callq 0x147e
leaq 0xd63(%rip), %rdi       # 0x202c
xorl %esi, %esi
callq 0x147e
leaq 0xd5f(%rip), %rdi       # 0x2036
movl $0x1, %esi
callq 0x147e
leaq 0xd58(%rip), %rdi       # 0x2040
xorl %esi, %esi
callq 0x147e
leaq 0xd54(%rip), %rdi       # 0x204a
movl $0x1, %esi
callq 0x147e
leaq 0x1df(%rip), %rbx       # 0x14e6
leaq (%r14,%rbp), %rdi
addq $-0x30, %rdi
xorl %esi, %esi
movq %rbx, %rdx
xorl %ecx, %ecx
callq 0x1100
addq $0x8, %r14
cmpq $0x20, %r14
jne 0x1307
xorl %ebx, %ebx
movq -0x30(%rbp,%rbx,8), %rdi
xorl %esi, %esi
callq 0x1130
incq %rbx
cmpq $0x4, %rbx
jne 0x1327
xorl %eax, %eax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %rbp
retq