LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O0/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:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
cmpl $0x0, -0x1c(%rbp)
je 0xb0e3
jmp 0xb102
leaq 0x12f3(%rip), %rdi      # 0xc3dd
leaq 0x11b8(%rip), %rsi      # 0xc2a9
movl $0x7c3, %edx            # imm = 0x7C3
leaq 0x21d2(%rip), %rcx      # 0xd2cf
callq 0x10f0
movl -0x1c(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
jne 0xb10f
jmp 0xb12e
leaq 0x1231(%rip), %rdi      # 0xc347
leaq 0x118c(%rip), %rsi      # 0xc2a9
movl $0x7c4, %edx            # imm = 0x7C4
leaq 0x21a6(%rip), %rcx      # 0xd2cf
callq 0x10f0
movl -0x1c(%rbp), %eax
shrl %eax
movl %eax, -0x34(%rbp)
movq -0x10(%rbp), %rax
movl (%rax), %eax
cmpl -0x34(%rbp), %eax
jae 0xb14e
movq $0x0, -0x8(%rbp)
jmp 0xb201
movq -0x28(%rbp), %rax
movq 0x70(%rax), %rax
movl -0x34(%rbp), %ecx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
movb (%rax), %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0xb194
movq -0x28(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x1c(%rax), %edx
movl -0x1c(%rbp), %ecx
leaq 0x218f(%rip), %rsi      # 0xd318
callq 0x9fe0
movq %rax, -0x8(%rbp)
jmp 0xb201
movq -0x30(%rbp), %rax
movb (%rax), %al
shrb %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0xb1c6
movq -0x28(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x1c(%rax), %edx
movl -0x1c(%rbp), %ecx
leaq 0x218a(%rip), %rsi      # 0xd345
callq 0x9fe0
movq %rax, -0x8(%rbp)
jmp 0xb201
movq -0x30(%rbp), %rax
movb (%rax), %al
shrb $0x2, %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0xb1f9
movq -0x28(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x1c(%rax), %edx
movl -0x1c(%rbp), %ecx
leaq 0x2184(%rip), %rsi      # 0xd372
callq 0x9fe0
movq %rax, -0x8(%rbp)
jmp 0xb201
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_read_number
static unsigned
aiger_read_number (aiger_reader * reader)
{
  unsigned res;

  assert (isdigit (reader->ch));
  res = reader->ch - '0';

  while (isdigit (aiger_next_ch (reader)))
    res = 10 * res + (reader->ch - '0');

  return res;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
callq 0x11a0
movq (%rax), %rax
movq -0x8(%rbp), %rcx
movslq 0x10(%rcx), %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x800, %eax            # imm = 0x800
cmpl $0x0, %eax
je 0xb23c
jmp 0xb25b
leaq 0x2048(%rip), %rdi      # 0xd28b
leaq 0x105f(%rip), %rsi      # 0xc2a9
movl $0x77a, %edx            # imm = 0x77A
leaq 0x204a(%rip), %rcx      # 0xd2a0
callq 0x10f0
movq -0x8(%rbp), %rax
movl 0x10(%rax), %eax
subl $0x30, %eax
movl %eax, -0xc(%rbp)
callq 0x11a0
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
callq 0xae30
movl %eax, %ecx
movq -0x18(%rbp), %rax
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x800, %eax            # imm = 0x800
cmpl $0x0, %eax
je 0xb2a9
imull $0xa, -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
movl 0x10(%rcx), %ecx
subl $0x30, %ecx
addl %ecx, %eax
movl %eax, -0xc(%rbp)
jmp 0xb268
movl -0xc(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x18(%rbp), %rax
cmpl $-0x1, 0x10(%rax)
jne 0xb300
jmp 0xb2e0
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x18(%rax), %edx
leaq 0x20f5(%rip), %rsi      # 0xd3e7
callq 0xa150
movq %rax, -0x8(%rbp)
jmp 0xb3cd
movl $0x0, -0x28(%rbp)
movl $0x0, -0x24(%rbp)
movq -0x18(%rbp), %rax
movl 0x10(%rax), %eax
movb %al, -0x2d(%rbp)
movq -0x18(%rbp), %rax
movl 0x18(%rax), %eax
movl %eax, -0x2c(%rbp)
movzbl -0x2d(%rbp), %eax
andl $0x80, %eax
cmpl $0x0, %eax
je 0xb392
cmpl $0x5, -0x28(%rbp)
jne 0xb351
jmp 0xb338
movq -0x10(%rbp), %rdi
movl -0x2c(%rbp), %edx
leaq 0x20c6(%rip), %rsi      # 0xd40c
callq 0xa150
movq %rax, -0x8(%rbp)
jmp 0xb3cd
movzbl -0x2d(%rbp), %eax
andl $0x7f, %eax
movl -0x28(%rbp), %ecx
movl %ecx, %edx
addl $0x1, %edx
movl %edx, -0x28(%rbp)
imull $0x7, %ecx, %ecx
shll %cl, %eax
orl -0x24(%rbp), %eax
movl %eax, -0x24(%rbp)
movq -0x18(%rbp), %rdi
callq 0xae30
movq -0x18(%rbp), %rax
cmpl $-0x1, 0x10(%rax)
jne 0xb386
jmp 0xb2e0
movq -0x18(%rbp), %rax
movl 0x10(%rax), %eax
movb %al, -0x2d(%rbp)
jmp 0xb322
cmpl $0x5, -0x28(%rbp)
jne 0xb3a3
movzbl -0x2d(%rbp), %eax
cmpl $0x8, %eax
jl 0xb3a3
jmp 0xb338
movzbl -0x2d(%rbp), %eax
imull $0x7, -0x28(%rbp), %ecx
shll %cl, %eax
orl -0x24(%rbp), %eax
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, (%rax)
movq -0x18(%rbp), %rdi
callq 0xae30
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/reactive-systems[P]aiger-ltl-model-checker/aiger.c
// Function: aiger_read_comments
static const char *
aiger_read_comments (aiger * public, aiger_reader * reader)
{
  IMPORT_private_FROM (public);
  assert( reader->ch == '\n' );

  aiger_next_ch (reader);

  while (reader->ch != EOF)
    {
      while (reader->ch != '\n')
	{
	  aiger_reader_push_ch (private, reader, reader->ch);
	  aiger_next_ch (reader);

	  if (reader->ch == EOF)
	    return aiger_error_u (private,
				  "line %u: new line after comment missing",
				  reader->lineno);
	}

      aiger_next_ch (reader);
      aiger_reader_push_ch (private, reader, 0);
      aiger_add_comment (public, reader->buffer);
      reader->top_buffer = 0;
    }

  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
cmpl $0xa, 0x10(%rax)
jne 0xb404
jmp 0xb423
leaq 0x2165(%rip), %rdi      # 0xd570
leaq 0xe97(%rip), %rsi       # 0xc2a9
movl $0x950, %edx            # imm = 0x950
leaq 0x2165(%rip), %rcx      # 0xd583
callq 0x10f0
movq -0x18(%rbp), %rdi
callq 0xae30
movq -0x18(%rbp), %rax
cmpl $-0x1, 0x10(%rax)
je 0xb4c8
jmp 0xb43c
movq -0x18(%rbp), %rax
cmpl $0xa, 0x10(%rax)
je 0xb48f
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x18(%rbp), %rax
movl 0x10(%rax), %eax
movsbl %al, %edx
callq 0xb670
movq -0x18(%rbp), %rdi
callq 0xae30
movq -0x18(%rbp), %rax
cmpl $-0x1, 0x10(%rax)
jne 0xb48d
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x14(%rax), %edx
leaq 0x213a(%rip), %rsi      # 0xd5bc
callq 0xa150
movq %rax, -0x8(%rbp)
jmp 0xb4d0
jmp 0xb43c
movq -0x18(%rbp), %rdi
callq 0xae30
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
xorl %edx, %edx
callq 0xb670
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x50(%rax), %rsi
callq 0x3d60
movq -0x18(%rbp), %rax
movl $0x0, 0x58(%rax)
jmp 0xb42c
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq %rcx, -0x20(%rbp)
movl %r8d, -0x24(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0xd0(%rax)
jne 0xb50b
jmp 0xb52a
leaq 0x1554(%rip), %rdi      # 0xca66
leaq 0xd90(%rip), %rsi       # 0xc2a9
movl $0x261, %edx            # imm = 0x261
leaq 0x20bf(%rip), %rcx      # 0xd5e4
callq 0x10f0
movq -0x10(%rbp), %rdi
callq 0x10b0
movq %rax, -0x58(%rbp)
movq -0x20(%rbp), %rdi
callq 0x10b0
movq %rax, %rcx
movq -0x58(%rbp), %rax
addq %rcx, %rax
addq $0x10, %rax
addq $0x10, %rax
addq $0x1, %rax
movl %eax, -0x28(%rbp)
movl -0x28(%rbp), %eax
shlq $0x0, %rax
movq %rax, -0x40(%rbp)
movq -0x8(%rbp), %rax
movq 0xc0(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0xb8(%rcx), %rdi
movq -0x40(%rbp), %rsi
callq *%rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rdi
movq -0x40(%rbp), %rdx
xorl %esi, %esi
callq 0x1100
movq -0x38(%rbp), %rdi
movq -0x10(%rbp), %rsi
movl -0x14(%rbp), %edx
movq -0x20(%rbp), %rcx
movl -0x24(%rbp), %r8d
movb $0x0, %al
callq 0x1180
movq -0x38(%rbp), %rdi
callq 0x10b0
addq $0x1, %rax
movl %eax, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
shlq $0x0, %rax
movq %rax, -0x48(%rbp)
movq -0x8(%rbp), %rax
movq 0xc0(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0xb8(%rcx), %rdi
movq -0x48(%rbp), %rsi
callq *%rax
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0xd0(%rax)
movq -0x8(%rbp), %rax
movq 0xd0(%rax), %rdi
movq -0x48(%rbp), %rdx
xorl %esi, %esi
callq 0x1100
movq -0x8(%rbp), %rax
movq 0xd0(%rax), %rdi
movq -0x38(%rbp), %rsi
movl -0x2c(%rbp), %eax
movl %eax, %edx
callq 0x1140
movl -0x28(%rbp), %eax
shlq $0x0, %rax
movq %rax, -0x50(%rbp)
movq -0x8(%rbp), %rax
movq 0xc8(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0xb8(%rcx), %rdi
movq -0x38(%rbp), %rsi
movq -0x50(%rbp), %rdx
callq *%rax
movq $0x0, -0x38(%rbp)
movq -0x8(%rbp), %rax
movq 0xd0(%rax), %rax
addq $0x60, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/yurrriq[P]knrc/src/wc.c
// Function: char_count
double char_count()
{
    double nc = 0;

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

    return nc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
xorps %xmm0, %xmm0
movsd %xmm0, -0x8(%rbp)
callq 0x1040
cmpl $-0x1, %eax
je 0x117e
movsd 0xe96(%rip), %xmm0      # 0x2008
addsd -0x8(%rbp), %xmm0
movsd %xmm0, -0x8(%rbp)
jmp 0x1160
movsd -0x8(%rbp), %xmm0
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/yurrriq[P]knrc/src/wc.c
// Function: line_count
int line_count()
{
    int c, nl = 0;
    while ((c = getchar()) != EOF)
        if (c == '\n')
            ++nl;

    return nl;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl $0x0, -0x8(%rbp)
callq 0x1040
movl %eax, -0x4(%rbp)
cmpl $-0x1, %eax
je 0x11bd
cmpl $0xa, -0x4(%rbp)
jne 0x11bb
movl -0x8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
jmp 0x119f
movl -0x8(%rbp), %eax
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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 %rbp
movq %rsp, %rbp
subq $0x10, %rsp
xorps %xmm0, %xmm0
movsd %xmm0, -0x8(%rbp)
movl $0x0, -0xc(%rbp)
callq 0x1040
movl %eax, -0xc(%rbp)
cmpl $-0x1, %eax
je 0x1246
movl -0xc(%rbp), %edi
callq 0x11d0
testb $0x1, %al
jne 0x1232
jmp 0x1244
movsd 0xdce(%rip), %xmm0      # 0x2008
addsd -0x8(%rbp), %xmm0
movsd %xmm0, -0x8(%rbp)
jmp 0x1217
movsd -0x8(%rbp), %xmm0
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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
movq %rsp, %rbp
subq $0x20, %rsp
movl $0x0, -0x4(%rbp)
movl $0x0, -0x18(%rbp)
movl $0x0, -0x14(%rbp)
movl $0x0, -0x10(%rbp)
movl $0x0, -0xc(%rbp)
callq 0x1040
movl %eax, -0x8(%rbp)
cmpl $-0x1, %eax
je 0x12e5
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
cmpl $0xa, -0x8(%rbp)
jne 0x12b0
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
cmpl $0x20, -0x8(%rbp)
je 0x12c2
cmpl $0xa, -0x8(%rbp)
je 0x12c2
cmpl $0x9, -0x8(%rbp)
jne 0x12cb
movl $0x0, -0x18(%rbp)
jmp 0x12e3
cmpl $0x0, -0x18(%rbp)
jne 0x12e1
movl $0x1, -0x18(%rbp)
movl -0x10(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x10(%rbp)
jmp 0x12e3
jmp 0x128b
movl -0xc(%rbp), %esi
movl -0x10(%rbp), %edx
movl -0x14(%rbp), %ecx
leaq 0xd1b(%rip), %rdi       # 0x2010
movb $0x0, %al
callq 0x1030
xorl %eax, %eax
addq $0x20, %rsp
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/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
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movl %ecx, -0x18(%rbp)
movl -0x18(%rbp), %eax
movl -0x14(%rbp), %ecx
subl %ecx, %eax
movb %al, %cl
decb %cl
movl $0x1, %eax
movl %eax, %edx
shll %cl, %edx
movl %edx, %ecx
movl %ecx, -0x1c(%rbp)
movb -0x14(%rbp), %cl
shll %cl, %eax
movl %eax, -0x20(%rbp)
movl -0x1c(%rbp), %eax
subl $0x1, %eax
jne 0x1eec
jmp 0x1ed2
movl -0x20(%rbp), %esi
movq -0x10(%rbp), %rdx
movq -0x8(%rbp), %rcx
movl $0x1, %edi
callq 0x1fd0
jmp 0x1f90
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movl -0x14(%rbp), %edx
addl $0x1, %edx
movl -0x18(%rbp), %ecx
callq 0x1e90
movq -0x8(%rbp), %rdi
movl -0x20(%rbp), %eax
shlq $0x4, %rax
addq %rax, %rdi
movq -0x10(%rbp), %rsi
movl -0x1c(%rbp), %eax
shlq $0x4, %rax
addq %rax, %rsi
movl -0x14(%rbp), %edx
addl $0x1, %edx
movl -0x18(%rbp), %ecx
callq 0x1e90
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl -0x1c(%rbp), %eax
jae 0x1f8e
movl -0x1c(%rbp), %eax
movl %eax, -0x44(%rbp)
movq -0x10(%rbp), %rax
movl -0x24(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, -0x40(%rbp)
movl -0x24(%rbp), %edi
movl -0x14(%rbp), %ecx
shll %cl, %edi
movl -0x18(%rbp), %esi
callq 0x21e0
movl -0x44(%rbp), %edi
movq -0x40(%rbp), %rsi
movsd %xmm0, -0x38(%rbp)
movsd %xmm1, -0x30(%rbp)
movsd -0x38(%rbp), %xmm0
movsd -0x30(%rbp), %xmm1
callq 0x2080
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x1f33
jmp 0x1f90
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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 %rbp
movq %rsp, %rbp
subq $0x9c60, %rsp           # imm = 0x9C60
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
callq 0x1260
cmpl $0x0, %eax
jne 0x11cf
leaq 0xe43(%rip), %rdi       # 0x2004
callq 0x1040
movl $0x1, -0x4(%rbp)
jmp 0x124a
movq $0xa, -0x18(%rbp)
cmpl $0x2, -0x8(%rbp)
jne 0x11fd
movq -0x10(%rbp), %rax
movl -0x8(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movq (%rax,%rcx,8), %rdi
addq $0x1, %rdi
callq 0x1060
cltq
movq %rax, -0x18(%rbp)
leaq -0x9c60(%rbp), %rdi
movl $0x1388, %esi           # imm = 0x1388
callq 0x12d0
movq %rax, -0x20(%rbp)
cmpq $-0x1, %rax
je 0x122e
leaq -0x9c60(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
callq 0x13a0
jmp 0x1243
leaq 0xdea(%rip), %rdi       # 0x201f
callq 0x1040
movl $0x1, -0x4(%rbp)
jmp 0x124a
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x9c60, %rsp           # imm = 0x9C60
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
movq -0x18(%rbp), %rax
cmpq -0x10(%rbp), %rax
jb 0x13d2
movq -0x18(%rbp), %rax
subq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
cmpq -0x18(%rbp), %rax
jae 0x1414
movq -0x8(%rbp), %rax
movq -0x28(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
callq 0x1040
movq -0x8(%rbp), %rax
movq -0x28(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
callq 0x15c0
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x13da
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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:
movq %rdi, -0x8(%rsp)
movq %rsi, -0x10(%rsp)
movq -0x8(%rsp), %rax
movsd (%rax), %xmm0
movq -0x10(%rsp), %rax
subsd (%rax), %xmm0
movsd %xmm0, -0x18(%rsp)
movq -0x8(%rsp), %rax
movsd 0x8(%rax), %xmm0
movq -0x10(%rsp), %rax
subsd 0x8(%rax), %xmm0
movsd %xmm0, -0x20(%rsp)
movq -0x8(%rsp), %rax
movsd 0x10(%rax), %xmm0
movq -0x10(%rsp), %rax
subsd 0x10(%rax), %xmm0
movsd %xmm0, -0x28(%rsp)
movsd -0x18(%rsp), %xmm0
mulsd -0x18(%rsp), %xmm0
movsd -0x20(%rsp), %xmm1
mulsd -0x20(%rsp), %xmm1
addsd %xmm1, %xmm0
movsd -0x28(%rsp), %xmm1
mulsd -0x28(%rsp), %xmm1
addsd %xmm1, %xmm0
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movl %esi, 0xc(%rsp)
movl $0x0, 0x8(%rsp)
movl 0x8(%rsp), %eax
cmpl 0xc(%rsp), %eax
jge 0x4062b3
movq 0x10(%rsp), %rax
movslq 0x8(%rsp), %rcx
cmpl $0x0, (%rax,%rcx,4)
jl 0x40627c
movq 0x10(%rsp), %rax
movslq 0x8(%rsp), %rcx
movl (%rax,%rcx,4), %esi
addl $0x1, %esi
movq $0x60dd20, %rdi         # imm = 0x60DD20
callq 0x47a210
movq %rax, %rdi
leaq 0x186dfe(%rip), %rsi    # 0x58d073
callq 0x479e70
jmp 0x4062a4
movq 0x10(%rsp), %rax
movslq 0x8(%rsp), %rcx
movl (%rax,%rcx,4), %esi
movq $0x60dd20, %rdi         # imm = 0x60DD20
callq 0x47a210
movq %rax, %rdi
leaq 0x186dd4(%rip), %rsi    # 0x58d073
callq 0x479e70
jmp 0x4062a6
movl 0x8(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x8(%rsp)
jmp 0x406235
movq $0x60dd20, %rdi         # imm = 0x60DD20
movq $0x479750, %rsi         # imm = 0x479750
callq 0x478960
movq %rax, %rdi
movq $0x479750, %rsi         # imm = 0x479750
callq 0x478960
addq $0x18, %rsp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movl %esi, 0xc(%rsp)
movl $0x0, 0x8(%rsp)
movl $0x0, 0x4(%rsp)
movl 0x4(%rsp), %eax
cmpl 0xc(%rsp), %eax
jge 0x406347
movq 0x10(%rsp), %rax
movslq 0x4(%rsp), %rcx
movl (%rax,%rcx,4), %esi
movq $0x60dd20, %rdi         # imm = 0x60DD20
callq 0x47a210
movq %rax, %rdi
leaq 0x186d49(%rip), %rsi    # 0x58d073
callq 0x479e70
movl 0x8(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x8(%rsp)
movl 0x4(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x4(%rsp)
jmp 0x4062fd
movq $0x60dd20, %rdi         # imm = 0x60DD20
movq $0x479750, %rsi         # imm = 0x479750
callq 0x478960
movq %rax, %rdi
movq $0x479750, %rsi         # imm = 0x479750
callq 0x478960
movl 0x8(%rsp), %eax
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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:
subq $0x38, %rsp
movl 0x201126(%rip), %esi    # 0x60a5b0
addl $0x1, %esi
leaq 0x20110c(%rip), %rdi    # 0x60a5a0
callq 0x4108c0
movl 0x201111(%rip), %esi    # 0x60a5b0
addl $0x1, %esi
leaq 0x2010ff(%rip), %rdi    # 0x60a5a8
callq 0x410970
movl 0x2010fc(%rip), %esi    # 0x60a5b0
addl $0x1, %esi
leaq 0x2010da(%rip), %rdi    # 0x60a598
callq 0x410970
movl 0x2010e7(%rip), %esi    # 0x60a5b0
leaq 0x2010f0(%rip), %rdi    # 0x60a5c0
callq 0x410970
movl 0x2010d5(%rip), %esi    # 0x60a5b0
leaq 0x20110e(%rip), %rdi    # 0x60a5f0
callq 0x410970
movl 0x2010c7(%rip), %esi    # 0x60a5b4
leaq 0x2010d4(%rip), %rdi    # 0x60a5c8
callq 0x410970
movl 0x2010b9(%rip), %esi    # 0x60a5b8
leaq 0x201112(%rip), %rdi    # 0x60a618
callq 0x410970
movl 0x2010a7(%rip), %esi    # 0x60a5b8
leaq 0x201108(%rip), %rdi    # 0x60a620
callq 0x410970
movl 0x201095(%rip), %esi    # 0x60a5b8
leaq 0x2010b6(%rip), %rdi    # 0x60a5e0
callq 0x410970
movl 0x201083(%rip), %esi    # 0x60a5b8
leaq 0x2010ac(%rip), %rdi    # 0x60a5e8
callq 0x410970
movq 0x2010b0(%rip), %rax    # 0x60a5f8
movq %rax, 0x30(%rsp)
cmpq $0x0, %rax
je 0x40955d
movq 0x30(%rsp), %rdi
callq 0x410cc0
movq 0x20109c(%rip), %rax    # 0x60a600
movq %rax, 0x28(%rsp)
cmpq $0x0, %rax
je 0x409579
movq 0x28(%rsp), %rdi
callq 0x410cc0
movq 0x201088(%rip), %rax    # 0x60a608
movq %rax, 0x20(%rsp)
cmpq $0x0, %rax
je 0x409595
movq 0x20(%rsp), %rdi
callq 0x410cc0
movq 0x201074(%rip), %rax    # 0x60a610
movq %rax, 0x18(%rsp)
cmpq $0x0, %rax
je 0x4095b1
movq 0x18(%rsp), %rdi
callq 0x410cc0
movq 0x201018(%rip), %rax    # 0x60a5d0
movq %rax, 0x10(%rsp)
cmpq $0x0, %rax
je 0x4095cd
movq 0x10(%rsp), %rdi
callq 0x410cc0
movq 0x201004(%rip), %rax    # 0x60a5d8
movq %rax, 0x8(%rsp)
cmpq $0x0, %rax
je 0x4095e9
movq 0x8(%rsp), %rdi
callq 0x410cc0
addq $0x38, %rsp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/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:
subq $0x68, %rsp
movq %rdi, 0x60(%rsp)
movl %esi, 0x5c(%rsp)
movq %rdx, 0x50(%rsp)
movl $0x0, 0x4(%rsp)
movl 0x4(%rsp), %eax
cmpl 0x5c(%rsp), %eax
jge 0x40b4a2
movq 0x50(%rsp), %rax
movslq 0x4(%rsp), %rcx
movl $0x1, (%rax,%rcx,4)
movl 0x4(%rsp), %eax
subl $0x2, %eax
movl %eax, 0x4c(%rsp)
movl 0x4(%rsp), %eax
subl $0x1, %eax
movl %eax, 0x48(%rsp)
movl 0x4(%rsp), %eax
movl %eax, 0x44(%rsp)
movl 0x4(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x40(%rsp)
movl 0x4(%rsp), %eax
addl $0x2, %eax
movl %eax, 0x3c(%rsp)
cmpl $0x0, 0x4c(%rsp)
jl 0x40b490
movl 0x3c(%rsp), %eax
cmpl 0x5c(%rsp), %eax
jge 0x40b490
movq 0x60(%rsp), %rax
movslq 0x4c(%rsp), %rcx
movq (%rax,%rcx,8), %rdi
movq 0x60(%rsp), %rax
movslq 0x44(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x406000
sqrtsd %xmm0, %xmm0
movsd %xmm0, 0x30(%rsp)
movq 0x60(%rsp), %rax
movslq 0x4c(%rsp), %rcx
movq (%rax,%rcx,8), %rdi
movq 0x60(%rsp), %rax
movslq 0x40(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x406000
sqrtsd %xmm0, %xmm0
movsd %xmm0, 0x28(%rsp)
movq 0x60(%rsp), %rax
movslq 0x4c(%rsp), %rcx
movq (%rax,%rcx,8), %rdi
movq 0x60(%rsp), %rax
movslq 0x3c(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x406000
sqrtsd %xmm0, %xmm0
movsd %xmm0, 0x20(%rsp)
movq 0x60(%rsp), %rax
movslq 0x48(%rsp), %rcx
movq (%rax,%rcx,8), %rdi
movq 0x60(%rsp), %rax
movslq 0x40(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x406000
sqrtsd %xmm0, %xmm0
movsd %xmm0, 0x18(%rsp)
movq 0x60(%rsp), %rax
movslq 0x48(%rsp), %rcx
movq (%rax,%rcx,8), %rdi
movq 0x60(%rsp), %rax
movslq 0x3c(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x406000
sqrtsd %xmm0, %xmm0
movsd %xmm0, 0x10(%rsp)
movq 0x60(%rsp), %rax
movslq 0x44(%rsp), %rcx
movq (%rax,%rcx,8), %rdi
movq 0x60(%rsp), %rax
movslq 0x3c(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x406000
sqrtsd %xmm0, %xmm0
movsd %xmm0, 0x8(%rsp)
movsd 0x30(%rsp), %xmm0
movsd 0x28(%rsp), %xmm1
movsd 0x20(%rsp), %xmm2
movsd 0x18(%rsp), %xmm3
movsd 0x10(%rsp), %xmm4
movsd 0x8(%rsp), %xmm5
callq 0x40b020
movl %eax, %edx
movq 0x50(%rsp), %rax
movslq 0x4(%rsp), %rcx
movl %edx, (%rax,%rcx,4)
jmp 0x40b492
movl 0x4(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x4(%rsp)
jmp 0x40b2ea
movq 0x50(%rsp), %rdi
movl 0x5c(%rsp), %esi
callq 0x40acc0
addq $0x68, %rsp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/asford[P]tmalign/./TMalign.h
// Function: get_initial_ss(double**, double**, int, int, int*)
void get_initial_ss(  double **x, 
					  double **y, 
					  int x_len,
					  int y_len, 
					  int *y2x
                      )
{
    //assign secondary structures
	make_sec(x, x_len, secx);
	make_sec(y, y_len, secy);

	double gap_open=-1.0;
	NWDP_TM(secx, secy, x_len, y_len, gap_open, y2x);    
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movl %edx, 0x14(%rsp)
movl %ecx, 0x10(%rsp)
movq %r8, 0x8(%rsp)
movq 0x20(%rsp), %rdi
movl 0x14(%rsp), %esi
movq 0x1ff11d(%rip), %rdx    # 0x60a608
callq 0x40b2d0
movq 0x18(%rsp), %rdi
movl 0x10(%rsp), %esi
movq 0x1ff110(%rip), %rdx    # 0x60a610
callq 0x40b2d0
movsd 0x180b33(%rip), %xmm0   # 0x58c040
movsd %xmm0, (%rsp)
movq 0x1ff0ef(%rip), %rdi    # 0x60a608
movq 0x1ff0f0(%rip), %rsi    # 0x60a610
movl 0x14(%rsp), %edx
movl 0x10(%rsp), %ecx
movsd (%rsp), %xmm0
movq 0x8(%rsp), %r8
callq 0x406c70
addq $0x28, %rsp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/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:
subq $0x18, %rsp
movl %edi, 0x14(%rsp)
movl %esi, 0x10(%rsp)
movsd 0x17d674(%rip), %xmm0   # 0x58c038
movsd %xmm0, 0x1fbb9c(%rip)   # 0x60a568
movsd 0x17d6ec(%rip), %xmm0   # 0x58c0c0
movsd %xmm0, 0x1fbbb4(%rip)   # 0x60a590
movl 0x14(%rsp), %eax
cmpl 0x10(%rsp), %eax
jle 0x40e9f0
movl 0x10(%rsp), %eax
movl %eax, 0xc(%rsp)
jmp 0x40e9f8
movl 0x14(%rsp), %eax
movl %eax, 0xc(%rsp)
movl 0xc(%rsp), %eax
cvtsi2sd %eax, %xmm0
movsd %xmm0, 0x1fbb68(%rip)   # 0x60a570
movsd 0x17d6b8(%rip), %xmm0   # 0x58c0c8
ucomisd 0x1fbb58(%rip), %xmm0   # 0x60a570
jb 0x40ea2c
movsd 0x17d6c6(%rip), %xmm0   # 0x58c0e8
movsd %xmm0, 0x1fbb56(%rip)   # 0x60a580
jmp 0x40ea70
movsd 0x17d5d4(%rip), %xmm0   # 0x58c008
mulsd 0x1fbb34(%rip), %xmm0   # 0x60a570
movsd 0x17d69c(%rip), %xmm1   # 0x58c0e0
subsd %xmm1, %xmm0
callq 0x4af770
movaps %xmm0, %xmm1
movsd 0x17d680(%rip), %xmm0   # 0x58c0d8
mulsd %xmm1, %xmm0
movsd 0x17d66c(%rip), %xmm1   # 0x58c0d0
subsd %xmm1, %xmm0
movsd %xmm0, 0x1fbb10(%rip)   # 0x60a580
movsd 0x17d678(%rip), %xmm0   # 0x58c0f0
addsd 0x1fbb00(%rip), %xmm0   # 0x60a580
movsd %xmm0, 0x1fbae0(%rip)   # 0x60a568
movsd 0x1fbad8(%rip), %xmm0   # 0x60a568
movsd %xmm0, 0x1fbae8(%rip)   # 0x60a580
movsd 0x1fbae0(%rip), %xmm0   # 0x60a580
movsd %xmm0, 0x1fbae0(%rip)   # 0x60a588
movsd 0x1fbad8(%rip), %xmm0   # 0x60a588
movsd 0x17d5d0(%rip), %xmm1   # 0x58c088
ucomisd %xmm1, %xmm0
jbe 0x40eace
movsd 0x17d5c2(%rip), %xmm0   # 0x58c088
movsd %xmm0, 0x1fbaba(%rip)   # 0x60a588
movsd 0x17d622(%rip), %xmm0   # 0x58c0f8
ucomisd 0x1fbaaa(%rip), %xmm0   # 0x60a588
jbe 0x40eaf0
movsd 0x17d610(%rip), %xmm0   # 0x58c0f8
movsd %xmm0, 0x1fba98(%rip)   # 0x60a588
movsd 0x17d510(%rip), %xmm0   # 0x58c008
mulsd 0x1fba70(%rip), %xmm0   # 0x60a570
movsd 0x17d600(%rip), %xmm1   # 0x58c108
callq 0x4b0d10
movaps %xmm0, %xmm1
movsd 0x17d578(%rip), %xmm0   # 0x58c090
mulsd %xmm1, %xmm0
movsd 0x17d5dc(%rip), %xmm1   # 0x58c100
addsd %xmm1, %xmm0
movsd %xmm0, 0x1fba48(%rip)   # 0x60a578
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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
movsd %xmm0, (%rsp)
movsd 0x17d4ea(%rip), %xmm0   # 0x58c038
movsd %xmm0, 0x1fba12(%rip)   # 0x60a568
movsd (%rsp), %xmm0
movsd %xmm0, 0x1fba0d(%rip)   # 0x60a570
movsd 0x17d5a5(%rip), %xmm0   # 0x58c110
ucomisd 0x1fb9fd(%rip), %xmm0   # 0x60a570
jb 0x40eb87
movsd 0x17d4bb(%rip), %xmm0   # 0x58c038
movsd %xmm0, 0x1fb9fb(%rip)   # 0x60a580
jmp 0x40ebcb
movsd 0x17d479(%rip), %xmm0   # 0x58c008
mulsd 0x1fb9d9(%rip), %xmm0   # 0x60a570
movsd 0x17d541(%rip), %xmm1   # 0x58c0e0
subsd %xmm1, %xmm0
callq 0x4af770
movaps %xmm0, %xmm1
movsd 0x17d525(%rip), %xmm0   # 0x58c0d8
mulsd %xmm1, %xmm0
movsd 0x17d511(%rip), %xmm1   # 0x58c0d0
subsd %xmm1, %xmm0
movsd %xmm0, 0x1fb9b5(%rip)   # 0x60a580
movsd 0x1fb9ad(%rip), %xmm1   # 0x60a580
movsd 0x1fb98d(%rip), %xmm0   # 0x60a568
ucomisd %xmm1, %xmm0
jbe 0x40ebf1
movsd 0x1fb97f(%rip), %xmm0   # 0x60a568
movsd %xmm0, 0x1fb98f(%rip)   # 0x60a580
movsd 0x1fb987(%rip), %xmm0   # 0x60a580
movsd %xmm0, 0x1fb987(%rip)   # 0x60a588
movsd 0x1fb97f(%rip), %xmm0   # 0x60a588
movsd 0x17d477(%rip), %xmm1   # 0x58c088
ucomisd %xmm1, %xmm0
jbe 0x40ec27
movsd 0x17d469(%rip), %xmm0   # 0x58c088
movsd %xmm0, 0x1fb961(%rip)   # 0x60a588
movsd 0x17d4c9(%rip), %xmm0   # 0x58c0f8
ucomisd 0x1fb951(%rip), %xmm0   # 0x60a588
jbe 0x40ec49
movsd 0x17d4b7(%rip), %xmm0   # 0x58c0f8
movsd %xmm0, 0x1fb93f(%rip)   # 0x60a588
popq %rax
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/asford[P]tmalign/TMalign.cpp
// Function: parameter_set4scale(int, double)
void parameter_set4scale(int len, double d_s)
{
 
	d0=d_s;          
	Lnorm=len;            //normaliz TMscore by this in searching

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

}

// Assembly:
movl %edi, -0x4(%rsp)
movsd %xmm0, -0x10(%rsp)
movsd -0x10(%rsp), %xmm0
movsd %xmm0, 0x1fb918(%rip)   # 0x60a580
cvtsi2sdl -0x4(%rsp), %xmm0
movsd %xmm0, 0x1fb8fa(%rip)   # 0x60a570
movsd 0x1fb902(%rip), %xmm0   # 0x60a580
movsd %xmm0, 0x1fb902(%rip)   # 0x60a588
movsd 0x1fb8fa(%rip), %xmm0   # 0x60a588
movsd 0x17d3f2(%rip), %xmm1   # 0x58c088
ucomisd %xmm1, %xmm0
jbe 0x40ecac
movsd 0x17d3e4(%rip), %xmm0   # 0x58c088
movsd %xmm0, 0x1fb8dc(%rip)   # 0x60a588
movsd 0x17d444(%rip), %xmm0   # 0x58c0f8
ucomisd 0x1fb8cc(%rip), %xmm0   # 0x60a588
jbe 0x40ecce
movsd 0x17d432(%rip), %xmm0   # 0x58c0f8
movsd %xmm0, 0x1fb8ba(%rip)   # 0x60a588
retq
nop
// File: /workspace/github_c_makefile_star2_O0/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:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movl %esi, 0x1c(%rsp)
movl $0x0, 0x18(%rsp)
movl 0x18(%rsp), %eax
cmpl 0x1c(%rsp), %eax
jge 0x41092a
movq 0x20(%rsp), %rax
movq (%rax), %rax
movslq 0x18(%rsp), %rcx
cmpq $0x0, (%rax,%rcx,8)
je 0x41091b
movq 0x20(%rsp), %rax
movq (%rax), %rax
movslq 0x18(%rsp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, 0x10(%rsp)
cmpq $0x0, %rax
je 0x410919
movq 0x10(%rsp), %rdi
callq 0x410cc0
jmp 0x41091b
jmp 0x41091d
movl 0x18(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x18(%rsp)
jmp 0x4108d5
cmpl $0x0, 0x1c(%rsp)
je 0x410950
movq 0x20(%rsp), %rax
movq (%rax), %rax
movq %rax, 0x8(%rsp)
cmpq $0x0, %rax
je 0x41094e
movq 0x8(%rsp), %rdi
callq 0x410cc0
jmp 0x410950
movq 0x20(%rsp), %rax
movq $0x0, (%rax)
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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
subq $0x40, %rsp
movl $0x0, -0x4(%rbp)
movl $0x8, %edi
callq 0x1380
leaq 0xd74(%rip), %rdi       # 0x2004
xorl %esi, %esi
callq 0x14c0
leaq 0xd70(%rip), %rdi       # 0x200e
movl $0x1, %esi
callq 0x14c0
leaq 0xd69(%rip), %rdi       # 0x2018
xorl %esi, %esi
callq 0x14c0
leaq 0xd65(%rip), %rdi       # 0x2022
movl $0x1, %esi
callq 0x14c0
leaq 0xd5e(%rip), %rdi       # 0x202c
xorl %esi, %esi
callq 0x14c0
leaq 0xd5a(%rip), %rdi       # 0x2036
movl $0x1, %esi
callq 0x14c0
leaq 0xd53(%rip), %rdi       # 0x2040
xorl %esi, %esi
callq 0x14c0
leaq 0xd4f(%rip), %rdi       # 0x204a
movl $0x1, %esi
callq 0x14c0
movl $0x0, -0x34(%rbp)
cmpl $0x4, -0x34(%rbp)
jge 0x133f
movslq -0x34(%rbp), %rax
leaq -0x30(%rbp), %rdi
shlq $0x3, %rax
addq %rax, %rdi
xorl %eax, %eax
movl %eax, %ecx
leaq 0x204(%rip), %rdx       # 0x1530
movq %rcx, %rsi
callq 0x1100
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x130c
movl $0x0, -0x34(%rbp)
cmpl $0x4, -0x34(%rbp)
jge 0x1369
movslq -0x34(%rbp), %rax
movq -0x30(%rbp,%rax,8), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x1130
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x1346
xorl %eax, %eax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/ramirezsebas[P]TP-LISTINGS/./src/capitulo_4/4.12/job-queue3.c
// Function: create_files
void create_files(int n){
	char filename[20] = "";
	FILE *fp = NULL;
	int i, count, j;

	for(i = 1; i <= n; ++i){
		srand(time(NULL)*(i+2));
		sprintf(filename, "file%d.txt", i);
		fp = fopen(filename, "w");
		count = rand() % TAM_MAX;
		count = count > 10 ? count : 10;
		for(j = 0; j < count-1; ++j){
			fprintf(fp, "%d\n", rand() % 1000);
		}
		fprintf(fp, "%d", rand() % 1000);
		fclose(fp);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movl %edi, -0x4(%rbp)
leaq -0x20(%rbp), %rdi
xorl %esi, %esi
movl $0x14, %edx
callq 0x1080
movq $0x0, -0x28(%rbp)
movl $0x1, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
cmpl -0x4(%rbp), %eax
jg 0x14ae
xorl %eax, %eax
movl %eax, %edi
callq 0x10c0
movl -0x2c(%rbp), %ecx
addl $0x2, %ecx
movslq %ecx, %rcx
imulq %rcx, %rax
movl %eax, %edi
callq 0x10a0
leaq -0x20(%rbp), %rdi
movl -0x2c(%rbp), %edx
leaq 0xc73(%rip), %rsi       # 0x2054
movb $0x0, %al
callq 0x1120
leaq -0x20(%rbp), %rdi
leaq 0xc6c(%rip), %rsi       # 0x205f
callq 0x1110
movq %rax, -0x28(%rbp)
callq 0x1160
movl $0x64, %ecx
cltd
idivl %ecx
movl %edx, -0x30(%rbp)
cmpl $0xa, -0x30(%rbp)
jle 0x141a
movl -0x30(%rbp), %eax
movl %eax, -0x38(%rbp)
jmp 0x1424
movl $0xa, %eax
movl %eax, -0x38(%rbp)
jmp 0x1424
movl -0x38(%rbp), %eax
movl %eax, -0x30(%rbp)
movl $0x0, -0x34(%rbp)
movl -0x34(%rbp), %eax
movl -0x30(%rbp), %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
jge 0x1470
movq -0x28(%rbp), %rax
movq %rax, -0x40(%rbp)
callq 0x1160
movq -0x40(%rbp), %rdi
movl $0x3e8, %ecx            # imm = 0x3E8
cltd
idivl %ecx
leaq 0xc03(%rip), %rsi       # 0x2061
movb $0x0, %al
callq 0x10b0
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x1431
movq -0x28(%rbp), %rax
movq %rax, -0x48(%rbp)
callq 0x1160
movq -0x48(%rbp), %rdi
movl $0x3e8, %ecx            # imm = 0x3E8
cltd
idivl %ecx
leaq 0xbd5(%rip), %rsi       # 0x2065
movb $0x0, %al
callq 0x10b0
movq -0x28(%rbp), %rdi
callq 0x1060
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x13aa
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rdi
movl -0xc(%rbp), %esi
callq 0x15c0
movq %rax, -0x18(%rbp)
leaq 0x2bea(%rip), %rdi      # 0x40d0
callq 0x1150
movq 0x2c06(%rip), %rcx      # 0x40f8
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movq -0x18(%rbp), %rax
movq %rax, 0x2bf4(%rip)      # 0x40f8
leaq 0x2bf5(%rip), %rdi      # 0x4100
callq 0x1090
leaq 0x2bb9(%rip), %rdi      # 0x40d0
callq 0x10d0
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/ramirezsebas[P]TP-LISTINGS/./src/capitulo_4/4.12/job-queue3.c
// Function: create_job
job* create_job(const char *filename, int reverse){
	job *new_job = malloc(sizeof(job));

	new_job->next = NULL;
	new_job->filename = filename;
	new_job->reverse = reverse;

	return new_job;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl $0x18, %edi
callq 0x10e0
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq $0x0, (%rax)
movq -0x8(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x8(%rax)
movl -0xc(%rbp), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x10(%rax)
movq -0x18(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/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
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rdi
leaq 0xa3d(%rip), %rsi       # 0x2068
callq 0x1110
movq %rax, -0x10(%rbp)
movl $0x0, -0x18(%rbp)
movq $0x0, -0x28(%rbp)
movq -0x10(%rbp), %rdi
callq 0x1140
movl %eax, -0x14(%rbp)
cmpl $-0x1, -0x14(%rbp)
je 0x1674
cmpl $0xa, -0x14(%rbp)
jne 0x1664
movl -0x18(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18(%rbp)
jmp 0x1666
movq -0x10(%rbp), %rdi
callq 0x1140
movl %eax, -0x14(%rbp)
jmp 0x164f
movslq -0x18(%rbp), %rdi
shlq $0x2, %rdi
callq 0x10e0
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rdi
callq 0x1070
movl $0x0, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
cmpl -0x18(%rbp), %eax
jge 0x16c9
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rdx
movslq -0x1c(%rbp), %rax
shlq $0x2, %rax
addq %rax, %rdx
leaq 0x9ae(%rip), %rsi       # 0x2065
movb $0x0, %al
callq 0x1040
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x1695
movq -0x28(%rbp), %rdi
movl -0x18(%rbp), %edx
subl $0x1, %edx
xorl %esi, %esi
callq 0x1790
movq -0x10(%rbp), %rdi
callq 0x1060
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rdi
leaq 0x96d(%rip), %rsi       # 0x205f
callq 0x1110
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rax
cmpl $0x0, 0x10(%rax)
je 0x173e
movl -0x18(%rbp), %eax
subl $0x1, %eax
movl %eax, -0x1c(%rbp)
cmpl $0x0, -0x1c(%rbp)
jl 0x173c
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movl (%rax,%rcx,4), %edx
leaq 0x937(%rip), %rsi       # 0x2061
movb $0x0, %al
callq 0x10b0
movl -0x1c(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x170e
jmp 0x1777
movl $0x0, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
cmpl -0x18(%rbp), %eax
jge 0x1775
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movl (%rax,%rcx,4), %edx
leaq 0x8fe(%rip), %rsi       # 0x2061
movb $0x0, %al
callq 0x10b0
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x1745
jmp 0x1777
movq -0x28(%rbp), %rdi
callq 0x1030
movq -0x10(%rbp), %rdi
callq 0x1060
addq $0x30, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/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:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movl -0xc(%rbp), %eax
movl %eax, -0x18(%rbp)
movl -0x10(%rbp), %eax
subl -0xc(%rbp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, %ecx
movl -0x18(%rbp), %eax
addl %ecx, %eax
movl %eax, -0x14(%rbp)
movl -0xc(%rbp), %eax
cmpl -0x10(%rbp), %eax
jge 0x17fb
movq -0x8(%rbp), %rdi
movl -0xc(%rbp), %esi
movl -0x14(%rbp), %edx
callq 0x1790
movq -0x8(%rbp), %rdi
movl -0x14(%rbp), %esi
addl $0x1, %esi
movl -0x10(%rbp), %edx
callq 0x1790
movq -0x8(%rbp), %rdi
movl -0xc(%rbp), %esi
movl -0x14(%rbp), %edx
movl -0x10(%rbp), %ecx
callq 0x1810
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)