LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O3/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 0x69fa
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 0x1190
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 0x1150
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 0x20a2(%rip), %rdi      # 0x8aa3
leaq 0x18eb(%rip), %rsi      # 0x82f3
leaq 0x20a4(%rip), %rcx      # 0x8ab3
movl $0x250, %edx            # imm = 0x250
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O3/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 0x6ae5
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 0x1190
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 0x1150
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 0x1fb7(%rip), %rdi      # 0x8aa3
leaq 0x1800(%rip), %rsi      # 0x82f3
leaq 0x2023(%rip), %rcx      # 0x8b1d
movl $0x23f, %edx            # imm = 0x23F
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O3/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 0x6b30
movq %rsi, %r15
testq %rsi, %rsi
je 0x6b59
movl %edx, %ebx
movq %rdi, %r14
movl %edx, %esi
callq 0x68e3
testl %eax, %eax
je 0x6b3b
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movl (%r15), %ecx
leaq 0x20c8(%rip), %rsi      # 0x8c0d
movq %r14, %rdi
movl %ebx, %edx
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x6928
leaq 0x1864(%rip), %rdi      # 0x83c4
leaq 0x178c(%rip), %rsi      # 0x82f3
leaq 0x204a(%rip), %rcx      # 0x8bb8
movl $0x2a6, %edx            # imm = 0x2A6
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O3/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 $0x28, %rsp
testl %r8d, %r8d
je 0x6ca3
movq %rcx, %r14
movq %rsi, %r15
movq %rdi, %r12
movl %r8d, %ecx
leaq 0x1(%rdx), %rax
movq %rax, -0x48(%rbp)
xorl %esi, %esi
movq %rdx, -0x30(%rbp)
movq %r14, -0x50(%rbp)
movq %rcx, -0x40(%rbp)
movq %rsi, %r13
shlq $0x5, %r13
movq 0x18(%r14,%r13), %rax
testq %rax, %rax
je 0x6c97
cmpb $0x0, (%rax)
je 0x6cbb
movq %rsi, -0x38(%rbp)
movb (%rdx), %al
testb %al, %al
je 0x6c04
movq -0x48(%rbp), %r14
movq %rdx, %rbx
movsbl %al, %edi
movq %r12, %rsi
callq *%r15
cmpl $-0x1, %eax
je 0x6caa
movb (%r14), %al
incq %rbx
incq %r14
testb %al, %al
jne 0x6be3
jmp 0x6c07
movq %rdx, %rbx
subl -0x30(%rbp), %ebx
xorl %eax, %eax
cmpl $-0x1, %ebx
movq -0x50(%rbp), %r14
je 0x6cac
movq %r12, %rdi
movq %r15, %rsi
movq -0x38(%rbp), %rdx
callq 0x6cda
cmpl $-0x1, %eax
je 0x6caa
movl $0x20, %edi
movq %r12, %rsi
callq *%r15
cmpl $-0x1, %eax
je 0x6caa
leaq (%r14,%r13), %rax
addq $0x18, %rax
movq (%rax), %r13
movb (%r13), %al
movq %r13, %rbx
testb %al, %al
je 0x6c6e
movq %r13, %rbx
movsbl %al, %edi
movq %r12, %rsi
callq *%r15
cmpl $-0x1, %eax
je 0x6caa
movb 0x1(%rbx), %al
incq %rbx
testb %al, %al
jne 0x6c56
subl %r13d, %ebx
cmpl $-0x1, %ebx
je 0x6caa
movl $0xa, %edi
movq %r12, %rsi
callq *%r15
cmpl $-0x1, %eax
movq -0x30(%rbp), %rdx
movq -0x40(%rbp), %rcx
movq -0x38(%rbp), %rsi
movl $0x0, %eax
je 0x6cac
incq %rsi
cmpq %rcx, %rsi
jne 0x6bb4
movl $0x1, %eax
jmp 0x6cac
xorl %eax, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x2006(%rip), %rdi      # 0x8cc8
leaq 0x162a(%rip), %rsi      # 0x82f3
leaq 0x200b(%rip), %rcx      # 0x8cdb
movl $0x498, %edx            # imm = 0x498
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O3/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 0x11c0
movq (%rax), %rax
movslq 0x10(%rbx), %rcx
testb $0x20, 0x1(%rax,%rcx,2)
je 0x73af
movslq %r14d, %rcx
testb $0x20, 0x1(%rax,%rcx,2)
jne 0x73af
movl 0x14(%rbx), %ecx
movl %ecx, 0x1c(%rbx)
movl %r14d, 0x10(%rbx)
cmpl $0x0, 0x20(%rbx)
je 0x73e8
cmpl $0x0, 0x24(%rbx)
je 0x73e8
movslq %r14d, %rcx
movzwl (%rax,%rcx,2), %eax
btl $0xd, %eax
jb 0x73e8
btl $0xb, %eax
setae %al
cmpl $-0x1, %r14d
setne %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x73e8
movl $0x0, 0x24(%rbx)
cmpl $-0x1, %r14d
je 0x73fa
cmpl $0xa, %r14d
jne 0x73f7
incl 0x14(%rbx)
incl 0x18(%rbx)
movl %r14d, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/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 0x75aa
movl %ecx, %eax
shrl %eax
cmpl %eax, (%rdi)
jae 0x7571
xorl %eax, %eax
retq
movq 0x70(%rdi), %rdx
movl %eax, %eax
movb (%rdx,%rax,8), %al
testb $0x1, %al
jne 0x758f
testb $0x2, %al
jne 0x7598
testb $0x4, %al
je 0x756e
leaq 0x1dcd(%rip), %rax      # 0x935a
jmp 0x759f
leaq 0x1d6a(%rip), %rax      # 0x9300
jmp 0x759f
leaq 0x1d8e(%rip), %rax      # 0x932d
movl 0x1c(%rsi), %edx
movq %rax, %rsi
jmp 0x6928
pushq %rbp
movq %rsp, %rbp
leaq 0xddc(%rip), %rdi       # 0x8391
leaq 0xd37(%rip), %rsi       # 0x82f3
leaq 0x1cf4(%rip), %rcx      # 0x92b7
movl $0x7c4, %edx            # imm = 0x7C4
callq 0x10f0
// File: /workspace/github_c_makefile_star2_O3/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 0x769c
testb %r15b, %r15b
js 0x7638
andl $0x7f, %r15d
xorl %r14d, %r14d
movl %r15d, %eax
xorl %r12d, %r12d
leal (,%r14,8), %ecx
subl %r14d, %ecx
shll %cl, %eax
orl %r12d, %eax
movq -0x40(%rbp), %rcx
movl %eax, (%rcx)
movq %rbx, %rdi
callq 0x7379
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl 0x18(%rbx), %eax
movl %eax, -0x2c(%rbp)
xorl %r13d, %r13d
xorl %r14d, %r14d
xorl %r12d, %r12d
cmpl $-0x5, %r14d
je 0x768c
movq %rbx, %rdi
callq 0x7379
movl 0x10(%rbx), %eax
cmpl $-0x1, %eax
je 0x769c
andl $0x7f, %r15d
movl %r13d, %ecx
shll %cl, %r15d
orl %r15d, %r12d
decl %r14d
addl $0x7, %r13d
movl %eax, %r15d
testb %al, %al
js 0x7647
andl $0x7f, %eax
cmpl $-0x5, %r14d
sete %cl
cmpl $0x8, %eax
setae %dl
testb %dl, %cl
je 0x76bd
leaq 0x1d61(%rip), %rsi      # 0x93f4
movq -0x38(%rbp), %rdi
movl -0x2c(%rbp), %edx
jmp 0x76aa
movl 0x18(%rbx), %edx
leaq 0x1d29(%rip), %rsi      # 0x93cf
movq -0x38(%rbp), %rdi
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x6a19
negl %r14d
jmp 0x7609
// File: /workspace/github_c_makefile_star2_O3/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 0x1b5b
movl %eax, %ecx
shll %cl, %r12d
leal 0x1(%r14), %edx
movl %edx, 0x8(%rsp)
movq %rbx, %rsi
movl %ebp, %ecx
callq 0x1a16
movq %r12, %r13
shlq $0x4, %r13
leaq (%rbx,%r13), %rsi
movq %r15, %rdi
movl 0x8(%rsp), %edx
movl %ebp, %ecx
callq 0x1a16
leaq 0x25f8(%rip), %r15      # 0x4080
movq (%r15), %rax
xorl %ebp, %ebp
movl %ebp, %edx
movl %r14d, %ecx
shll %cl, %edx
shlq $0x4, %rdx
movsd (%rbx), %xmm5
movsd 0x8(%rbx), %xmm6
movupd (%rax,%rdx), %xmm2
movupd (%rbx,%r13), %xmm4
movapd %xmm2, %xmm0
mulpd %xmm4, %xmm0
movapd %xmm2, %xmm3
shufpd $0x1, %xmm2, %xmm3      # xmm3 = xmm3[1],xmm2[0]
mulpd %xmm4, %xmm3
movapd %xmm0, %xmm1
unpckhpd %xmm0, %xmm1            # xmm1 = xmm1[1],xmm0[1]
subsd %xmm1, %xmm0
movapd %xmm3, %xmm1
unpckhpd %xmm3, %xmm1            # xmm1 = xmm1[1],xmm3[1]
addsd %xmm3, %xmm1
ucomisd %xmm0, %xmm0
jp 0x1b1f
movapd %xmm5, %xmm2
addsd %xmm0, %xmm2
movapd %xmm6, %xmm3
addsd %xmm1, %xmm3
movsd %xmm2, (%rbx)
movsd %xmm3, 0x8(%rbx)
subsd %xmm0, %xmm5
subsd %xmm1, %xmm6
movsd %xmm5, (%rbx,%r13)
movsd %xmm6, 0x8(%rbx,%r13)
incq %rbp
addq $0x10, %rbx
cmpq %rbp, %r12
jne 0x1a8d
jmp 0x1b79
ucomisd %xmm1, %xmm1
jnp 0x1adf
movapd %xmm2, %xmm3
unpckhpd %xmm2, %xmm3            # xmm3 = xmm3[1],xmm2[1]
movapd %xmm4, %xmm1
unpckhpd %xmm4, %xmm1            # xmm1 = xmm1[1],xmm4[1]
movapd %xmm4, %xmm0
movsd %xmm5, 0x8(%rsp)
movsd %xmm6, 0x10(%rsp)
callq 0x1ba0
movsd 0x10(%rsp), %xmm6
movsd 0x8(%rsp), %xmm5
movq (%r15), %rax
jmp 0x1adf
movupd (%rdi), %xmm0
movupd (%r15), %xmm1
movapd %xmm0, %xmm2
addpd %xmm1, %xmm2
movupd %xmm2, (%rbx)
subpd %xmm1, %xmm0
movupd %xmm0, 0x10(%rbx)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/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 %rbx
subq $0x9c40, %rsp           # imm = 0x9C40
cmpl $0x2, %edi
jle 0x11ac
leaq 0xe64(%rip), %rdi       # 0x2004
callq 0x1040
movl $0x1, %eax
jmp 0x11f9
movl $0xa, %ebx
jne 0x11d6
movq 0x8(%rsi), %rbx
cmpb $0x2d, (%rbx)
jne 0x1199
incq %rbx
movq %rbx, %rdi
callq 0x1392
testl %eax, %eax
je 0x1199
movq %rbx, %rdi
callq 0x1060
movslq %eax, %rbx
movq %rsp, %rdi
movl $0x1388, %esi           # imm = 0x1388
callq 0x1233
cmpq $-0x1, %rax
je 0x1202
movq %rsp, %rdi
movq %rbx, %rsi
movq %rax, %rdx
callq 0x1322
xorl %eax, %eax
addq $0x9c40, %rsp           # imm = 0x9C40
popq %rbx
retq
leaq 0xe16(%rip), %rdi       # 0x201f
jmp 0x11a0
// File: /workspace/github_c_makefile_star2_O3/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 0x1391
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 0x2d1d(%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 0x1381
movq %rax, 0x2cd7(%rip)      # 0x4058
incq %rbx
jne 0x135a
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/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 0x17f6ef(%rip), %r15    # 0x5850e7
movl (%rbx,%r13,4), %eax
movl %eax, %esi
notl %esi
shrl $0x1f, %esi
addl %eax, %esi
movq %r14, %rdi
callq 0x476950
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x476080
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 0x4571d0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x475b80
movq %rax, %rdi
callq 0x475150
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4571d0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x475b80
movq %rax, %rdi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x475150
// File: /workspace/github_c_makefile_star2_O3/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 0x17f63a(%rip), %r12    # 0x5850e7
movl (%r14,%rbp,4), %esi
movq %r15, %rdi
callq 0x476950
movl $0x1, %edx
movq %rax, %rdi
movq %r12, %rsi
callq 0x476080
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 0x4571d0
movsbl %al, %esi
movq %r14, %rdi
callq 0x475b80
movq %rax, %rdi
callq 0x475150
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x4571d0
movsbl %al, %esi
movq %r14, %rdi
callq 0x475b80
movq %rax, %rdi
callq 0x475150
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_O3/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 0x1fb3bb(%rip), %esi    # 0x6025b0
incl %esi
leaq 0x1fb3a2(%rip), %rdi    # 0x6025a0
callq 0x40c41d
movl 0x1fb3a7(%rip), %esi    # 0x6025b0
incl %esi
leaq 0x1fb396(%rip), %rdi    # 0x6025a8
callq 0x40c46f
movl 0x1fb393(%rip), %esi    # 0x6025b0
incl %esi
leaq 0x1fb372(%rip), %rdi    # 0x602598
callq 0x40c46f
movl 0x1fb37f(%rip), %esi    # 0x6025b0
leaq 0x1fb388(%rip), %rdi    # 0x6025c0
callq 0x40c46f
movl 0x1fb36d(%rip), %esi    # 0x6025b0
leaq 0x1fb3a6(%rip), %rdi    # 0x6025f0
callq 0x40c46f
movl 0x1fb35f(%rip), %esi    # 0x6025b4
leaq 0x1fb36c(%rip), %rdi    # 0x6025c8
callq 0x40c46f
movl 0x1fb351(%rip), %esi    # 0x6025b8
leaq 0x1fb3aa(%rip), %rdi    # 0x602618
callq 0x40c46f
movl 0x1fb33f(%rip), %esi    # 0x6025b8
leaq 0x1fb3a0(%rip), %rdi    # 0x602620
callq 0x40c46f
movl 0x1fb32d(%rip), %esi    # 0x6025b8
leaq 0x1fb34e(%rip), %rdi    # 0x6025e0
callq 0x40c46f
movl 0x1fb31b(%rip), %esi    # 0x6025b8
leaq 0x1fb344(%rip), %rdi    # 0x6025e8
callq 0x40c46f
movq 0x1fb348(%rip), %rdi    # 0x6025f8
testq %rdi, %rdi
je 0x4072ba
callq 0x40c600
movq 0x1fb33f(%rip), %rdi    # 0x602600
testq %rdi, %rdi
je 0x4072cb
callq 0x40c600
movq 0x1fb336(%rip), %rdi    # 0x602608
testq %rdi, %rdi
je 0x4072dc
callq 0x40c600
movq 0x1fb32d(%rip), %rdi    # 0x602610
testq %rdi, %rdi
je 0x4072ed
callq 0x40c600
movq 0x1fb2dc(%rip), %rdi    # 0x6025d0
testq %rdi, %rdi
je 0x4072fe
callq 0x40c600
movq 0x1fb2d3(%rip), %rdi    # 0x6025d8
testq %rdi, %rdi
je 0x407310
popq %rax
jmp 0x40c600
popq %rax
retq
// File: /workspace/github_c_makefile_star2_O3/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:
testl %edx, %edx
jle 0x407404
pushq %r15
pushq %r14
pushq %rbx
movsd 0x1fb259(%rip), %xmm4   # 0x602580
mulsd %xmm4, %xmm4
movsd 0x1fb245(%rip), %xmm1   # 0x602578
mulsd %xmm1, %xmm1
movl %edx, %r10d
movapd %xmm0, %xmm6
mulsd %xmm0, %xmm6
movsd 0x17ccbe(%rip), %xmm2   # 0x584008
movapd %xmm2, %xmm3
divsd %xmm4, %xmm3
xorl %r11d, %r11d
movsd 0x17ccbb(%rip), %xmm4   # 0x584018
xorpd %xmm5, %xmm5
xorl %ebx, %ebx
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 %xmm6, %xmm7
jae 0x4073ac
cltq
movl %ebx, (%rcx,%rax,4)
incl %eax
cmpl $0x8, %r9d
jne 0x4073b8
ucomisd %xmm1, %xmm7
ja 0x4073cf
mulsd %xmm3, %xmm7
addsd %xmm2, %xmm7
movapd %xmm2, %xmm8
divsd %xmm7, %xmm8
addsd %xmm8, %xmm5
incq %rbx
cmpq %rbx, %r10
jne 0x407365
cmpl $0x4, %edx
jl 0x4073fd
cmpl $0x2, %eax
jg 0x4073fd
incl %r11d
xorps %xmm6, %xmm6
cvtsi2sd %r11d, %xmm6
mulsd %xmm4, %xmm6
addsd %xmm0, %xmm6
mulsd %xmm6, %xmm6
jmp 0x40735d
popq %rbx
popq %r14
popq %r15
jmp 0x40740a
xorl %eax, %eax
xorpd %xmm5, %xmm5
divsd 0x1fb15e(%rip), %xmm5   # 0x602570
movsd %xmm5, (%r8)
retq
// File: /workspace/github_c_makefile_star2_O3/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, %r11
movq %rsi, %rbx
movq %rdi, %r10
movl 0x50(%rsp), %r14d
movl 0x48(%rsp), %r9d
movq 0x40(%rsp), %r8
movq 0x1fac2f(%rip), %rdi    # 0x6025e0
movq 0x1fac30(%rip), %rsi    # 0x6025e8
testl %ecx, %ecx
jle 0x407a37
movl %ecx, %ecx
xorl %r15d, %r15d
xorl %edx, %edx
movslq (%r11,%r15,4), %r12
testq %r12, %r12
js 0x407a2d
movq (%r10,%r12,8), %r12
movsd (%r12), %xmm0
movslq %edx, %rdx
movq (%rdi,%rdx,8), %r13
movsd %xmm0, (%r13)
movsd 0x8(%r12), %xmm0
movsd %xmm0, 0x8(%r13)
movsd 0x10(%r12), %xmm0
movsd %xmm0, 0x10(%r13)
movq (%rbx,%r15,8), %r12
movsd (%r12), %xmm0
movq (%rsi,%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 0x4079c3
jmp 0x407a39
xorl %edx, %edx
leaq 0x8(%rsp), %r10
movq %rax, %rcx
pushq %r10
pushq %r14
callq 0x407418
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/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 0x17bbf9(%rip), %xmm6   # 0x584038
addsd %xmm2, %xmm6
andpd 0x17bce5(%rip), %xmm6   # 0x584130
ucomisd 0x17bbed(%rip), %xmm6   # 0x584040
jae 0x4084fc
movsd 0x17bbe7(%rip), %xmm6   # 0x584048
addsd %xmm1, %xmm6
andpd 0x17bcc3(%rip), %xmm6   # 0x584130
ucomisd 0x17bbcb(%rip), %xmm6   # 0x584040
jae 0x4084fc
movsd 0x17bbc5(%rip), %xmm6   # 0x584048
addsd %xmm4, %xmm6
andpd 0x17bca1(%rip), %xmm6   # 0x584130
ucomisd 0x17bba9(%rip), %xmm6   # 0x584040
jae 0x4084fc
movsd 0x17bbaf(%rip), %xmm6   # 0x584050
addsd %xmm0, %xmm6
andpd 0x17bc83(%rip), %xmm6   # 0x584130
ucomisd 0x17bb8b(%rip), %xmm6   # 0x584040
jae 0x4084fc
movsd 0x17bb91(%rip), %xmm6   # 0x584050
addsd %xmm3, %xmm6
andpd 0x17bc65(%rip), %xmm6   # 0x584130
ucomisd 0x17bb6d(%rip), %xmm6   # 0x584040
jae 0x4084fc
movsd 0x17bb73(%rip), %xmm6   # 0x584050
addsd %xmm5, %xmm6
andpd 0x17bc47(%rip), %xmm6   # 0x584130
movl $0x2, %eax
ucomisd 0x17bb4a(%rip), %xmm6   # 0x584040
jb 0x4085b9
movsd 0x17bb54(%rip), %xmm6   # 0x584058
addsd %xmm2, %xmm6
andpd 0x17bc20(%rip), %xmm6   # 0x584130
ucomisd 0x17bb48(%rip), %xmm6   # 0x584060
jae 0x4085a5
addsd 0x17bb42(%rip), %xmm1   # 0x584068
andpd 0x17bc02(%rip), %xmm1   # 0x584130
ucomisd 0x17bb2a(%rip), %xmm1   # 0x584060
jae 0x4085a5
addsd 0x17bb28(%rip), %xmm4   # 0x584068
andpd 0x17bbe8(%rip), %xmm4   # 0x584130
ucomisd 0x17bb10(%rip), %xmm4   # 0x584060
jae 0x4085a5
addsd 0x17bb16(%rip), %xmm0   # 0x584070
andpd 0x17bbce(%rip), %xmm0   # 0x584130
ucomisd 0x17baf6(%rip), %xmm0   # 0x584060
jae 0x4085a5
addsd 0x17bafc(%rip), %xmm3   # 0x584070
andpd 0x17bbb4(%rip), %xmm3   # 0x584130
ucomisd 0x17badc(%rip), %xmm3   # 0x584060
jae 0x4085a5
addsd 0x17bae2(%rip), %xmm5   # 0x584070
andpd 0x17bb9a(%rip), %xmm5   # 0x584130
movl $0x4, %eax
ucomisd 0x17babd(%rip), %xmm5   # 0x584060
jb 0x4085b9
xorl %eax, %eax
ucomisd 0x17bac9(%rip), %xmm2   # 0x584078
setb %al
leal 0x1(,%rax,2), %eax
retq
// File: /workspace/github_c_makefile_star2_O3/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 $0x4011000000000000, %rax # imm = 0x4011000000000000
movq %rax, 0x1f75bd(%rip)    # 0x602590
cmpl %esi, %edi
cmovll %edi, %esi
cvtsi2sd %esi, %xmm2
movsd %xmm2, 0x1f758c(%rip)   # 0x602570
cmpl $0x14, %esi
jge 0x40aff3
movsd 0x1790af(%rip), %xmm0   # 0x5840a0
jmp 0x40b019
addl $-0xf, %esi
cvtsi2sd %esi, %xmm0
movsd %xmm2, (%rsp)
callq 0x4aaee0
movsd (%rsp), %xmm2
mulsd 0x179097(%rip), %xmm0   # 0x5840a8
addsd 0x179017(%rip), %xmm0   # 0x584030
movsd %xmm0, 0x1f7547(%rip)   # 0x602568
movsd %xmm0, 0x1f7557(%rip)   # 0x602580
minsd 0x179047(%rip), %xmm0   # 0x584078
maxsd 0x179077(%rip), %xmm0   # 0x5840b0
movsd %xmm0, 0x1f7547(%rip)   # 0x602588
movsd 0x17906f(%rip), %xmm1   # 0x5840b8
movapd %xmm2, %xmm0
callq 0x4abb70
mulsd 0x179026(%rip), %xmm0   # 0x584080
addsd 0x17905e(%rip), %xmm0   # 0x5840c0
movsd %xmm0, 0x1f750e(%rip)   # 0x602578
popq %rax
retq
// File: /workspace/github_c_makefile_star2_O3/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, 0x1f74ea(%rip)    # 0x602568
movsd %xmm0, 0x1f74ea(%rip)   # 0x602570
ucomisd 0x17903a(%rip), %xmm0   # 0x5840c8
jbe 0x40b0b7
addsd 0x179038(%rip), %xmm0   # 0x5840d0
callq 0x4aaee0
mulsd 0x179003(%rip), %xmm0   # 0x5840a8
addsd 0x17902b(%rip), %xmm0   # 0x5840d8
ucomisd 0x178f63(%rip), %xmm0   # 0x584018
jae 0x40b0bf
movsd 0x178f59(%rip), %xmm0   # 0x584018
movsd %xmm0, 0x1f74b9(%rip)   # 0x602580
minsd 0x178fa9(%rip), %xmm0   # 0x584078
maxsd 0x178fd9(%rip), %xmm0   # 0x5840b0
movsd %xmm0, 0x1f74a9(%rip)   # 0x602588
popq %rax
retq
// File: /workspace/github_c_makefile_star2_O3/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 0x40c44c
movl %ebp, %r14d
xorl %r15d, %r15d
movq (%rbx), %rax
movq (%rax,%r15,8), %rdi
testq %rdi, %rdi
je 0x40c444
callq 0x40c600
incq %r15
cmpq %r15, %r14
jne 0x40c433
testl %ebp, %ebp
je 0x40c45d
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x40c45d
callq 0x40c600
movq $0x0, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/ramirezsebas[P]TP-LISTINGS/./src/capitulo_4/4.12/job-queue3.c
// Function: enqueue_job
void enqueue_job (const char *filename, int reverse)
{
	job* new_job = create_job(filename, reverse);
	/* Set the other fields of the job struct here... */
	/* Lock the mutex on the job queue before accessing it.*/
	pthread_mutex_lock (&job_queue_mutex);
	/* Place the new job at the head of the queue. */
	new_job->next = job_queue;
	job_queue = new_job;

	/* Post to the semaphore to indicate that another job is available.
	If threads are blocked, waiting on the semaphore, one will become
	unblocked so it can process the job. */
	sem_post (&job_queue_count);

	/* Unlock the job queue mutex. */
	pthread_mutex_unlock (&job_queue_mutex);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
movl $0x18, %edi
callq 0x10e0
movq %rax, %r15
movq %r14, 0x8(%rax)
movl %ebx, 0x10(%rax)
leaq 0x2c28(%rip), %rbx      # 0x40d0
movq %rbx, %rdi
callq 0x1150
movq 0x2c41(%rip), %rax      # 0x40f8
movq %rax, (%r15)
movq %r15, 0x2c37(%rip)      # 0x40f8
leaq 0x2c38(%rip), %rdi      # 0x4100
callq 0x1080
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x10d0
// File: /workspace/github_c_makefile_star2_O3/ramirezsebas[P]TP-LISTINGS/./src/capitulo_4/4.12/job-queue3.c
// Function: process_job
void process_job(job* next_job){
	FILE *fp = fopen(next_job->filename, "r");
	int c, count = 0, i;
	int *array = NULL;

	for (c = getc(fp); c != EOF; c = getc(fp)) 
        if (c == '\n') 
            count = count + 1; 

	array = (int *)malloc(sizeof(int) * count);

	rewind(fp);

	for(i = 0; i < count; ++i)
		fscanf(fp,"%d", &array[i]);

	merge_sort(array, 0, count-1);

	fclose(fp);

	fp = fopen(next_job->filename, "w");

	if(next_job->reverse){
		for(i = count-1; i >= 0; --i)
			fprintf(fp, "%d\n", array[i]);		
	}else{
		for(i = 0; i < count; ++i)
			fprintf(fp, "%d\n", array[i]);
	}

	free(array);
	fclose(fp);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, -0x38(%rbp)
movq 0x8(%rdi), %rdi
leaq 0xacd(%rip), %rsi       # 0x2068
callq 0x1110
movq %rax, %r15
xorl %ebx, %ebx
movq %r15, %rdi
callq 0x1140
cmpl $-0x1, %eax
je 0x15bc
cmpl $0xa, %eax
jne 0x15a5
incq %rbx
jmp 0x15a5
movl %ebx, %edi
shlq $0x2, %rdi
callq 0x10e0
movq %rax, -0x30(%rbp)
movq %r15, %rdi
callq 0x1070
testl %ebx, %ebx
je 0x15fe
leaq 0xa87(%rip), %r12       # 0x2065
movq %rbx, %r14
movq -0x30(%rbp), %r13
movq %r15, %rdi
movq %r12, %rsi
movq %r13, %rdx
xorl %eax, %eax
callq 0x1040
addq $0x4, %r13
decq %r14
jne 0x15e5
leal -0x1(%rbx), %r12d
movq -0x30(%rbp), %rdi
xorl %esi, %esi
movl %r12d, %edx
callq 0x16a9
movq %r15, %rdi
callq 0x1060
movq -0x38(%rbp), %r14
movq 0x8(%r14), %rdi
leaq 0xa38(%rip), %rsi       # 0x205f
callq 0x1110
movq %rax, %r15
cmpl $0x0, 0x10(%r14)
je 0x1661
testl %ebx, %ebx
je 0x168a
movl %r12d, %r12d
leaq 0xa1d(%rip), %r14       # 0x2061
movq -0x30(%rbp), %rax
movl (%rax,%r12,4), %edx
movq %r15, %rdi
movq %r14, %rsi
xorl %eax, %eax
callq 0x10a0
addq $-0x1, %r12
jb 0x1644
jmp 0x168a
testl %ebx, %ebx
je 0x168a
leaq 0x9f5(%rip), %r12       # 0x2061
movq -0x30(%rbp), %r13
movl (%r13), %edx
movq %r15, %rdi
movq %r12, %rsi
xorl %eax, %eax
callq 0x10a0
addq $0x4, %r13
decq %rbx
jne 0x1670
movq -0x30(%rbp), %rdi
callq 0x1030
movq %r15, %rdi
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x1060
// File: /workspace/github_c_makefile_star2_O3/ramirezsebas[P]TP-LISTINGS/./src/capitulo_4/4.12/job-queue3.c
// Function: merge_sort
void merge_sort(int *a, int low, int high) 
{ 
    // calculating mid point of array 
    int mid = low + (high - low) / 2; 
    if (low < high) { 
  
        // calling first half 
        merge_sort(a, low, mid); 
  
        // calling second half 
        merge_sort(a, mid + 1, high); 
  
        // merging the two halves 
        merge(a, low, mid, high); 
    } 
}

// Assembly:
movl %edx, %eax
subl %esi, %eax
jle 0x170c
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edx, %ebx
movl %esi, %r14d
movq %rdi, %r15
movl %eax, %r13d
shrl $0x1f, %r13d
addl %eax, %r13d
sarl %r13d
leal (%r14,%r13), %r12d
movl %r12d, %edx
callq 0x16a9
leal (%r14,%r13), %esi
incl %esi
movq %r15, %rdi
movl %ebx, %edx
callq 0x16a9
movq %r15, %rdi
movl %r14d, %esi
movl %r12d, %edx
movl %ebx, %ecx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x170d
retq
// File: /workspace/github_c_makefile_star2_O3/xbarin02[P]uFFT/example.c
// Function: main
int main()
{
	size_t N = 1 << 3;

	float complex vector[N];

	for (size_t n = 0; n < N; n++) {
		vector[n] = n;
	}

	printf("in time domain:\n");

	for (size_t n = 0; n < N; n++) {
		printf("%f%+fi\n", creal(vector[n]), cimag(vector[n]));
	}

	fft(vector, N);

	printf("in frequency domain:\n");

	for (size_t n = 0; n < N; n++) {
		printf("%f%+fi\n", creal(vector[n]), cimag(vector[n]));
	}

	ift(vector, N);

	printf("in time domain:\n");

	for (size_t n = 0; n < N; n++) {
		printf("%f%+fi\n", creal(vector[n]), cimag(vector[n]));
	}

	return 0;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x48, %rsp
movdqa 0x1e75(%rip), %xmm0     # 0x3010
xorl %eax, %eax
movdqa 0x1e7b(%rip), %xmm1     # 0x3020
pshufd $0xee, %xmm0, %xmm2     # xmm2 = xmm0[2,3,2,3]
movq %xmm2, %rcx
testq %rcx, %rcx
js 0x11be
xorps %xmm2, %xmm2
cvtsi2ss %rcx, %xmm2
jmp 0x11d6
movq %rcx, %rdx
shrq %rdx
andl $0x1, %ecx
orq %rdx, %rcx
xorps %xmm2, %xmm2
cvtsi2ss %rcx, %xmm2
addss %xmm2, %xmm2
movq %xmm0, %rcx
testq %rcx, %rcx
js 0x11ea
xorps %xmm3, %xmm3
cvtsi2ss %rcx, %xmm3
jmp 0x1202
movq %rcx, %rdx
shrq %rdx
andl $0x1, %ecx
orq %rdx, %rcx
xorps %xmm3, %xmm3
cvtsi2ss %rcx, %xmm3
addss %xmm3, %xmm3
xorps %xmm4, %xmm4
movss %xmm3, %xmm4            # xmm4 = xmm3[0],xmm4[1,2,3]
xorps %xmm3, %xmm3
movss %xmm2, %xmm3            # xmm3 = xmm2[0],xmm3[1,2,3]
movlhps %xmm3, %xmm4            # xmm4 = xmm4[0],xmm3[0]
movaps %xmm4, (%rsp,%rax,8)
addq $0x2, %rax
paddq %xmm1, %xmm0
cmpq $0x8, %rax
jne 0x11a5
leaq 0x1e21(%rip), %rdi      # 0x304d
callq 0x1040
xorl %r14d, %r14d
leaq 0x1df5(%rip), %rbx      # 0x3030
xorps %xmm0, %xmm0
cvtss2sd (%rsp,%r14,8), %xmm0
xorps %xmm1, %xmm1
cvtss2sd 0x4(%rsp,%r14,8), %xmm1
movq %rbx, %rdi
movb $0x2, %al
callq 0x1050
incq %r14
cmpq $0x8, %r14
jne 0x123b
movq %rsp, %rdi
movl $0x8, %esi
callq 0x1300
leaq 0x1dc3(%rip), %rdi      # 0x3038
callq 0x1040
xorl %r14d, %r14d
leaq 0x1dac(%rip), %rbx      # 0x3030
xorps %xmm0, %xmm0
cvtss2sd (%rsp,%r14,8), %xmm0
xorps %xmm1, %xmm1
cvtss2sd 0x4(%rsp,%r14,8), %xmm1
movq %rbx, %rdi
movb $0x2, %al
callq 0x1050
incq %r14
cmpq $0x8, %r14
jne 0x1284
movq %rsp, %rdi
movl $0x8, %esi
callq 0x19dc
leaq 0x1d8f(%rip), %rdi      # 0x304d
callq 0x1040
xorl %r14d, %r14d
leaq 0x1d63(%rip), %rbx      # 0x3030
xorps %xmm0, %xmm0
cvtss2sd (%rsp,%r14,8), %xmm0
xorps %xmm1, %xmm1
cvtss2sd 0x4(%rsp,%r14,8), %xmm1
movq %rbx, %rdi
movb $0x2, %al
callq 0x1050
incq %r14
cmpq $0x8, %r14
jne 0x12cd
xorl %eax, %eax
addq $0x48, %rsp
popq %rbx
popq %r14
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O3/xbarin02[P]uFFT/fft-dit.c
// Function: nop_reverse
static int nop_reverse(int b, float complex *buffers[2], size_t N)
{
	int J = ctz(N);

	for (int j = 0; j < J - 1; j++, b++) {
		size_t delta = N >> j;

		for (size_t n = 0; n < N; n += delta) {
			nop_split(buffers[b&1] + n, buffers[~b&1] + n, delta);
		}
	}

	return b;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movl %edi, -0x14(%rsp)
movq %rdx, %rax
shrq %rax
je 0x18f7
bsrq %rax, %rax
xorq $0x3f, %rax
jmp 0x18fc
movl $0x40, %eax
movl $0x3f, %ecx
subl %eax, %ecx
testq %rdx, %rdx
movl $0xfffffffe, %eax       # imm = 0xFFFFFFFE
cmovnel %ecx, %eax
testl %eax, %eax
jle 0x19ca
movl %eax, %eax
movq %rax, -0x10(%rsp)
xorl %ecx, %ecx
movq %rdx, %r8
movq %rcx, -0x8(%rsp)
shrq %cl, %r8
testq %rdx, %rdx
je 0x19b3
movl -0x14(%rsp), %eax
movl %eax, %r9d
andl $0x1, %r9d
movl %r9d, %ecx
xorl $0x1, %ecx
movq %r8, %r11
shrq %r11
leaq (,%r11,8), %rbx
leaq (,%r8,8), %r14
movl $0x8, %r15d
xorl %r12d, %r12d
xorl %r13d, %r13d
cmpq $0x2, %r8
jb 0x19a2
movq (%rsi,%rcx,8), %rbp
leaq (%rbx,%rbp), %rdi
addq %r12, %rbp
movq (%rsi,%r9,8), %r10
addq %r15, %r10
xorl %eax, %eax
movsd -0x8(%r10), %xmm0
movsd %xmm0, (%rbp,%rax,8)
movsd (%r10), %xmm0
movsd %xmm0, (%rdi,%rax,8)
incq %rax
addq $0x10, %r10
cmpq %rax, %r11
jne 0x1980
addq %r8, %r13
addq %r14, %rbx
addq %r14, %r12
addq %r14, %r15
cmpq %rdx, %r13
jb 0x1966
movq -0x8(%rsp), %rcx
incq %rcx
incl -0x14(%rsp)
cmpq -0x10(%rsp), %rcx
jne 0x191f
movl -0x14(%rsp), %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O3/xbarin02[P]uFFT/ift-dif.c
// Function: nop_reverse
static int nop_reverse(int b, float complex *buffers[2], size_t N)
{
	int J = ctz(N);

	for (int j = J - 2; j >= 0; j--, b++) {
		size_t delta = N >> j;

		for (size_t n = 0; n < N; n += delta) {
			nop_split(buffers[b&1] + n, buffers[~b&1] + n, delta);
		}
	}

	return b;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movl %edi, -0xc(%rsp)
movq %rdx, %rax
shrq %rax
je 0x1f73
bsrq %rax, %rax
xorq $0x3f, %rax
jmp 0x1f78
movl $0x40, %eax
movl $0x3e, %ecx
subl %eax, %ecx
testq %rdx, %rdx
movl $0xfffffffd, %eax       # imm = 0xFFFFFFFD
cmovnel %ecx, %eax
testl %eax, %eax
js 0x2043
movl %eax, %eax
movq %rdx, %rdi
movq %rax, -0x8(%rsp)
movq %rax, %rcx
shrq %cl, %rdi
testq %rdx, %rdx
je 0x202d
movl -0xc(%rsp), %eax
movl %eax, %r8d
andl $0x1, %r8d
movl %r8d, %ecx
xorl $0x1, %ecx
movq %rdi, %r10
shrq %r10
leaq (,%r10,8), %r11
leaq (,%rdi,8), %rbx
movl $0x8, %r14d
xorl %r15d, %r15d
xorl %r12d, %r12d
cmpq $0x2, %rdi
jb 0x201c
movq (%rsi,%r8,8), %r13
leaq (%r11,%r13), %rbp
movq (%rsi,%rcx,8), %r9
addq %r14, %r9
addq %r15, %r13
xorl %eax, %eax
movsd (%r13,%rax,8), %xmm0
movsd %xmm0, -0x8(%r9)
movsd (%rbp,%rax,8), %xmm0
movsd %xmm0, (%r9)
incq %rax
addq $0x10, %r9
cmpq %rax, %r10
jne 0x1ff8
addq %rdi, %r12
addq %rbx, %r11
addq %rbx, %r14
addq %rbx, %r15
cmpq %rdx, %r12
jb 0x1fde
movq -0x8(%rsp), %rcx
leaq -0x1(%rcx), %rax
incl -0xc(%rsp)
testq %rcx, %rcx
jg 0x1f94
movl -0xc(%rsp), %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O3/FredTheDino[P]Fog/src/engine/util/getline.c
// Function: getline
ssize_t getline(char **lineptr, size_t *n, FILE *stream) {
    size_t pos;
    int c;

    if (lineptr == NULL || stream == NULL || n == NULL) {
        errno = EINVAL;
        return -1;
    }

    c = getc(stream);
    if (c == EOF) {
        return -1;
    }

    if (*lineptr == NULL) {
        *lineptr = (char *) malloc(128);
        if (*lineptr == NULL) {
            return -1;
        }
        *n = 128;
    }

    pos = 0;
    while(c != EOF) {
        if (pos + 1 >= *n) {
            size_t new_size = *n + (*n >> 2);
            if (new_size < 128) {
                new_size = 128;
            }
            char *new_ptr = (char *) realloc(*lineptr, new_size);
            if (new_ptr == NULL) {
                return -1;
            }
            *n = new_size;
            *lineptr = new_ptr;
        }

        ((unsigned char *)(*lineptr))[pos ++] = c;
        if (c == '\n') {
            break;
        }
        c = getc(stream);
    }

    (*lineptr)[pos] = '\0';
    return pos;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, -0x30(%rbp)
testq %rsi, %rsi
je 0x265f
movq %rdi, %r14
testq %rdi, %rdi
je 0x265f
movq %rdx, %r15
testq %rdx, %rdx
je 0x265f
movq %r15, %rdi
callq 0x20a0
cmpl $-0x1, %eax
je 0x266a
movl %eax, %r12d
cmpq $0x0, (%r14)
jne 0x25ea
movl $0x80, %edi
callq 0x2270
movq %rax, (%r14)
testq %rax, %rax
je 0x266a
movq -0x30(%rbp), %rax
movq $0x80, (%rax)
movl $0x1, %eax
movq %rax, %r13
movq -0x30(%rbp), %rax
movq (%rax), %rcx
movq (%r14), %rax
cmpq %rcx, %r13
jb 0x2635
movq %rcx, %rbx
shrq $0x2, %rbx
addq %rcx, %rbx
cmpq $0x81, %rbx
movl $0x80, %ecx
cmovbq %rcx, %rbx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2360
testq %rax, %rax
je 0x266a
movq -0x30(%rbp), %rcx
movq %rbx, (%rcx)
movq %rax, (%r14)
movb %r12b, -0x1(%rax,%r13)
cmpl $0xa, %r12d
je 0x2655
movq %r15, %rdi
callq 0x20a0
movl %eax, %r12d
leaq 0x1(%r13), %rax
cmpl $-0x1, %r12d
jne 0x25ef
movq (%r14), %rax
movb $0x0, (%rax,%r13)
jmp 0x2671
callq 0x2040
movl $0x16, (%rax)
movq $-0x1, %r13
movq %r13, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/FredTheDino[P]Fog/src/engine/util/debug.cpp
// Function: fog_debug_log(char const*, _IO_FILE*, char const*, int, char const*, char const*, ...)
void _fog_debug_log(const char* type, FILE* stream, const char* file,
                    int line, const char *func, const char* fmt, ...) {
    // TODO(ed): Log file with timestamps?
    va_list args;
    va_start(args, fmt);
#ifdef VIM_JUMP_TO
    fprintf(stream, "%s|%d| (%s) [%s]: ", file, line, func, type);
#else
    fprintf(stream, "%s @ %d (%s) [%s]:\n-- ", file, line, func, type);
#endif
    vfprintf(stream, fmt, args);
    va_end(args);
    fprintf(stream, "\n");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0xc8, %rsp
movq %r9, %r14
movq %rsi, %rbx
movq %rdi, %r9
testb %al, %al
je 0x26c9
movaps %xmm0, -0xb0(%rbp)
movaps %xmm1, -0xa0(%rbp)
movaps %xmm2, -0x90(%rbp)
movaps %xmm3, -0x80(%rbp)
movaps %xmm4, -0x70(%rbp)
movaps %xmm5, -0x60(%rbp)
movaps %xmm6, -0x50(%rbp)
movaps %xmm7, -0x40(%rbp)
leaq -0xe0(%rbp), %rax
leaq -0x30(%rbp), %r15
movq %rax, 0x10(%r15)
leaq 0x10(%rbp), %rax
movq %rax, 0x8(%r15)
movabsq $0x3000000030, %rax     # imm = 0x3000000030
movq %rax, (%r15)
leaq 0x1717c(%rip), %rsi     # 0x19870
movq %rbx, %rdi
xorl %eax, %eax
callq 0x22c0
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x2280
movl $0xa, %edi
movq %rbx, %rsi
callq 0x2250
addq $0xc8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/FredTheDino[P]Fog/src/engine/math/block_matrix.h
// Function: create_skew_symmetric(Vec3)
Mat4 create_skew_symmetric(Vec3 v) {
    Mat4 m;
    m._00 = m._11 = m._22 = m._33 = 0.0f;
    m._10 = v.z;
    m._01 = -v.z;
    m._02 = v.y;
    m._20 = -v.y;
    m._13 = v.z;
    m._31 = -v.z;
    return m;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, %rax
xorl %ecx, %ecx
movl %ecx, 0x3c(%rdi)
movl %ecx, 0x28(%rdi)
movl %ecx, 0x14(%rdi)
movl %ecx, (%rdi)
movss %xmm1, 0x10(%rdi)
movaps 0x15acd(%rip), %xmm2    # 0x19030
movaps %xmm1, %xmm3
xorps %xmm2, %xmm3
movss %xmm3, 0x4(%rdi)
shufps $0x55, %xmm0, %xmm0     # xmm0 = xmm0[1,1,1,1]
movss %xmm0, 0x8(%rdi)
xorps %xmm2, %xmm0
movss %xmm0, 0x20(%rdi)
movss %xmm1, 0x1c(%rdi)
movss %xmm3, 0x34(%rdi)
popq %rbp
retq