LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O3/hughbarney[P]zepl/lisp.c
// Function: newRootEnv
Object *newRootEnv(GC_PARAM)
{
	GC_TRACE(gcEnv, newEnv(&nil, &nil, GC_ROOTS));
	GC_TRACE(gcVar, nil);
	GC_TRACE(gcVal, nil);

	// add constants
	envSet(&nil, &nil, gcEnv, GC_ROOTS);
	envSet(&t, &t, gcEnv, GC_ROOTS);

	// add primitives
	int nPrimitives = sizeof(primitives) / sizeof(primitives[0]);

	for (int i = 0; i < nPrimitives; ++i) {
		*gcVar = newSymbol(primitives[i].name, GC_ROOTS);
		*gcVal = newPrimitive(i, primitives[i].name, GC_ROOTS);

		envSet(gcVar, gcVal, gcEnv, GC_ROOTS);
	}

	// add standard library
	Stream stream = { STREAM_TYPE_STRING,.buffer = stdlib };
	GC_TRACE(gcObject, nil);

	while (peekNext(&stream) != EOF) {
		*gcObject = nil;
		*gcObject = readExpr(&stream, GC_ROOTS);
		evalExpr(gcObject, gcEnv, GC_ROOTS);
	}

	return *gcEnv;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movq %rdi, %r14
movl $0x3, %r15d
leaq 0x88(%rsp), %r13
movl %r15d, -0x10(%r13)
xorl %ebp, %ebp
movq %rbp, -0x8(%r13)
leaq 0x5ede(%rip), %rbx      # 0xd208
movq %rbx, %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x4cca
movq %rax, (%r13)
movq %r14, 0x8(%r13)
leaq 0x38(%rsp), %rdx
movl %r15d, -0x10(%rdx)
movq %rbp, -0x8(%rdx)
movq 0x5eb4(%rip), %rax      # 0xd208
movq %rax, (%rdx)
leaq 0x78(%rsp), %rcx
movq %rcx, 0x8(%rdx)
leaq 0x60(%rsp), %r12
movl %r15d, -0x10(%r12)
movq %rbp, -0x8(%r12)
movq %rax, (%r12)
leaq 0x28(%rsp), %rax
movq %rax, 0x8(%r12)
leaq 0x50(%rsp), %r15
movq %rbx, %rdi
movq %rbx, %rsi
movq %r13, %rdx
movq %r15, %rcx
callq 0x5896
leaq 0x5e76(%rip), %rdi      # 0xd210
movq %rdi, %rsi
movq %r13, %rdx
movq %r15, %rcx
callq 0x5896
leaq 0x5e71(%rip), %rbx      # 0xd220
movq %r13, %r14
movq (%rbx), %r13
movq %r13, %rdi
callq 0x20e0
movq %r13, %rdi
movq %rax, %rsi
movq %r15, %rdx
callq 0x4ac2
movq %rax, 0x38(%rsp)
movq (%rbx), %r13
movl $0x28, %esi
movl $0x6, %edi
movq %r15, %rdx
callq 0x4814
movl %ebp, 0x10(%rax)
movq %r13, 0x18(%rax)
movq %r14, %r13
movq %rax, 0x60(%rsp)
leaq 0x38(%rsp), %rdi
movq %r12, %rsi
movq %r14, %rdx
movq %r15, %rcx
callq 0x5896
incq %rbp
addq $0x18, %rbx
cmpq $0x43, %rbp
jne 0x73af
xorps %xmm0, %xmm0
leaq 0xa0(%rsp), %rdi
movaps %xmm0, (%rdi)
movaps %xmm0, 0x20(%rdi)
movaps %xmm0, 0x10(%rdi)
xorl %eax, %eax
movq %rax, 0x30(%rdi)
leaq 0x159d(%rip), %rcx      # 0x89d4
movq %rcx, 0x8(%rdi)
movl $0x3, (%rsp)
movq %rax, 0x8(%rsp)
movq %r15, 0x18(%rsp)
callq 0x4fd9
cmpl $-0x1, %eax
je 0x74bb
leaq 0x10(%rsp), %r14
xorl %ebx, %ebx
leaq 0xa0(%rsp), %r15
movq %rsp, %r12
movq 0xc8(%rsp), %rax
leaq -0x1(%rax), %rcx
cmpq $0x2, %rax
cmovlq %rbx, %rcx
movq %rcx, 0xc8(%rsp)
movq 0x5d7d(%rip), %rax      # 0xd208
movq %rax, 0x10(%rsp)
movq %r15, %rdi
movq %r12, %rsi
callq 0x518b
movq %rax, 0x10(%rsp)
movq %r14, %rdi
movq %r13, %rsi
movq %r12, %rdx
callq 0x6b25
movq %r15, %rdi
callq 0x4fd9
cmpl $-0x1, %eax
jne 0x7468
movq 0x88(%rsp), %rax
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/hughbarney[P]zepl/lisp.c
// Function: reset_output_stream
void reset_output_stream()
{
	Stream *stream = &ostream; /* we only want 1 output stream */
	stream->type = STREAM_TYPE_STRING;
	stream->length = 0;
	if (stream->buffer != NULL) {
		free(stream->buffer);
		stream->buffer = NULL;
	}
}

// Assembly:
movl $0x0, 0x5cab(%rip)      # 0xd1d0
movq $0x0, 0x5cb8(%rip) # 0xd1e8
movq 0x5ca1(%rip), %rdi      # 0xd1d8
testq %rdi, %rdi
je 0x7551
pushq %rax
callq 0x2050
movq $0x0, 0x5c8b(%rip) # 0xd1d8
addq $0x8, %rsp
retq
// File: /workspace/github_c_makefile_star2_O3/hughbarney[P]zepl/lisp.c
// Function: load_file_body
void load_file_body(Object ** env, GC_PARAM, Stream *input_stream)
{
	//debug("load_file_body\n");
	GC_TRACE(gcObject, nil);

	if (setjmp(exceptionEnv))
		return;

	while (peekNext(input_stream) != EOF) {
		*gcObject = nil;
		*gcObject = readExpr(input_stream, GC_ROOTS);
		*gcObject = evalExpr(gcObject, theEnv, GC_ROOTS);
		writeObject(*gcObject, true, &ostream);
		writeChar('\n', &ostream);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %rbx
movl $0x3, (%rsp)
movq $0x0, 0x8(%rsp)
movq %rsi, 0x18(%rsp)
leaq 0x78e1(%rip), %rdi      # 0xee60
callq 0x2180
testl %eax, %eax
jne 0x7625
movq %rbx, %rdi
callq 0x4fd9
cmpl $-0x1, %eax
je 0x7625
xorl %eax, %eax
movl %eax, %r14d
movq %rsp, %r15
leaq 0x5c24(%rip), %r12      # 0xd1d0
movl $0x1, %ebp
movl $0xa, %r13d
movq 0x28(%rbx), %rax
leaq -0x1(%rax), %rcx
cmpq $0x2, %rax
cmovlq %r14, %rcx
movq %rcx, 0x28(%rbx)
movq 0x5c36(%rip), %rax      # 0xd208
movq %rax, 0x10(%rsp)
movq %rbx, %rdi
movq %r15, %rsi
callq 0x518b
movq %rax, 0x10(%rsp)
movq 0x7942(%rip), %rsi      # 0xef30
leaq 0x10(%rsp), %rdi
movq %r15, %rdx
callq 0x6b25
movq %rax, 0x10(%rsp)
movq %rax, %rdi
movl %ebp, %esi
movq %r12, %rdx
callq 0x4489
movl %r13d, %edi
movq %r12, %rsi
callq 0x4350
movq %rbx, %rdi
callq 0x4fd9
cmpl $-0x1, %eax
jne 0x75b7
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/hughbarney[P]zepl/lisp.c
// Function: call_lisp_body
void call_lisp_body(Object ** env, GC_PARAM, Stream *input_stream)
{
	GC_TRACE(gcObject, nil);

	for (;;) {
		if (setjmp(exceptionEnv))
			return;

		*gcObject = nil;

		if (peekNext(input_stream) == EOF) {
			writeChar('\n', &ostream);
			return;
		}

		*gcObject = readExpr(input_stream, GC_ROOTS);
		*gcObject = evalExpr(gcObject, env, GC_ROOTS);
		writeObject(*gcObject, true, &ostream);
		writeChar('\n', &ostream);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %rbx
movq %rdi, %r14
movl $0x3, (%rsp)
movq $0x0, 0x8(%rsp)
movq %rsi, 0x18(%rsp)
leaq 0x77fc(%rip), %rdi      # 0xee60
callq 0x2180
testl %eax, %eax
jne 0x7715
xorl %eax, %eax
movl %eax, %r15d
movq %rsp, %r12
leaq 0x5b50(%rip), %r13      # 0xd1d0
leaq 0x77d9(%rip), %rbp      # 0xee60
movq 0x5b7a(%rip), %rax      # 0xd208
movq %rax, 0x10(%rsp)
movq %rbx, %rdi
callq 0x4fd9
cmpl $-0x1, %eax
je 0x7704
movq 0x28(%rbx), %rax
leaq -0x1(%rax), %rcx
cmpq $0x2, %rax
cmovlq %r15, %rcx
movq %rcx, 0x28(%rbx)
movq %rbx, %rdi
movq %r12, %rsi
callq 0x518b
movq %rax, 0x10(%rsp)
leaq 0x10(%rsp), %rdi
movq %r14, %rsi
movq %r12, %rdx
callq 0x6b25
movq %rax, 0x10(%rsp)
movq %rax, %rdi
movl $0x1, %esi
movq %r13, %rdx
callq 0x4489
movl $0xa, %edi
movq %r13, %rsi
callq 0x4350
movq %rbp, %rdi
callq 0x2180
testl %eax, %eax
je 0x7687
jmp 0x7715
leaq 0x5ac5(%rip), %rsi      # 0xd1d0
movl $0xa, %edi
callq 0x4350
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/hughbarney[P]zepl/lisp.c
// Function: init_lisp
int init_lisp()
{
	theRoot = nil;

	//set_stream_file(&istream, STDIN_FILENO);
	set_stream_file(&ostream, STDOUT_FILENO);

	if (setjmp(exceptionEnv))
		return 1;

	symbols = nil;
	symbols = newCons(&nil, &symbols, theRoot);
	symbols = newCons(&t, &symbols, theRoot);

	temp_root.type = TYPE_CONS;
	temp_root.car = newRootEnv(theRoot);
	temp_root.cdr = theRoot;

	theEnv = &temp_root.car;
	theRoot = &temp_root;
	return 0;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq 0x5ad9(%rip), %rax      # 0xd208
movq %rax, 0x7802(%rip)      # 0xef38
movl $0x1, %ebx
movl %ebx, 0x5a8f(%rip)      # 0xd1d0
movl %ebx, 0x5a99(%rip)      # 0xd1e0
leaq 0x7712(%rip), %rdi      # 0xee60
callq 0x2180
movl %ebx, %ecx
testl %eax, %eax
jne 0x781b
movq 0x5aa4(%rip), %rax      # 0xd208
movq %rax, 0x77bd(%rip)      # 0xef28
movq 0x77c6(%rip), %rdx      # 0xef38
movl $0x3, %ebx
movl $0x28, %r14d
movl %ebx, %edi
movq %r14, %rsi
callq 0x4814
movq 0x5a7a(%rip), %rcx      # 0xd208
movq %rcx, 0x10(%rax)
movq 0x778f(%rip), %rcx      # 0xef28
movq %rcx, 0x18(%rax)
movq %rax, 0x7784(%rip)      # 0xef28
movq 0x778d(%rip), %rdx      # 0xef38
movl %ebx, %edi
movq %r14, %rsi
callq 0x4814
movq 0x5a54(%rip), %rcx      # 0xd210
movq %rcx, 0x10(%rax)
movq 0x7761(%rip), %rcx      # 0xef28
movq %rcx, 0x18(%rax)
movq %rax, 0x7756(%rip)      # 0xef28
movl $0x3, 0x7764(%rip)      # 0xef40
leaq 0x775d(%rip), %rbx      # 0xef40
movq 0x774e(%rip), %rdi      # 0xef38
callq 0x72f7
movq %rax, 0x775a(%rip)      # 0xef50
leaq 0x7753(%rip), %rax      # 0xef50
movq 0x7734(%rip), %rcx      # 0xef38
movq %rcx, 0x774d(%rip)      # 0xef58
movq %rax, 0x771e(%rip)      # 0xef30
movq %rbx, 0x771f(%rip)      # 0xef38
xorl %ecx, %ecx
movl %ecx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/stevenmherring[P]DNS/fine-trie.c
// Function: new_leaf
struct trie_node * new_leaf (const char *string, size_t strlen, int32_t ip4_address) {
    struct trie_node *new_node = malloc(sizeof(struct trie_node));
    if (!new_node) {
      printf ("WARNING: Node memory allocation failed.  Results may be bogus.\n");
      return NULL;
    }

    assert(strlen < 64);
    assert(strlen > 0);
    new_node->next = NULL;
    new_node->strlen = strlen;
    strncpy(new_node->key, string, strlen);
    new_node->key[strlen] = '\0';
    new_node->ip4_address = ip4_address;
    new_node->children = NULL;
    int rv = pthread_mutex_init(&(new_node->lock), NULL);
    assert(rv == 0);
    rv = pthread_cond_init(&(new_node->c), NULL);
    assert(rv == 0);
    new_node->waiting = 0;
    return new_node;
  }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %r15
movl $0xb8, %edi
callq 0x1120
movq %rax, %rbx
testq %rax, %rax
je 0x1364
cmpq $0x40, %r14
jae 0x137c
testq %r14, %r14
je 0x139b
xorl %r12d, %r12d
movq %r12, (%rbx)
movl %r14d, 0x8(%rbx)
leaq 0x18(%rbx), %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x1050
movb $0x0, 0x18(%rbx,%r14)
movl %ebp, 0xc(%rbx)
movq %r12, 0x10(%rbx)
leaq 0x58(%rbx), %rdi
xorl %esi, %esi
callq 0x11c0
testl %eax, %eax
jne 0x13ba
movq %rbx, %rdi
subq $-0x80, %rdi
xorl %esi, %esi
callq 0x10f0
testl %eax, %eax
jne 0x13d9
movl $0x0, 0xb0(%rbx)
jmp 0x1370
leaq 0x30b0(%rip), %rdi      # 0x441b
callq 0x1080
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x2d74(%rip), %rdi      # 0x40f7
leaq 0x2c7a(%rip), %rsi      # 0x4004
leaq 0x2c7f(%rip), %rcx      # 0x4010
movl $0x21, %edx
callq 0x10b0
leaq 0x2eaf(%rip), %rdi      # 0x4251
leaq 0x2c5b(%rip), %rsi      # 0x4004
leaq 0x2c60(%rip), %rcx      # 0x4010
movl $0x22, %edx
callq 0x10b0
leaq 0x2c89(%rip), %rdi      # 0x404a
leaq 0x2c3c(%rip), %rsi      # 0x4004
leaq 0x2c41(%rip), %rcx      # 0x4010
movl $0x2a, %edx
callq 0x10b0
leaq 0x2c6a(%rip), %rdi      # 0x404a
leaq 0x2c1d(%rip), %rsi      # 0x4004
leaq 0x2c22(%rip), %rcx      # 0x4010
movl $0x2c, %edx
callq 0x10b0
// File: /workspace/github_c_makefile_star2_O3/stevenmherring[P]DNS/fine-trie.c
// Function: compare_keys
int compare_keys (const char *string1, int len1, const char *string2, int len2, int *pKeylen) {
    int keylen, offset1, offset2;
    keylen = len1 < len2 ? len1 : len2;
    offset1 = len1 - keylen;
    offset2 = len2 - keylen;
    assert (keylen > 0);
    if (pKeylen)
    *pKeylen = keylen;
    return strncmp(&string1[offset1], &string2[offset2], keylen);
  }

// Assembly:
cmpl %ecx, %esi
movl %ecx, %eax
cmovll %esi, %eax
testl %eax, %eax
jle 0x1428
testq %r8, %r8
je 0x140b
movl %eax, (%r8)
subl %eax, %ecx
subl %eax, %esi
movslq %esi, %rsi
addq %rsi, %rdi
movslq %ecx, %rcx
addq %rcx, %rdx
movl %eax, %eax
movq %rdx, %rsi
movq %rax, %rdx
jmp 0x1060
pushq %rax
leaq 0x2c22(%rip), %rdi      # 0x4052
leaq 0x2bcd(%rip), %rsi      # 0x4004
leaq 0x2c1f(%rip), %rcx      # 0x405d
movl $0x36, %edx
callq 0x10b0
// File: /workspace/github_c_makefile_star2_O3/stevenmherring[P]DNS/fine-trie.c
// Function: init
void init(int numthreads) {
    //Initialization function, set root node to null, initialize the lock we will use for root.
    root = NULL;
    int rv = pthread_mutex_init(&root_lock, NULL);
    assert(rv == 0);
  }

// Assembly:
pushq %rax
movq $0x0, 0x5cbc(%rip) # 0x7110
leaq 0x5cbd(%rip), %rdi      # 0x7118
xorl %esi, %esi
callq 0x11c0
testl %eax, %eax
jne 0x1468
popq %rax
retq
leaq 0x2bdb(%rip), %rdi      # 0x404a
leaq 0x2b8e(%rip), %rsi      # 0x4004
leaq 0x2c1e(%rip), %rcx      # 0x409b
movl $0x40, %edx
callq 0x10b0
// File: /workspace/github_c_makefile_star2_O3/stevenmherring[P]DNS/fine-trie.c
// Function: search
int search  (const char *string, size_t strlen, int32_t *ip4_address) {
    //Search Controller
    //main thread communicates directly with this and this pushes us where to go.
    int32_t found;
    int rc;
    // Skip strings of length 0
    if (strlen == 0)
    return 0;
    struct trie_node *node = root;

    if(node == NULL)
    return 0;
    rc = pthread_mutex_lock(&(node->lock));
    assert(rc == 0);

    found = _search(node, string, strlen);

    if (found >= 0 && ip4_address)
    *ip4_address = found;

    return (found >= 0);
  }

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
xorl %eax, %eax
testq %rsi, %rsi
je 0x1b32
movq 0x561e(%rip), %r12      # 0x7110
testq %r12, %r12
je 0x1b32
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
leaq 0x58(%r12), %rdi
callq 0x11d0
testl %eax, %eax
jne 0x1b3e
movq %r12, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x1487
testl %eax, %eax
sets %cl
testq %rbx, %rbx
sete %dl
orb %cl, %dl
jne 0x1b2d
movl %eax, (%rbx)
notl %eax
shrl $0x1f, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x25c8(%rip), %rdi      # 0x410d
leaq 0x24b8(%rip), %rsi      # 0x4004
leaq 0x2631(%rip), %rcx      # 0x4184
movl $0x127, %edx            # imm = 0x127
callq 0x10b0
// File: /workspace/github_c_makefile_star2_O3/stevenmherring[P]DNS/fine-trie.c
// Function: search_and_squat
int search_and_squat  (const char *string, size_t strlen, int32_t ip4_address) {
    int32_t found;
    int rc;
    // Skip strings of length 0
    if (strlen == 0)
    return 0;

    // in case the node was removed between trying to insert and squatting
    rc = pthread_mutex_lock(&(root_lock));
    assert(rc == 0);
    if(root != NULL)
    {
      found = _insert(string, strlen, ip4_address, root, NULL, NULL);
    }
    else
    {
      root = new_leaf (string, strlen, ip4_address);
      found = 1;
    }
    rc = pthread_mutex_unlock(&(root_lock));
    assert(rc == 0);

    while(!found)
    {
      rc = pthread_mutex_lock(&(root->lock));
      assert(rc == 0);


      found = _search_and_squat(root, string, strlen, ip4_address);

      // in case the node was removed between trying to insert and squatting
      if(!found)
      {
        found = insert(string, strlen, ip4_address);
      }
    }



    return (found >= 0);
  }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
testq %rsi, %rsi
je 0x1c08
movl %edx, %ebx
movq %rsi, %r14
movq %rdi, %r15
leaq 0x559c(%rip), %rdi      # 0x7118
callq 0x11d0
testl %eax, %eax
jne 0x1c8a
movq 0x5580(%rip), %rcx      # 0x7110
testq %rcx, %rcx
je 0x1c0c
movq %r15, %rdi
movq %r14, %rsi
movl %ebx, %edx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x1ca9
movl %eax, %ebp
leaq 0x5567(%rip), %rdi      # 0x7118
callq 0x1110
testl %eax, %eax
jne 0x1c37
movl $0x1, %eax
testl %ebp, %ebp
jne 0x1c60
jmp 0x1bda
movq %r15, %rdi
movq %r14, %rsi
movl %ebx, %edx
callq 0x2501
testl %eax, %eax
jne 0x1c56
movq 0x552f(%rip), %rdi      # 0x7110
addq $0x58, %rdi
callq 0x11d0
testl %eax, %eax
jne 0x1c6b
movq 0x551b(%rip), %rdi      # 0x7110
movq %r15, %rsi
movq %r14, %rdx
movl %ebx, %ecx
callq 0x1781
testl %eax, %eax
je 0x1bc9
jmp 0x1c5b
xorl %eax, %eax
jmp 0x1c60
movq %r15, %rdi
movq %r14, %rsi
movl %ebx, %edx
callq 0x12dc
movq %rax, 0x54f0(%rip)      # 0x7110
leaq 0x54f1(%rip), %rdi      # 0x7118
callq 0x1110
movl %eax, %ecx
movl $0x1, %eax
testl %ecx, %ecx
je 0x1c60
leaq 0x24cf(%rip), %rdi      # 0x410d
leaq 0x23bf(%rip), %rsi      # 0x4004
leaq 0x2564(%rip), %rcx      # 0x41b0
movl $0x146, %edx            # imm = 0x146
callq 0x10b0
movl $0x1, %eax
notl %eax
shrl $0x1f, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x249b(%rip), %rdi      # 0x410d
leaq 0x238b(%rip), %rsi      # 0x4004
leaq 0x2530(%rip), %rcx      # 0x41b0
movl $0x14b, %edx            # imm = 0x14B
callq 0x10b0
leaq 0x247c(%rip), %rdi      # 0x410d
leaq 0x236c(%rip), %rsi      # 0x4004
leaq 0x2511(%rip), %rcx      # 0x41b0
movl $0x13b, %edx            # imm = 0x13B
callq 0x10b0
// File: /workspace/github_c_makefile_star2_O3/stevenmherring[P]DNS/fine-trie.c
// Function: insert
int insert (const char *string, size_t strlen, int32_t ip4_address) {
        // Skip strings of length 0
        int rc;
        if (strlen == 0)
        return 0;
        int rv;
        // get root lock
        rc = pthread_mutex_lock(&(root_lock));
        assert(rc == 0);
        if (root == NULL) {
          root = new_leaf (string, strlen, ip4_address);
          rv =  1;
          rc = pthread_mutex_unlock(&(root_lock));
          assert(rc == 0);
        }
        else
        {
          rv = _insert (string, strlen, ip4_address, root, NULL, NULL);
          rc = pthread_mutex_unlock(&(root_lock));
          assert(rc == 0);
          if (!rv && allow_squatting)
          {
            search_and_squat(string, strlen, ip4_address);
          }
        }
        return rv;
      }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
testq %rsi, %rsi
je 0x2577
movl %edx, %ebx
movq %rsi, %r14
movq %rdi, %r15
leaq 0x4bfc(%rip), %rdi      # 0x7118
callq 0x11d0
testl %eax, %eax
jne 0x25b1
movq 0x4be0(%rip), %rcx      # 0x7110
testq %rcx, %rcx
je 0x257b
movq %r15, %rdi
movq %r14, %rsi
movl %ebx, %edx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x1ca9
movl %eax, %ebp
leaq 0x4bc7(%rip), %rdi      # 0x7118
callq 0x1110
testl %eax, %eax
jne 0x25d0
testl %ebp, %ebp
jne 0x25a4
leaq 0x4bdb(%rip), %rax      # 0x7140
cmpl $0x0, (%rax)
je 0x25a4
movq %r15, %rdi
movq %r14, %rsi
movl %ebx, %edx
callq 0x1b5d
xorl %ebp, %ebp
jmp 0x25a4
movq %r15, %rdi
movq %r14, %rsi
movl %ebx, %edx
callq 0x12dc
movq %rax, 0x4b81(%rip)      # 0x7110
leaq 0x4b82(%rip), %rdi      # 0x7118
callq 0x1110
movl $0x1, %ebp
testl %eax, %eax
jne 0x25ef
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x1b55(%rip), %rdi      # 0x410d
leaq 0x1a45(%rip), %rsi      # 0x4004
leaq 0x1cee(%rip), %rcx      # 0x42b4
movl $0x262, %edx            # imm = 0x262
callq 0x10b0
leaq 0x1b36(%rip), %rdi      # 0x410d
leaq 0x1a26(%rip), %rsi      # 0x4004
leaq 0x1ccf(%rip), %rcx      # 0x42b4
movl $0x26d, %edx            # imm = 0x26D
callq 0x10b0
leaq 0x1b17(%rip), %rdi      # 0x410d
leaq 0x1a07(%rip), %rsi      # 0x4004
leaq 0x1cb0(%rip), %rcx      # 0x42b4
movl $0x267, %edx            # imm = 0x267
callq 0x10b0
// File: /workspace/github_c_makefile_star2_O3/stevenmherring[P]DNS/fine-trie.c
// Function: delete
int delete  (const char *string, size_t strlen) {
          // Skip strings of length 0
          if (strlen == 0)
          return 0;
          int rc;

          rc = pthread_mutex_lock(&root_lock);
          assert(rc == 0);
          struct trie_node *parent = _delete(root, string, strlen);

          rc = pthread_mutex_unlock(&root_lock);
          assert(rc == 0);
          // release root lock

          int rv =(NULL != parent);

          if(parent != NULL && parent != ((struct trie_node *) 0x100100))
          {
            rc = pthread_mutex_unlock(&(parent->lock));
            assert(rc == 0);

          }


          return rv;
        }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
testq %rsi, %rsi
je 0x2baf
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x45d8(%rip), %rdi      # 0x7118
callq 0x11d0
testl %eax, %eax
jne 0x2bba
movq 0x45c0(%rip), %rdi      # 0x7110
movq %r14, %rsi
movq %rbx, %rdx
callq 0x260e
movq %rax, %rbx
leaq 0x45b3(%rip), %rdi      # 0x7118
callq 0x1110
testl %eax, %eax
jne 0x2bd9
testq %rbx, %rbx
setne %bpl
je 0x2bb1
cmpq $0x100100, %rbx         # imm = 0x100100
je 0x2bb1
addq $0x58, %rbx
movq %rbx, %rdi
callq 0x1110
testl %eax, %eax
je 0x2bb1
leaq 0x1576(%rip), %rdi      # 0x410d
leaq 0x1466(%rip), %rsi      # 0x4004
leaq 0x17a9(%rip), %rcx      # 0x434e
movl $0x35f, %edx            # imm = 0x35F
callq 0x10b0
xorl %ebp, %ebp
movzbl %bpl, %eax
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x154c(%rip), %rdi      # 0x410d
leaq 0x143c(%rip), %rsi      # 0x4004
leaq 0x177f(%rip), %rcx      # 0x434e
movl $0x353, %edx            # imm = 0x353
callq 0x10b0
leaq 0x152d(%rip), %rdi      # 0x410d
leaq 0x141d(%rip), %rsi      # 0x4004
leaq 0x1760(%rip), %rcx      # 0x434e
movl $0x357, %edx            # imm = 0x357
callq 0x10b0
// File: /workspace/github_c_makefile_star2_O3/stevenmherring[P]DNS/fine-trie.c
// Function: print
void print() {
          // TODO get root lock
          printf ("Root is at %p\n", root);
          struct trie_node *node = root;
          // relese root lock

          if(node)
          {
            _print(node,0 ,0);
          }
        }

// Assembly:
pushq %rax
movq 0x43f6(%rip), %rsi      # 0x7110
leaq 0x16eb(%rip), %rdi      # 0x440c
xorl %eax, %eax
callq 0x10a0
movq 0x43e1(%rip), %rdi      # 0x7110
testq %rdi, %rdi
je 0x2d3e
xorl %esi, %esi
xorl %edx, %edx
popq %rax
jmp 0x2bf8
popq %rax
retq
// File: /workspace/github_c_makefile_star2_O3/giometti[P]mastering_UNIX_programming/chapter_02/read.c
// Function: main
int main(void)
{
	int fd;
	int nr, nw;
	char buf[BUF_SIZE];

	fd = open(TMP_FILE, O_RDONLY);
	if (fd < 0) {
		perror("open");
		return -1;
	}

	do {
		nr = read(fd, buf, BUF_SIZE);
		if (nr < 0) {
			perror("read");
			return -1;
		}

		nw = writen(STDOUT_FILENO, buf, nr);
		if (nw < nr) {
			perror("write");
			return -1;
		}

		sleep(1);
	} while (nr > 0);

	return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
leaq 0xe68(%rip), %rdi       # 0x2004
xorl %esi, %esi
xorl %eax, %eax
callq 0x1060
testl %eax, %eax
js 0x11fb
movl %eax, %ebx
movq %rsp, %r14
movl $0x10, %edx
movl %ebx, %edi
movq %r14, %rsi
callq 0x1050
movq %rax, %r15
testl %r15d, %r15d
js 0x1204
movl %r15d, %edx
andl $0x7fffffff, %edx       # imm = 0x7FFFFFFF
movl $0x1, %edi
movq %r14, %rsi
callq 0x127e
cmpl %r15d, %eax
jl 0x120d
movl $0x1, %edi
callq 0x1080
testl %r15d, %r15d
jne 0x11ae
xorl %eax, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
leaq 0xe0c(%rip), %rdi       # 0x200e
jmp 0x1214
leaq 0xe08(%rip), %rdi       # 0x2013
jmp 0x1214
leaq 0xe04(%rip), %rdi       # 0x2018
callq 0x1070
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0x11f1
// File: /workspace/github_c_makefile_star2_O3/giometti[P]mastering_UNIX_programming/chapter_02/wrappers.c
// Function: readn
int readn(int fd, void *buf, size_t count)
{
        int nleft = count, nread;
        char *ptr = buf;

        while (nleft > 0) {
                nread = read(fd, ptr, nleft);
                if (nread < 0) {
                        if (errno != EAGAIN)
                                return -1;
                        nread = 0;
                } else if (nread == 0)
                        break;

                nleft -= nread;
                ptr += nread;
        }

        return count - nleft;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movl %ebx, %r15d
testl %ebx, %ebx
jle 0x1267
movq %rsi, %r14
movl %edi, %ebp
movl %ebx, %r15d
movl %r15d, %edx
movl %ebp, %edi
movq %r14, %rsi
callq 0x1050
testl %eax, %eax
js 0x124e
jne 0x125d
jmp 0x1267
callq 0x1030
movq %rax, %rcx
xorl %eax, %eax
cmpl $0xb, (%rcx)
jne 0x1277
movl %eax, %ecx
addq %rcx, %r14
subl %eax, %r15d
jg 0x1239
subl %r15d, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
jmp 0x126a
// File: /workspace/github_c_makefile_star2_O3/giometti[P]mastering_UNIX_programming/chapter_02/wrappers.c
// Function: writen
int writen(int fd, void *buf, size_t count)
{
        int nleft = count, nwritten;
        char *ptr = buf;

        while (nleft > 0) {
                nwritten = write(fd, ptr, nleft);
                if (nwritten < 0) {
                        if (errno != EAGAIN)
                                return -1;
                        nwritten = 0;
                }

                nleft -= nwritten;
                ptr += nwritten;
        }

        return count - nleft;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movl %ebx, %r15d
testl %ebx, %ebx
jle 0x12c1
movq %rsi, %r14
movl %edi, %ebp
movl %ebx, %r15d
movl %r15d, %edx
movl %ebp, %edi
movq %r14, %rsi
callq 0x1040
testl %eax, %eax
jns 0x12b7
callq 0x1030
movq %rax, %rcx
xorl %eax, %eax
cmpl $0xb, (%rcx)
jne 0x12d1
movl %eax, %ecx
addq %rcx, %r14
subl %eax, %r15d
jg 0x1297
subl %r15d, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
jmp 0x12c4
// File: /workspace/github_c_makefile_star2_O3/joncampbell123[P]swfhax/c4_swf2svg.c
// Function: dump_font_to_svg
void dump_font_to_svg(swf_reader *swf,swf_DefineFont *nfo) {
	unsigned int i;
	uint64_t ofs;
	FILE *fp;

	for (i=0;i < nfo->nGlyphs;i++) {
		ofs = (unsigned long long)nfo->absoluteOffsetTable + (unsigned long long)nfo->OffsetTable[i];
		if (swf_reader_seek(swf,ofs) == 0) {
			char tmp[256];

			sprintf(tmp,"swf.font.%u.glyph.%u.svg",nfo->FontID,i);
			fp = fopen(tmp,"w");
			if (fp) do_dump_font_to_svg(swf,fp);
			fclose(fp);
		}
		else {
			fprintf(stderr,"!! Unable to seek to offset (likely reason: non-sequential offsets)\n");
		}
	}
}

// Assembly:
cmpw $0x0, 0x2(%rsi)
je 0x19b4
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x108, %rsp            # imm = 0x108
movq %rsi, %rbx
movq %rdi, %r14
leaq -0x130(%rbp), %r12
xorl %r15d, %r15d
movq 0x8(%rbx), %rax
movzwl (%rax,%r15,2), %esi
addq 0x10(%rbx), %rsi
movq %r14, %rdi
callq 0x357f
testl %eax, %eax
jne 0x199c
movzwl (%rbx), %edx
movq %r12, %rdi
leaq 0x5891(%rip), %rsi      # 0x71eb
movl %r15d, %ecx
xorl %eax, %eax
callq 0x11a0
movq %r12, %rdi
leaq 0x5896(%rip), %rsi      # 0x7204
callq 0x1180
movq %rax, %r13
testq %rax, %rax
je 0x1986
movq %r14, %rdi
movq %r13, %rsi
callq 0x16ec
movq %r13, %rdi
callq 0x1060
incq %r15
movzwl 0x2(%rbx), %eax
cmpq %rax, %r15
jb 0x1934
jmp 0x19a3
callq 0x11d0
jmp 0x198e
addq $0x108, %rsp            # imm = 0x108
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/sasairc[P]yasuna/src/libbenly/src/column.c
// Function: tablize
int tablize(char** const array[])
{
    int     status  = 0;

    size_t  x       = 0,
            y       = 0,
        *   length  = NULL;

    regex_t reg;

    y = count_lines(array);
    x = count_cols(array);
    if (regcomp(&reg, ANSI_ESCSEQ, REG_EXTENDED) != 0) {
        status = -1; goto ERR;
    }
    if (count_length(array, x, y, &length, &reg) < 0) {
        status = -2; goto ERR;
    }
    put(array, x, y, length, &reg);
    regfree(&reg);
    free(length);

    return 0;

ERR:
    switch (status) {
        case    -1:
            break;
        case    -2:
            regfree(&reg);
            break;
    }

    return status;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rdi, %rbx
movq $-0x1, %r12
cmpq $0x0, 0x8(%rbx,%r12,8)
leaq 0x1(%r12), %r12
jne 0x11d4
movq (%rbx), %rax
movq $-0x1, %r13
movl $0x8, %r14d
addq $-0x8, %r14
cmpq $0x0, 0x8(%rax,%r13,8)
leaq 0x1(%r13), %r13
jne 0x11f1
leaq 0xdf8(%rip), %rsi       # 0x2000
leaq 0x18(%rsp), %rdi
movl $0x1, %edx
callq 0x10a0
movl %eax, %ecx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testl %ecx, %ecx
jne 0x135a
negq %r14
movq %r14, %rdi
callq 0x10b0
movq %rax, 0x8(%rsp)
testq %rax, %rax
je 0x134b
testq %r13, %r13
je 0x1298
xorl %ebp, %ebp
movq 0x8(%rsp), %rax
movq $0x0, (%rax,%rbp,8)
testq %r12, %r12
je 0x1290
xorl %r14d, %r14d
xorl %r15d, %r15d
movq (%rbx,%r15,8), %rax
movq (%rax,%rbp,8), %rdi
testq %rdi, %rdi
je 0x1290
leaq 0x18(%rsp), %rsi
callq 0x1369
cltq
cmpq %rax, %r14
jae 0x1288
movq 0x8(%rsp), %rcx
movq %rax, (%rcx,%rbp,8)
movq %rax, %r14
incq %r15
cmpq %r15, %r12
jne 0x125e
incq %rbp
cmpq %rbp, %r13
jne 0x1246
movq %r12, 0x10(%rsp)
testq %r12, %r12
je 0x1333
xorl %r12d, %r12d
testq %r13, %r13
je 0x131b
xorl %r15d, %r15d
movq (%rbx,%r12,8), %rax
movq (%rax,%r15,8), %rdi
testq %rdi, %rdi
je 0x131b
movq 0x2d1b(%rip), %rax      # 0x3fe0
movq (%rax), %rsi
callq 0x1090
movq %rbx, %rbp
movq (%rbx,%r12,8), %rax
movq (%rax,%r15,8), %rdi
leaq 0x18(%rsp), %rsi
callq 0x1369
movslq %eax, %rbx
movq 0x8(%rsp), %rax
movq (%rax,%r15,8), %r14
cmpq %rbx, %r14
jb 0x1310
incq %rbx
movl $0x20, %edi
callq 0x1040
testl %eax, %eax
je 0x1310
leaq 0x1(%rbx), %rax
cmpq %r14, %rbx
movq %rax, %rbx
jbe 0x12f6
incq %r15
cmpq %r15, %r13
movq %rbp, %rbx
jne 0x12b1
movl $0xa, %edi
callq 0x1040
incq %r12
cmpq %r12, 0x10(%rsp)
jne 0x12a9
leaq 0x18(%rsp), %rdi
callq 0x1070
movq 0x8(%rsp), %rdi
callq 0x1030
xorl %eax, %eax
jmp 0x135a
leaq 0x18(%rsp), %rdi
callq 0x1070
movl $0xfffffffe, %eax       # imm = 0xFFFFFFFE
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/sasairc[P]yasuna/src/libbenly/src/column.c
// Function: mbstrlen_with_regex
static
int mbstrlen_with_regex(char* src, regex_t* reg)
{
    int         ch      = 0,
                len     = 0;

    char*       p       = src;

#ifdef  WITH_GLIB
    gunichar*   cpoints;
/* WITH_GLIB */
#endif

    regmatch_t  match;

    setlocale(LC_CTYPE, LOCALE);

    while (*p != '\0') {
        /* get string length */
        if ((ch = mblen(p, MB_CUR_MAX)) < 0)
            return 0;

#ifdef  WITH_GLIB
        /*
         * true : multi byte
         * false: ascii
         */
        if (ch > 1) {
            /* get unicode code point */
            cpoints = g_utf8_to_ucs4_fast(p, sizeof(*p), NULL);
            /*
             * # multi byte
             * true : hankaku kana
             * false: other
             */
            if ((*cpoints >= 0xff65 && *cpoints <= 0xff9f) ||
                    *cpoints == 0x001b) {
                len++;
            } else {
                len += 2;
            }
            g_free(cpoints);
        } else {
            len++;
        }
#else
        /*
         * true : multi byte
         * false: ascii
         */
        if (ch > 1) {
            len += 2;
        } else {
            len++;
        }
/* WITH_GLIB */
#endif
        /* seek offset */
        p += ch;
    }

    /* regex match */
    while (regexec(reg, src, 1, &match, 0) != REG_NOMATCH) {
        src += match.rm_eo;
        len -= match.rm_eo - match.rm_so;
    }

    return len;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0xc90(%rip), %rsi       # 0x2011
xorl %ebp, %ebp
xorl %edi, %edi
callq 0x10d0
cmpb $0x0, (%r14)
je 0x1405
movq %r14, %r15
xorl %ebp, %ebp
callq 0x1080
movq %r15, %rdi
movq %rax, %rsi
callq 0x1050
testl %eax, %eax
js 0x144d
movl %eax, %r12d
movl $0x1, %r13d
cmpl $0x2, %eax
jb 0x13f4
movl $0x1, %esi
movq %r15, %rdi
xorl %edx, %edx
callq 0x10e0
movl (%rax), %ecx
leal -0xff65(%rcx), %edx
cmpl $0x3b, %edx
setb %dl
cmpl $0x1b, %ecx
sete %cl
orb %dl, %cl
movzbl %cl, %ecx
movl $0x2, %r13d
subl %ecx, %r13d
movq %rax, %rdi
callq 0x1060
addl %r13d, %ebp
movl %r12d, %eax
cmpb $0x0, (%r15,%rax)
leaq (%r15,%rax), %r15
jne 0x1395
movq %rsp, %rcx
movl $0x1, %edx
movq %rbx, %rdi
movq %r14, %rsi
xorl %r8d, %r8d
callq 0x10c0
cmpl $0x1, %eax
je 0x144f
movq %rsp, %r15
movslq 0x4(%rsp), %rax
addq %rax, %r14
subl %eax, %ebp
addl (%rsp), %ebp
movl $0x1, %edx
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rcx
xorl %r8d, %r8d
callq 0x10c0
cmpl $0x1, %eax
jne 0x1423
jmp 0x144f
xorl %ebp, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/lh3[P]fermi-lite/misc.c
// Function: fml_opt_init
void fml_opt_init(fml_opt_t *opt)
{
	opt->n_threads = 1;
	opt->ec_k = 0;
	opt->min_cnt = 4;
	opt->max_cnt = 8;
	opt->min_asm_ovlp = 33;
	opt->min_merge_len = 0;
	mag_init_opt(&opt->mag_opt);
	opt->mag_opt.flag = MAG_F_NO_SIMPL | MAG_F_POPOPEN;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movaps 0x14c31(%rip), %xmm0    # 0x17370
movups %xmm0, (%rdi)
movq $0x21, 0x10(%rdi)
addq $0x18, %rdi
callq 0x12330
movl $0xc0, 0x18(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/lh3[P]fermi-lite/misc.c
// Function: fml_opt_adjust
void fml_opt_adjust(fml_opt_t *opt, int n_seqs, const bseq1_t *seqs)
{
	int i, log_len;
	uint64_t tot_len = 0;
	if (opt->n_threads < 1) opt->n_threads = 1;
	for (i = 0; i < n_seqs; ++i) tot_len += seqs[i].l_seq; // compute total length
	for (log_len = 10; log_len < 32; ++log_len) // compute ceil(log2(tot_len))
		if (1ULL<<log_len > tot_len) break;
	if (opt->ec_k == 0) opt->ec_k = (log_len + 12) / 2;
	if (opt->ec_k%2 == 0) ++opt->ec_k;
	opt->mag_opt.min_elen = (int)((double)tot_len / n_seqs * 2.5 + .499);
}

// Assembly:
cmpl $0x0, (%rdi)
jg 0x2767
movl $0x1, (%rdi)
testl %esi, %esi
jle 0x278c
movl %esi, %eax
shlq $0x3, %rax
leaq (%rax,%rax,2), %rcx
xorl %r8d, %r8d
xorl %eax, %eax
movslq (%rdx,%r8), %r9
addq %r9, %rax
addq $0x18, %r8
cmpq %r8, %rcx
jne 0x277a
jmp 0x278e
xorl %eax, %eax
movl $0xa, %edx
movq %rdx, %rcx
movq %rax, %r8
shrq %cl, %r8
incq %rdx
cmpq $0x1f, %rcx
ja 0x27aa
testq %r8, %r8
jne 0x2793
movl 0x4(%rdi), %ecx
testl %ecx, %ecx
jne 0x27bb
addl $0xb, %edx
shrl %edx
movl %edx, 0x4(%rdi)
movl %edx, %ecx
testb $0x1, %cl
jne 0x27c6
orl $0x1, %ecx
movl %ecx, 0x4(%rdi)
movq %rax, %xmm0
punpckldq 0x14bad(%rip), %xmm0 # xmm0 = xmm0[0],mem[0],xmm0[1],mem[1]
subpd 0x14bb5(%rip), %xmm0    # 0x17390
movapd %xmm0, %xmm1
unpckhpd %xmm0, %xmm1            # xmm1 = xmm1[1],xmm0[1]
addsd %xmm0, %xmm1
xorps %xmm0, %xmm0
cvtsi2sd %esi, %xmm0
divsd %xmm0, %xmm1
mulsd 0x14ba6(%rip), %xmm1    # 0x173a0
addsd 0x14ba6(%rip), %xmm1    # 0x173a8
cvttsd2si %xmm1, %eax
movl %eax, 0x20(%rdi)
retq
// File: /workspace/github_c_makefile_star2_O3/lh3[P]fermi-lite/misc.c
// Function: fml_mag_clean
void fml_mag_clean(const fml_opt_t *opt, struct mag_t *g)
{
	magopt_t o = opt->mag_opt;
	o.min_merge_len = opt->min_merge_len;
	mag_g_merge(g, 1, opt->min_merge_len);
	mag_g_clean(g, &o);
	mag_g_trim_open(g, &o);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x38, %rsp
movq %rsi, %rbx
movq 0x48(%rdi), %rax
movq %rsp, %r14
movq %rax, 0x30(%r14)
movups 0x18(%rdi), %xmm0
movups 0x28(%rdi), %xmm1
movups 0x38(%rdi), %xmm2
movaps %xmm2, 0x20(%r14)
movaps %xmm1, 0x10(%r14)
movaps %xmm0, (%r14)
movl 0x14(%rdi), %edx
movl %edx, 0x20(%r14)
movq %rsi, %rdi
movl $0x1, %esi
callq 0x10723
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1237e
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1265e
addq $0x38, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/lh3[P]fermi-lite/misc.c
// Function: fml_utg_print_gfa
void fml_utg_print_gfa(int n, const fml_utg_t *utg)
{
	int i, j;
	FILE *fp = stdout;
	fputs("H\tVN:Z:1.0\n", fp);
	for (i = 0; i < n; ++i) {
		const fml_utg_t *u = &utg[i];
		fprintf(fp, "S\t%d\t", i);
		fputs(u->seq, fp);
		fprintf(fp, "\tLN:i:%d\tRC:i:%d\tPD:Z:", u->len, u->nsr);
		fputs(u->cov, fp);
		fputc('\n', fp);
		for (j = 0; j < u->n_ovlp[0] + u->n_ovlp[1]; ++j) {
			fml_ovlp_t *o = &u->ovlp[j];
			if (i < o->id)
				fprintf(fp, "L\t%d\t%c\t%d\t%c\t%dM\n", i, "+-"[!o->from], o->id, "+-"[o->to], o->len);
		}
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, 0x8(%rsp)
movl %edi, %ebp
movq 0x19114(%rip), %rax     # 0x1cfc0
movq (%rax), %r14
leaq 0x13551(%rip), %rdi     # 0x17407
movq %r14, %rsi
callq 0x20f0
testl %ebp, %ebp
jle 0x3fd3
movl %ebp, %eax
movq %rax, 0x10(%rsp)
movl $0x7fffffff, %r12d      # imm = 0x7FFFFFFF
leaq 0x13569(%rip), %r15     # 0x17443
xorl %ebp, %ebp
leaq (,%rbp,4), %rbx
addq %rbp, %rbx
movq %r14, %rdi
leaq 0x13522(%rip), %rsi     # 0x17413
movl %ebp, %edx
xorl %eax, %eax
callq 0x2150
movq 0x8(%rsp), %r13
movq 0x8(%r13,%rbx,8), %rdi
movq %r14, %rsi
callq 0x20f0
movl (%r13,%rbx,8), %edx
movl 0x4(%r13,%rbx,8), %ecx
movq %r14, %rdi
leaq 0x134f9(%rip), %rsi     # 0x17419
xorl %eax, %eax
callq 0x2150
movq 0x10(%r13,%rbx,8), %rdi
movq %r14, %rsi
callq 0x20f0
movl $0xa, %edi
movq %r14, %rsi
callq 0x2120
movl 0x18(%r13,%rbx,8), %eax
movl 0x1c(%r13,%rbx,8), %ecx
movl %ecx, %edx
addl %eax, %edx
jle 0x3fc5
movq 0x8(%rsp), %rdx
leaq (%rdx,%rbx,8), %r13
xorl %ebx, %ebx
movq 0x20(%r13), %rdx
movq (%rdx,%rbx,8), %rdx
movq %rdx, %r8
shrq $0x20, %r8
movl %r8d, %esi
andl $0x7fffffff, %esi       # imm = 0x7FFFFFFF
cmpq %rsi, %rbp
jae 0x3fb7
andl %r12d, %r8d
movl %edx, %eax
shrl $0x1f, %eax
xorq $0x1, %rax
movsbl (%rax,%r15), %ecx
movq %rdx, %rax
shrq $0x3f, %rax
movsbl (%rax,%r15), %r9d
andl %r12d, %edx
movl %edx, (%rsp)
movq %r14, %rdi
leaq 0x1348a(%rip), %rsi     # 0x17430
movl %ebp, %edx
xorl %eax, %eax
callq 0x2150
movl 0x18(%r13), %eax
movl 0x1c(%r13), %ecx
incq %rbx
leal (%rcx,%rax), %edx
movslq %edx, %rdx
cmpq %rdx, %rbx
jl 0x3f5c
incq %rbp
cmpq 0x10(%rsp), %rbp
jne 0x3edc
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/lh3[P]fermi-lite/misc.c
// Function: fml_utg_destroy
void fml_utg_destroy(int n, fml_utg_t *utg)
{
	int i;
	for (i = 0; i < n; ++i) {
		free(utg[i].seq);
		free(utg[i].cov);
		free(utg[i].ovlp);
	}
	free(utg);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
testl %edi, %edi
jle 0x4022
movl %edi, %eax
shlq $0x3, %rax
leaq (%rax,%rax,4), %r14
xorl %r15d, %r15d
movq 0x8(%rbx,%r15), %rdi
callq 0x2040
movq 0x10(%rbx,%r15), %rdi
callq 0x2040
movq 0x20(%rbx,%r15), %rdi
callq 0x2040
addq $0x28, %r15
cmpq %r15, %r14
jne 0x3ffb
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x2040
// File: /workspace/github_c_makefile_star2_O3/lh3[P]fermi-lite/misc.c
// Function: fml_assemble
fml_utg_t *fml_assemble(const fml_opt_t *opt0, int n_seqs, bseq1_t *seqs, int *n_utg)
{
	rld_t *e;
	mag_t *g;
	fml_utg_t *utg;
	fml_opt_t opt = *opt0;
	float kcov;

	*n_utg = 0;
	fml_opt_adjust(&opt, n_seqs, seqs);
	if (opt.ec_k >= 0) fml_correct(&opt, n_seqs, seqs);
	kcov = fml_fltuniq(&opt, n_seqs, seqs);
	e = fml_seq2fmi(&opt, n_seqs, seqs);
	if (e == 0) return 0; // this may happen when all sequences are filtered out
	g = fml_fmi2mag(&opt, e);
	opt.mag_opt.min_ensr = opt.mag_opt.min_ensr > kcov * MAG_MIN_NSR_COEF? opt.mag_opt.min_ensr : (int)(kcov * MAG_MIN_NSR_COEF + .499);
	opt.mag_opt.min_ensr = opt.mag_opt.min_ensr < opt0->max_cnt? opt.mag_opt.min_ensr : opt0->max_cnt;
	opt.mag_opt.min_ensr = opt.mag_opt.min_ensr > opt0->min_cnt? opt.mag_opt.min_ensr : opt0->min_cnt;
	opt.mag_opt.min_insr = opt.mag_opt.min_ensr - 1;
	fml_mag_clean(&opt, g);
	utg = fml_mag2utg(g, n_utg);
	return utg;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rcx, %rbx
movq %rdx, %r15
movl %esi, %ebp
movq %rdi, %r14
leaq 0x10(%rsp), %r12
movl $0x14, %ecx
movq %r12, %rdi
movq %r14, %rsi
rep  movsl (%rsi), %es:(%rdi)
movl $0x0, (%rbx)
movq %r12, %rdi
movl %ebp, %esi
callq 0x275c
cmpl $0x0, 0x4(%r12)
js 0x407f
leaq 0x10(%rsp), %rdi
movl %ebp, %esi
movq %r15, %rdx
callq 0x7628
leaq 0x10(%rsp), %r12
movq %r12, %rdi
movl %ebp, %esi
movq %r15, %rdx
callq 0x7634
movss %xmm0, 0xc(%rsp)
xorl %edx, %edx
cmpl $0x2, (%r12)
setge %dl
movl %ebp, %edi
movq %r15, %rsi
callq 0x280a
testq %rax, %rax
je 0x4123
leaq 0x10(%rsp), %r15
movq %r15, %rdi
movq %rax, %rsi
callq 0xc5c3
movl 0x24(%r15), %ecx
xorps %xmm0, %xmm0
cvtsi2sd %ecx, %xmm0
cvtss2sd 0xc(%rsp), %xmm1
mulsd 0x132d7(%rip), %xmm1    # 0x173b0
ucomisd %xmm1, %xmm0
addsd 0x132c3(%rip), %xmm1    # 0x173a8
cvttsd2si %xmm1, %edx
cmoval %ecx, %edx
movl 0xc(%r14), %ecx
cmpl %ecx, %edx
cmovgel %ecx, %edx
movl 0x8(%r14), %ecx
cmpl %ecx, %edx
cmovlel %ecx, %edx
movq %rax, %r14
movl %edx, 0x24(%r15)
decl %edx
movl %edx, 0x28(%r15)
movq %r15, %rdi
movq %rax, %rsi
callq 0x2c46
movq %r14, %rdi
movq %rbx, %rsi
callq 0x2cac
jmp 0x4125
xorl %eax, %eax
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O3/lh3[P]fermi-lite/bseq.c
// Function: seq_reverse
void seq_reverse(int l, unsigned char *s)
{
	int i;
	for (i = 0; i < l>>1; ++i) {
		int tmp = s[l-1-i];
		s[l-1-i] = s[i]; s[i] = tmp;
	}
}

// Assembly:
movl %edi, %eax
sarl %eax
testl %eax, %eax
jle 0x468b
movl %eax, %eax
decl %edi
xorl %ecx, %ecx
movslq %edi, %rdi
movb (%rsi,%rdi), %dl
movb (%rsi,%rcx), %r8b
movb %r8b, (%rsi,%rdi)
movb %dl, (%rsi,%rcx)
incq %rcx
decl %edi
cmpq %rcx, %rax
jne 0x4670
retq
// File: /workspace/github_c_makefile_star2_O3/lh3[P]fermi-lite/bseq.c
// Function: seq_revcomp6
void seq_revcomp6(int l, unsigned char *s)
{
	int i;
	for (i = 0; i < l>>1; ++i) {
		int tmp = s[l-1-i];
		tmp = (tmp >= 1 && tmp <= 4)? 5 - tmp : tmp;
		s[l-1-i] = (s[i] >= 1 && s[i] <= 4)? 5 - s[i] : s[i];
		s[i] = tmp;
	}
	if (l&1) s[i] = (s[i] >= 1 && s[i] <= 4)? 5 - s[i] : s[i];
}

// Assembly:
movl %edi, %eax
sarl %eax
testl %eax, %eax
jle 0x46e8
movl %eax, %eax
leal -0x1(%rdi), %ecx
xorl %edx, %edx
movslq %ecx, %rcx
movzbl (%rsi,%rcx), %r8d
movb $0x5, %r9b
subb %r8b, %r9b
leal -0x1(%r8), %r10d
cmpb $0x4, %r10b
movzbl %r9b, %r9d
cmovael %r8d, %r9d
movzbl (%rsi,%rdx), %r8d
movb $0x5, %r10b
subb %r8b, %r10b
leal -0x1(%r8), %r11d
cmpb $0x4, %r11b
movzbl %r10b, %r10d
cmovael %r8d, %r10d
movb %r10b, (%rsi,%rcx)
movb %r9b, (%rsi,%rdx)
incq %rdx
decl %ecx
cmpq %rdx, %rax
jne 0x469b
jmp 0x46ea
xorl %eax, %eax
testb $0x1, %dil
je 0x4708
movzbl (%rsi,%rax), %ecx
movb $0x5, %dl
subb %cl, %dl
leal -0x1(%rcx), %edi
cmpb $0x4, %dil
movzbl %dl, %edx
cmovael %ecx, %edx
movb %dl, (%rsi,%rax)
retq
// File: /workspace/github_c_makefile_star2_O3/lh3[P]fermi-lite/bfc.c
// Function: fml_count
struct bfc_ch_s *fml_count(int n, const bseq1_t *seq, int k, int q, int l_pre, int n_threads)
{
	int i;
	cnt_step_t cs;
	cs.n_seqs = n, cs.seqs = seq, cs.k = k, cs.q = q;
	cs.ch = bfc_ch_init(cs.k, l_pre);
	cs.n_buf = calloc(n_threads, sizeof(int));
	cs.buf = calloc(n_threads, sizeof(void*));
	for (i = 0; i < n_threads; ++i)
		cs.buf[i] = malloc(CNT_BUF_SIZE * sizeof(insbuf_t));
	kt_for(n_threads, worker_count, &cs, cs.n_seqs);
	for (i = 0; i < n_threads; ++i) free(cs.buf[i]);
	free(cs.buf); free(cs.n_buf);
	return cs.ch;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x30, %rsp
movl %r9d, %ebx
movl %edi, %ebp
movl %edi, 0x8(%rsp)
movq %rsi, 0x10(%rsp)
movl %edx, (%rsp)
movl %ecx, 0x4(%rsp)
movl %edx, %edi
movl %r8d, %esi
callq 0x14840
movq %rax, 0x18(%rsp)
movslq %ebx, %r15
movl $0x4, %esi
movq %r15, %rdi
callq 0x2130
movq %rax, 0x20(%rsp)
movl $0x8, %esi
movq %r15, %rdi
callq 0x2130
movq %rax, 0x28(%rsp)
testl %r15d, %r15d
jle 0x4a68
movq %rax, %r14
movl %ebx, %r15d
xorl %r12d, %r12d
movl $0x1800, %edi           # imm = 0x1800
callq 0x21a0
movq %rax, (%r14,%r12,8)
incq %r12
cmpq %r12, %r15
jne 0x4a20
movslq %ebp, %rcx
leaq 0x62(%rip), %rsi        # 0x4aa2
movq %rsp, %rdx
movl %ebx, %edi
callq 0x14684
testl %ebx, %ebx
jle 0x4a7c
xorl %ebx, %ebx
movq 0x28(%rsp), %rax
movq (%rax,%rbx,8), %rdi
callq 0x2040
incq %rbx
cmpq %rbx, %r15
jne 0x4a50
jmp 0x4a7c
movslq %ebp, %rcx
leaq 0x30(%rip), %rsi        # 0x4aa2
movq %rsp, %rdx
movl %ebx, %edi
callq 0x14684
movq 0x28(%rsp), %rdi
callq 0x2040
movq 0x20(%rsp), %rdi
callq 0x2040
movq 0x18(%rsp), %rax
addq $0x30, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/lh3[P]fermi-lite/bfc.c
// Function: bfc_ec_first_kmer
int bfc_ec_first_kmer(int k, const ecseq_t *s, int start, bfc_kmer_t *x)
{
	int i, l;
	*x = bfc_kmer_null;
	for (i = start, l = 0; i < s->n; ++i) {
		ecbase_t *c = &s->a[i];
		if (c->b < 4) {
			bfc_kmer_append(k, x->x, c->b);
			if (++l == k) break;
		} else l = 0, *x = bfc_kmer_null;
	}
	return i;
}

// Assembly:
movups 0x18321(%rip), %xmm0    # 0x1d290
movups %xmm0, 0x10(%rcx)
movups 0x18306(%rip), %xmm0    # 0x1d280
movups %xmm0, (%rcx)
movslq %edx, %r8
cmpq %r8, (%rsi)
jbe 0x503b
pushq %r14
pushq %rbx
movq %rcx, %rax
movq $-0x1, %rdx
movl %edi, %ecx
shlq %cl, %rdx
notq %rdx
leal -0x1(%rdi), %ecx
xorl %r9d, %r9d
movq 0x10(%rsi), %r10
movzbl (%r10,%r8,8), %r10d
andl $0x7, %r10d
cmpb $0x3, %r10b
ja 0x5011
movl %r10d, %r11d
andl $0x1, %r11d
movq (%rax), %rbx
movq 0x8(%rax), %r14
leaq (%r11,%rbx,2), %rbx
andq %rdx, %rbx
movq %rbx, (%rax)
shrl %r10d
leaq (%r10,%r14,2), %rbx
andq %rdx, %rbx
movq %rbx, 0x8(%rax)
movq 0x10(%rax), %rbx
shrq %rbx
xorq $0x1, %r11
shlq %cl, %r11
orq %rbx, %r11
movq %r11, 0x10(%rax)
movq 0x18(%rax), %r11
shrq %r11
xorq $0x1, %r10
shlq %cl, %r10
orq %r11, %r10
movq %r10, 0x18(%rax)
incl %r9d
cmpl %edi, %r9d
jne 0x5029
jmp 0x5035
movups 0x18278(%rip), %xmm0    # 0x1d290
movups %xmm0, 0x10(%rax)
movups 0x1825d(%rip), %xmm0    # 0x1d280
movups %xmm0, (%rax)
xorl %r9d, %r9d
incq %r8
cmpq %r8, (%rsi)
ja 0x4fa4
movl %r8d, %edx
popq %rbx
popq %r14
movl %edx, %eax
retq
// File: /workspace/github_c_makefile_star2_O3/lh3[P]fermi-lite/bfc.c
// Function: bfc_ec_kcov
void bfc_ec_kcov(int k, int min_occ, ecseq_t *s, const bfc_ch_t *ch)
{
	int i, l, r, j;
	bfc_kmer_t x = bfc_kmer_null;
	for (i = l = 0; i < s->n; ++i) {
		ecbase_t *c = &s->a[i];
		c->high_end = c->solid_end = c->lcov = c->hcov = 0;
		if (c->b < 4) {
			bfc_kmer_append(k, x.x, c->b);
			if (++l >= k) {
				if ((r = bfc_ch_kmer_occ(ch, &x)) >= 0) {
					if ((r>>8&0x3f) >= min_occ+1) c->high_end = 1;
					if ((r&0xff) >= min_occ) {
						c->solid_end = 1;
						for (j = i - k + 1; j <= i; ++j)
							++s->a[j].lcov, s->a[j].hcov += c->high_end;
					}
				}
			}
		} else l = 0, x = bfc_kmer_null;
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rcx, 0x40(%rsp)
movl %esi, 0xc(%rsp)
movups 0x18234(%rip), %xmm0    # 0x1d290
movaps %xmm0, 0x20(%rsp)
movups 0x18218(%rip), %xmm0    # 0x1d280
movaps %xmm0, 0x10(%rsp)
cmpq $0x0, (%rdx)
je 0x5202
movq %rdx, %r14
movl %edi, %r13d
movq $-0x1, %r8
movl %r13d, %ecx
shlq %cl, %r8
notq %r8
leal -0x1(%r13), %ecx
movl %edi, %ebx
negl %ebx
xorl %ebp, %ebp
xorl %r15d, %r15d
movq %r8, 0x38(%rsp)
movq %rcx, 0x30(%rsp)
movq 0x10(%r14), %r12
andw $0xc000, 0x2(%r12,%rbp,8) # imm = 0xC000
movzbl (%r12,%rbp,8), %eax
andl $0x7, %eax
cmpb $0x3, %al
ja 0x51cb
movl %eax, %edx
andl $0x1, %edx
movq 0x10(%rsp), %r9
movq 0x18(%rsp), %rsi
leaq (%rdx,%r9,2), %r9
andq %r8, %r9
movq %r9, 0x10(%rsp)
shrl %eax
leaq (%rax,%rsi,2), %rsi
andq %r8, %rsi
movq %rsi, 0x18(%rsp)
movq 0x20(%rsp), %rsi
shrq %rsi
xorq $0x1, %rdx
shlq %cl, %rdx
orq %rsi, %rdx
movq %rdx, 0x20(%rsp)
movq 0x28(%rsp), %rdx
shrq %rdx
xorq $0x1, %rax
shlq %cl, %rax
orq %rdx, %rax
movq %rax, 0x28(%rsp)
incl %r15d
cmpl %r13d, %r15d
jl 0x51e6
movq 0x40(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x14d3a
testl %eax, %eax
js 0x51f6
movl %eax, %ecx
shrl $0x8, %ecx
andl $0x3f, %ecx
cmpl 0xc(%rsp), %ecx
jle 0x514e
orb $0x20, 0x3(%r12,%rbp,8)
movzbl %al, %eax
cmpl 0xc(%rsp), %eax
movq 0x38(%rsp), %r8
movq 0x30(%rsp), %rcx
jl 0x51e6
orb $0x10, 0x3(%r12,%rbp,8)
testl %r13d, %r13d
jle 0x51e6
movslq %ebx, %rax
movq 0x10(%r14), %r9
movzwl 0xa(%r9,%rax,8), %edx
leal 0x1(%rdx), %esi
andl $0x3f, %esi
andl $-0x40, %edx
orl %esi, %edx
movw %dx, 0xa(%r9,%rax,8)
movzwl 0x2(%r12,%rbp,8), %r9d
movq 0x10(%r14), %rdx
movzwl 0xa(%rdx,%rax,8), %esi
shrl $0x7, %r9d
andl $0x40, %r9d
addl %esi, %r9d
andl $0xfc0, %r9d            # imm = 0xFC0
andl $0xfffff03f, %esi       # imm = 0xFFFFF03F
orl %r9d, %esi
movw %si, 0xa(%rdx,%rax,8)
leaq 0x1(%rax), %rdx
movq %rdx, %rax
cmpq %rbp, %rdx
jl 0x5173
jmp 0x51e6
movups 0x180be(%rip), %xmm0    # 0x1d290
movaps %xmm0, 0x20(%rsp)
movups 0x180a2(%rip), %xmm0    # 0x1d280
movaps %xmm0, 0x10(%rsp)
xorl %r15d, %r15d
incq %rbp
incl %ebx
cmpq %rbp, (%r14)
ja 0x50a4
jmp 0x5202
movq 0x38(%rsp), %r8
movq 0x30(%rsp), %rcx
jmp 0x51e6
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq