LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/./Overlaps.h
// Function: get_real_length(asg_t*, unsigned int, unsigned int*)
inline int get_real_length(asg_t *g, uint32_t v, uint32_t* v_s)
{
    uint32_t i, kv = 0;
    for (i = 0, kv = 0; i < asg_arc_n(g, v); i++)
    {
        if(!asg_arc_a(g, v)[i].del)
        {
            if(v_s) v_s[kv] = asg_arc_a(g, v)[i].v;
            kv++;
        }
    }

    return kv;
}

// Assembly:
movq 0x28(%rdi), %rax
movl %esi, %ecx
movq (%rax,%rcx,8), %rax
testl %eax, %eax
je 0x1053a4
movq 0x8(%rdi), %rcx
movq %rax, %rsi
shrq $0x20, %rsi
movl %eax, %eax
leaq (%rsi,%rsi,2), %rsi
leaq (%rcx,%rsi,8), %rcx
addq $0xc, %rcx
shlq $0x3, %rax
leaq (%rax,%rax,2), %rsi
xorl %edi, %edi
xorl %eax, %eax
cmpl $0x0, (%rcx,%rdi)
js 0x10539a
testq %rdx, %rdx
je 0x105398
movl -0x4(%rcx,%rdi), %r8d
movl %eax, %r9d
movl %r8d, (%rdx,%r9,4)
incl %eax
addq $0x18, %rdi
cmpq %rdi, %rsi
jne 0x105381
retq
xorl %eax, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Trio.cpp
// Function: test_yak_binning(char*, char*)
uint32_t test_yak_binning(char* fn, char *cmd)
{
    gzFile fp; kstream_t *ks; kstring_t str = {0,0,0};
	int dret, eq = 0; fp = gzopen(fn, "r");
	if (fp == 0) return eq;
	ks = ks_init(fp);
	if(ks_getuntil(ks, KS_SEP_LINE, &str, &dret) >= 0) {
		uint64_t sl = strlen(str.s), z;
		for (z = 0; (z < sl) && (str.s[z]!='\t'); z++);
		if(((z+1)<sl) && (str.s[z]=='\t')) {
			if((strlen(str.s+z+1)==strlen(cmd)) && (!memcmp(str.s+z+1, cmd, strlen(cmd)))) {
				eq = 1;
			}
		}		
	}
	free(str.s);
	ks_destroy(ks);
	gzclose(fp);
	return eq;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r15
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rsp)
movq $0x0, 0x20(%rsp)
leaq 0x13823a(%rip), %rsi    # 0x23f7f7
callq 0x22d0
testq %rax, %rax
je 0x107681
movq %rax, %rbx
movl $0x1, %edi
movl $0x20, %esi
callq 0x2120
movq %rax, %r14
movq %rbx, 0x18(%rax)
movl $0x10000, %edi          # imm = 0x10000
callq 0x2280
movq %rax, (%r14)
leaq 0x10(%rsp), %r12
leaq 0xc(%rsp), %rdx
movq %r14, %rdi
movq %r12, %rsi
callq 0x1076bb
movq 0x10(%r12), %r13
testl %eax, %eax
js 0x107686
movq %r13, %rdi
callq 0x2090
xorl %r12d, %r12d
xorl %ebp, %ebp
testq %rax, %rax
je 0x107634
cmpb $0x9, (%r13,%rbp)
je 0x107634
incq %rbp
cmpq %rbp, %rax
jne 0x107621
movq %rax, %rbp
leaq 0x1(%rbp), %rcx
cmpq %rax, %rcx
jae 0x107689
cmpb $0x9, (%r13,%rbp)
jne 0x107689
addq %r13, %rbp
incq %rbp
movq %rbp, %rdi
callq 0x2090
movq %r15, %rdi
movq %rax, %r15
movq %rdi, (%rsp)
callq 0x2090
cmpq %rax, %r15
jne 0x107689
movq %rbp, %rdi
movq (%rsp), %rsi
movq %r15, %rdx
callq 0x21a0
xorl %r12d, %r12d
testl %eax, %eax
sete %r12b
jmp 0x107689
xorl %r12d, %r12d
jmp 0x1076a9
xorl %r12d, %r12d
movq %r13, %rdi
callq 0x2220
movq (%r14), %rdi
callq 0x2220
movq %r14, %rdi
callq 0x2220
movq %rbx, %rdi
callq 0x2390
movl %r12d, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Trio.cpp
// Function: ha_triobin(hifiasm_opt_t const*)
void ha_triobin(const hifiasm_opt_t *opt)
{
	memset(R_INF.trio_flag, AMBIGU, R_INF.total_reads * sizeof(uint8_t));
	if (opt->fn_bin_list[0] && opt->fn_bin_list[1])
		ha_triobin_list(opt);
	if (opt->fn_bin_yak[0] && opt->fn_bin_yak[1])
		ha_triobin_yak(opt);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x18e1e8(%rip), %r14    # 0x296230
movq 0x28(%r14), %rdi
movq 0x50(%r14), %rdx
xorl %esi, %esi
callq 0x20e0
cmpq $0x0, 0x30(%rbx)
je 0x108065
cmpq $0x0, 0x38(%rbx)
jne 0x10807d
movq 0x20(%rbx), %rsi
testq %rsi, %rsi
je 0x108075
cmpq $0x0, 0x28(%rbx)
jne 0x10809a
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq 0x50(%r14), %rdi
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpq %rax, %rdi
jae 0x1080a8
leaq 0x30(%rbx), %rsi
leaq 0x38(%rbx), %rdx
callq 0x11cc1
jmp 0x108065
leaq 0x28(%rbx), %rdx
movq %rbx, %rdi
callq 0x11e4f
jmp 0x108075
leaq 0x131311(%rip), %rdi    # 0x2393c0
leaq 0x13132b(%rip), %rsi    # 0x2393e1
leaq 0x131420(%rip), %rcx    # 0x2394dd
movl $0x14d, %edx            # imm = 0x14D
callq 0x2110
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Trio.cpp
// Function: ha_triobin_set_list(cstr_ht_t const*, char const*, int)
static int ha_triobin_set_list(const cstr_ht_t *h, const char *fn, int flag)
{
	gzFile fp;
	kstream_t *ks;
	kstring_t str = {0,0,0};
	int dret;
	int64_t n_tot = 0, n_bin = 0;
	fp = gzopen(fn, "r");
	if (fp == 0) {
		fprintf(stderr, "ERROR: failed to open file '%s'\n", fn);
		return -1;
	}
	ks = ks_init(fp);
	while (ks_getuntil(ks, KS_SEP_LINE, &str, &dret) >= 0) {
		char *p;
		khint_t k;
		++n_tot;
		for (p = str.s; *p; ++p)
			if (*p == '\t' || *p == ' ')
				*p = 0;
		k = cstr_ht_get(h, str.s);
		if (k != kh_end(h)) {
			R_INF.trio_flag[kh_val(h, k)] = flag;
			++n_bin;
		}
	}
	free(str.s);
	ks_destroy(ks);
	gzclose(fp);
	fprintf(stderr, "[M::%s::%.3f*%.2f] flagged %ld reads, out of %ld lines in file '%s'\n",
			__func__, yak_realtime(), yak_cpu_usage(), (long)n_bin, (long)n_tot, fn);
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %edx, (%rsp)
movq %rsi, %rbx
movq %rdi, %r15
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rsp)
movq $0x0, 0x20(%rsp)
leaq 0x137701(%rip), %rsi    # 0x23f7f7
movq %rbx, %rdi
callq 0x22d0
testq %rax, %rax
jne 0x10812c
movq 0x18ced6(%rip), %rax    # 0x294fe0
movq (%rax), %rdi
leaq 0x131351(%rip), %rsi    # 0x239465
movq %rbx, %rdx
xorl %eax, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x22b0
movq %rax, %r14
movq %rbx, 0x30(%rsp)
movl $0x1, %edi
movl $0x20, %esi
callq 0x2120
movq %rax, %r12
movq %r14, 0x28(%rsp)
movq %r14, 0x18(%rax)
movl $0x10000, %edi          # imm = 0x10000
callq 0x2280
movq %rax, (%r12)
leaq 0x10(%rsp), %rsi
leaq 0xc(%rsp), %rdx
movq %r12, %rdi
callq 0x1076bb
testl %eax, %eax
js 0x108202
xorl %r13d, %r13d
leaq 0x10(%rsp), %r14
leaq 0xc(%rsp), %rbp
xorl %ebx, %ebx
movq 0x20(%rsp), %rsi
movq %rsi, %rax
movzbl (%rax), %ecx
cmpl $0x9, %ecx
je 0x1081a1
cmpl $0x20, %ecx
je 0x1081a1
testl %ecx, %ecx
jne 0x1081a4
jmp 0x1081a9
movb $0x0, (%rax)
incq %rax
jmp 0x10818e
movq %r15, %rdi
callq 0x107f82
movq 0x10(%r15), %rdx
testq %rdx, %rdx
je 0x1081c6
movb (%r15), %cl
movl $0x1, %esi
shll %cl, %esi
jmp 0x1081c8
xorl %esi, %esi
cmpl %esi, %eax
je 0x1081eb
leaq 0x18e05d(%rip), %rcx    # 0x296230
movq 0x28(%rcx), %rcx
movl %eax, %eax
shlq $0x4, %rax
movq 0x8(%rdx,%rax), %rax
movl (%rsp), %edx
movb %dl, (%rcx,%rax)
incq %r13
incq %rbx
movq %r12, %rdi
movq %r14, %rsi
movq %rbp, %rdx
callq 0x1076bb
testl %eax, %eax
jns 0x108186
jmp 0x108207
xorl %ebx, %ebx
xorl %r13d, %r13d
movq 0x20(%rsp), %rdi
callq 0x2220
movq (%r12), %rdi
callq 0x2220
movq %r12, %rdi
callq 0x2220
movq 0x28(%rsp), %rdi
callq 0x2390
movq 0x18cdad(%rip), %rax    # 0x294fe0
movq (%rax), %r14
callq 0x1365ef
movsd %xmm0, (%rsp)
callq 0x1366b8
movaps %xmm0, %xmm1
leaq 0x1312ca(%rip), %rsi    # 0x239519
leaq 0x131308(%rip), %rdx    # 0x23955e
movq %r14, %rdi
movsd (%rsp), %xmm0
movq %r13, %rcx
movq %rbx, %r8
movq 0x30(%rsp), %r9
movb $0x2, %al
callq 0x22b0
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/kthread.cpp
// Function: kt_for
void kt_for(int n_threads, void (*func)(void*,long,int), void *data, long n)
{
	if (n_threads > 1) {
		int i;
		kt_for_t t;
		pthread_t *tid;
		t.func = func, t.data = data, t.n_threads = n_threads, t.n = n;
		t.w = (ktf_worker_t*)calloc(n_threads, sizeof(ktf_worker_t));
		tid = (pthread_t*)calloc(n_threads, sizeof(pthread_t));
		for (i = 0; i < n_threads; ++i)
			t.w[i].t = &t, t.w[i].i = i;
		for (i = 0; i < n_threads; ++i) pthread_create(&tid[i], 0, ktf_worker, &t.w[i]);
		for (i = 0; i < n_threads; ++i) pthread_join(tid[i], 0);
		free(tid); free(t.w);
	} else {
		long j;
		for (j = 0; j < n; ++j) func(data, j, 0);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r15
cmpl $0x1, %edi
jle 0x109001
movq %rsp, %r12
movq %r15, 0x18(%r12)
movq %r14, 0x20(%r12)
movl %edi, (%r12)
movq %rbx, 0x8(%r12)
movl %edi, %ebx
movl $0x10, %esi
movq %rbx, %rdi
callq 0x2120
movq %rax, %r15
movq %rax, 0x10(%r12)
movl $0x8, %esi
movq %rbx, %rdi
callq 0x2120
movq %rax, %r14
addq $0x8, %r15
xorl %eax, %eax
movq %r12, -0x8(%r15)
movq %rax, (%r15)
incq %rax
addq $0x10, %r15
cmpq %rax, %rbx
jne 0x108f8f
movq %rbx, %r13
shlq $0x4, %r13
xorl %ebp, %ebp
leaq 0x79(%rip), %r15        # 0x10902b
movq %r14, %r12
movq 0x10(%rsp), %rcx
addq %rbp, %rcx
movq %r12, %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0x23c0
addq $0x10, %rbp
addq $0x8, %r12
cmpq %rbp, %r13
jne 0x108fb5
xorl %r15d, %r15d
movq (%r14,%r15,8), %rdi
xorl %esi, %esi
callq 0x2170
incq %r15
cmpq %r15, %rbx
jne 0x108fda
movq %r14, %rdi
callq 0x2220
movq 0x10(%rsp), %rdi
callq 0x2220
jmp 0x10901c
testq %rbx, %rbx
jle 0x10901c
xorl %r12d, %r12d
movq %r14, %rdi
movq %r12, %rsi
xorl %edx, %edx
callq *%r15
incq %r12
cmpq %r12, %rbx
jne 0x109009
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/kthread.cpp
// Function: ktf_worker(void*)
static void *ktf_worker(void *data)
{
	ktf_worker_t *w = (ktf_worker_t*)data;
	long i;
	for (;;) {
		i = __sync_fetch_and_add(&w->i, w->t->n_threads);
		if (i >= w->t->n) break;
		w->t->func(w->t->data, i, w - w->t->w);
	}
	while ((i = steal_work(w->t)) >= 0)
		w->t->func(w->t->data, i, w - w->t->w);
	pthread_exit(0);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rax
movslq (%rax), %rsi
lock
xaddq %rsi, 0x8(%rdi)
movq (%rdi), %rax
cmpq 0x8(%rax), %rsi
jge 0x10906b
movq 0x20(%rax), %rdi
movq %rbx, %rdx
subq 0x10(%rax), %rdx
shrq $0x4, %rdx
callq *0x18(%rax)
movq (%rbx), %rax
movslq (%rax), %rsi
lock
xaddq %rsi, 0x8(%rbx)
movq (%rbx), %rax
jmp 0x109042
movabsq $0x7fffffffffffffff, %r14 # imm = 0x7FFFFFFFFFFFFFFF
movq $-0x1, %r15
movslq (%rax), %rsi
movq 0x10(%rax), %rcx
movq $-0x1, %rdx
testq %rsi, %rsi
jle 0x1090bb
leaq 0x8(%rcx), %rdi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
xorl %r8d, %r8d
movq %r14, %r9
movq (%rdi), %r10
cmpq %r10, %r9
cmovgl %r8d, %edx
cmovgeq %r10, %r9
incq %r8
addq $0x10, %rdi
cmpq %r8, %rsi
jne 0x10909e
movslq %edx, %rdx
shlq $0x4, %rdx
lock
xaddq %rsi, 0x8(%rcx,%rdx)
cmpq 0x8(%rax), %rsi
cmovgeq %r15, %rsi
testq %rsi, %rsi
js 0x1090ed
movq (%rbx), %rax
movq 0x20(%rax), %rdi
movq %rbx, %rdx
subq 0x10(%rax), %rdx
shrq $0x4, %rdx
callq *0x18(%rax)
movq (%rbx), %rax
jmp 0x10907c
xorl %edi, %edi
callq 0x23b0
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/kthread.cpp
// Function: kt_pipeline
void kt_pipeline(int n_threads, void *(*func)(void*, int, void*), void *shared_data, int n_steps)
{
	ktp_t aux;
	pthread_t *tid;
	int i;

	if (n_threads < 1) n_threads = 1;
	aux.n_workers = n_threads;
	aux.n_steps = n_steps;
	aux.func = func;
	aux.shared = shared_data;
	aux.index = 0;
	pthread_mutex_init(&aux.mutex, 0);
	pthread_cond_init(&aux.cv, 0);

	aux.workers = (ktp_worker_t*)calloc(n_threads, sizeof(ktp_worker_t));
	for (i = 0; i < n_threads; ++i) {
		ktp_worker_t *w = &aux.workers[i];
		w->step = 0; w->pl = &aux; w->data = 0;
		w->index = aux.index++;
	}

	tid = (pthread_t*)calloc(n_threads, sizeof(pthread_t));
	for (i = 0; i < n_threads; ++i) pthread_create(&tid[i], 0, ktp_worker, &aux.workers[i]);
	for (i = 0; i < n_threads; ++i) pthread_join(tid[i], 0);
	free(tid); free(aux.workers);

	pthread_mutex_destroy(&aux.mutex);
	pthread_cond_destroy(&aux.cv);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
cmpl $0x2, %edi
movl $0x1, %r15d
cmovgel %edi, %r15d
leaq 0x30(%rsp), %rdi
movl %r15d, -0x10(%rdi)
movl %ecx, -0xc(%rdi)
movq %rsi, -0x20(%rdi)
movq %rdx, -0x28(%rdi)
movq $0x0, -0x18(%rdi)
xorl %r12d, %r12d
xorl %esi, %esi
callq 0x22e0
leaq 0x58(%rsp), %rbx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x2240
movl $0x20, %esi
movq %r15, %rdi
callq 0x2120
movq %rax, -0x30(%rbx)
movq -0x40(%rbx), %rcx
movq %r15, %r14
shlq $0x5, %r14
leaq 0x8(%rsp), %rdx
movl $0x0, 0x10(%rax,%r12)
movq %rdx, (%rax,%r12)
movq $0x0, 0x18(%rax,%r12)
movq %rcx, 0x8(%rax,%r12)
incq %rcx
addq $0x20, %r12
cmpq %r12, %r14
jne 0x109168
movq %rcx, 0x18(%rsp)
movl $0x8, %esi
movq %r15, %rdi
callq 0x2120
movq %rax, %r12
xorl %ebx, %ebx
leaq 0x72(%rip), %r13        # 0x10921f
movq %rax, %rbp
movq 0x28(%rsp), %rcx
addq %rbx, %rcx
movq %rbp, %rdi
xorl %esi, %esi
movq %r13, %rdx
callq 0x23c0
addq $0x20, %rbx
addq $0x8, %rbp
cmpq %rbx, %r14
jne 0x1091b0
xorl %ebx, %ebx
movq (%r12,%rbx,8), %rdi
xorl %esi, %esi
callq 0x2170
incq %rbx
cmpq %rbx, %r15
jne 0x1091d4
movq %r12, %rdi
callq 0x2220
movq 0x28(%rsp), %rdi
callq 0x2220
leaq 0x30(%rsp), %rdi
callq 0x21f0
leaq 0x58(%rsp), %rdi
callq 0x2400
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/kthread.cpp
// Function: ktp_worker(void*)
static void *ktp_worker(void *data)
{
	ktp_worker_t *w = (ktp_worker_t*)data;
	ktp_t *p = w->pl;
	while (w->step < p->n_steps) {
		// test whether we can kick off the job with this worker
		pthread_mutex_lock(&p->mutex);
		for (;;) {
			int i;
			// test whether another worker is doing the same step
			for (i = 0; i < p->n_workers; ++i) {
				if (w == &p->workers[i]) continue; // ignore itself
				if (p->workers[i].step <= w->step && p->workers[i].index < w->index)
					break;
			}
			if (i == p->n_workers) break; // no workers with smaller indices are doing w->step or the previous steps
			pthread_cond_wait(&p->cv, &p->mutex);
		}
		pthread_mutex_unlock(&p->mutex);

		// working on w->step
		w->data = p->func(p->shared, w->step, w->step? w->data : 0); // for the first step, input is NULL

		// update step and let other workers know
		pthread_mutex_lock(&p->mutex);
		w->step = w->step == p->n_steps - 1 || w->data? (w->step + 1) % p->n_steps : p->n_steps;
		if (w->step == 0) w->index = p->index++;
		pthread_cond_broadcast(&p->cv);
		pthread_mutex_unlock(&p->mutex);
	}
	pthread_exit(0);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq (%rdi), %r12
movl 0x10(%rdi), %eax
cmpl 0x1c(%r12), %eax
jge 0x109318
movq %rdi, %rbx
leaq 0x28(%r12), %r14
leaq 0x50(%r12), %r15
movq %r14, %rdi
callq 0x22c0
movslq 0x18(%r12), %rax
testq %rax, %rax
jle 0x109283
movq 0x20(%r12), %rdx
xorl %ecx, %ecx
cmpq %rbx, %rdx
je 0x109275
movl 0x10(%rdx), %esi
cmpl 0x10(%rbx), %esi
jg 0x109275
movq 0x8(%rdx), %rsi
cmpq 0x8(%rbx), %rsi
jl 0x109285
incq %rcx
addq $0x20, %rdx
cmpq %rcx, %rax
jne 0x10925e
jmp 0x109296
xorl %ecx, %ecx
cmpl %eax, %ecx
je 0x109296
movq %r15, %rdi
movq %r14, %rsi
callq 0x2300
jmp 0x10924d
movq %r14, %rdi
callq 0x2130
movq (%r12), %rdi
movq 0x8(%r12), %rax
movl 0x10(%rbx), %esi
testl %esi, %esi
je 0x1092b4
movq 0x18(%rbx), %rdx
jmp 0x1092b6
xorl %edx, %edx
callq *%rax
movq %rax, 0x18(%rbx)
movq %r14, %rdi
callq 0x22c0
movl 0x10(%rbx), %eax
movl 0x1c(%r12), %ecx
leal -0x1(%rcx), %edx
cmpl %edx, %eax
je 0x1092da
cmpq $0x0, 0x18(%rbx)
je 0x1092e1
incl %eax
cltd
idivl %ecx
movl %edx, %ecx
movl %ecx, 0x10(%rbx)
testl %ecx, %ecx
jne 0x1092fa
movq 0x10(%r12), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0x10(%r12)
movq %rax, 0x8(%rbx)
movq %r15, %rdi
callq 0x2070
movq %r14, %rdi
callq 0x2130
movl 0x10(%rbx), %eax
cmpl 0x1c(%r12), %eax
jl 0x109245
xorl %edi, %edi
callq 0x23b0
nop
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: init_hap_alignment_struct(hap_alignment_struct*, unsigned int)
void init_hap_alignment_struct(hap_alignment_struct* x, uint32_t size)
{
    x->vote_counting = (uint64_t*)malloc(sizeof(uint64_t)*size);
    memset(x->vote_counting, 0, sizeof(uint64_t)*size);

    x->visit = (uint8_t*)malloc(sizeof(uint8_t)*size);
    memset(x->visit, 0, size);

    kv_init(x->u_vecs.a);
    kv_init(x->u_buffer.a);
    kv_init(x->u_buffer_tailIndex.a);
    kv_init(x->u_buffer_prevIndex.a);
    kv_init(x->u_buffer_beg.a);
    kv_init(x->u_buffer_flag.a);
    kv_init(x->u_can.a);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl %esi, %r14d
leaq (,%r14,8), %rsi
movl $0x1, %edi
callq 0x2120
movq %rax, (%rbx)
movl $0x1, %edi
movq %r14, %rsi
callq 0x2120
movq %rax, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
xorl %eax, %eax
movq %rax, 0x20(%rbx)
movups %xmm0, 0x30(%rbx)
movq %rax, 0x40(%rbx)
movups %xmm0, 0x50(%rbx)
movq %rax, 0x60(%rbx)
movups %xmm0, 0x70(%rbx)
movq %rax, 0x80(%rbx)
movups %xmm0, 0x90(%rbx)
movq %rax, 0xa0(%rbx)
movups %xmm0, 0xb0(%rbx)
movq %rax, 0xc0(%rbx)
movq %rax, 0xe0(%rbx)
movups %xmm0, 0xd0(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: init_pip_hh(asg_t*, ma_hit_t_alloc*, ma_sub_t*, long long)
uint8_t *init_pip_hh(asg_t *rg, ma_hit_t_alloc* reverse_sources, ma_sub_t *coverage_cut, long long sc)
{
    uint8_t *c = NULL; CALLOC(c, rg->n_seq);
    ma_hit_t *h = NULL;
    uint32_t i, k;
    long long R_Base, C_Base;
    for (i = 0; i < rg->n_seq; i++) {
        if(sc <= 0){
            c[i] = 1;
            continue;
        }
        R_Base = (coverage_cut[i].e - coverage_cut[i].s);
        for (k = 0, C_Base = 0; k < reverse_sources[i].length; k++){
            h = &(reverse_sources[i].buffer[k]);
            C_Base += (Get_qe((*h)) - Get_qs((*h)));
        }
        C_Base = (R_Base!=0?(C_Base/R_Base):0);
        C_Base /= sc;
        c[i] = 1;
        if(C_Base < REV_W) c[i] = REV_W -  C_Base;
    }
    return c;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r15
movl 0x14(%rdi), %r12d
movq %r12, %rdi
andq $0x7fffffff, %rdi       # imm = 0x7FFFFFFF
movl $0x1, %esi
callq 0x2120
movq %rax, %rcx
andq $0x7fffffff, %r12       # imm = 0x7FFFFFFF
je 0x10a25e
xorl %esi, %esi
movl $0x7fffffff, %edi       # imm = 0x7FFFFFFF
testq %rbx, %rbx
jle 0x10a21c
leaq (%rsi,%rsi,2), %rdx
movl 0xc(%r15,%rdx,8), %eax
testq %rax, %rax
je 0x10a222
leaq (%r15,%rdx,8), %r8
movq (%r8), %r8
shlq $0x3, %rax
leaq (%rax,%rax,4), %r9
xorl %r10d, %r10d
xorl %eax, %eax
movl 0x8(%r8,%r10), %r11d
subl (%r8,%r10), %r11d
addq %r11, %rax
addq $0x28, %r10
cmpq %r10, %r9
jne 0x10a205
jmp 0x10a224
movb $0x1, (%rcx,%rsi)
jmp 0x10a256
xorl %eax, %eax
movl 0x4(%r14,%rdx,4), %r8d
movl (%r14,%rdx,4), %edx
andl %edi, %edx
cmpl %edx, %r8d
jne 0x10a238
xorl %eax, %eax
jmp 0x10a240
subl %edx, %r8d
xorl %edx, %edx
divq %r8
cqto
idivq %rbx
movb $0x1, (%rcx,%rsi)
cmpq $0x7, %rax
jg 0x10a256
movb $0x8, %dl
subb %al, %dl
movb %dl, (%rcx,%rsi)
incq %rsi
cmpq %r12, %rsi
jne 0x10a1de
movq %rcx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: destory_hap_alignment_struct_pip(hap_alignment_struct_pip*)
void destory_hap_alignment_struct_pip(hap_alignment_struct_pip* x)
{
    uint32_t i;
    for (i = 0; i < x->num_threads; i++)
    {
        destory_hap_alignment_struct(&(x->buf[i]));
    }

    free(x->buf);
    free(x->hh);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
cmpl $0x0, 0x8(%rdi)
je 0x10a3e4
xorl %r14d, %r14d
xorl %r15d, %r15d
movq (%rbx), %rdi
addq %r14, %rdi
callq 0x10a13d
incq %r15
movl 0x8(%rbx), %eax
addq $0xf0, %r14
cmpq %rax, %r15
jb 0x10a3c7
movq (%rbx), %rdi
callq 0x2220
movq 0x10(%rbx), %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x2220
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: init_hap_overlaps_list(hap_overlaps_list*, unsigned int)
void init_hap_overlaps_list(hap_overlaps_list* x, uint32_t num)
{
    uint32_t i = 0;
    x->num = num;
    x->x = (kvec_hap_overlaps*)malloc(sizeof(kvec_hap_overlaps)*x->num);
    for (i = 0; i < x->num; i++)
    {
        kv_init(x->x[i].a);
    }
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %ebp
movq %rdi, %r14
movl %esi, 0x8(%rdi)
movl %esi, %eax
shlq $0x3, %rax
leaq (%rax,%rax,2), %rbx
movq %rbx, %rdi
callq 0x2280
movq %rax, (%r14)
testl %ebp, %ebp
je 0x10a430
movq %rax, %rdi
xorl %esi, %esi
movq %rbx, %rdx
popq %rbx
popq %r14
popq %rbp
jmp 0x20e0
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: destory_hap_overlaps_list(hap_overlaps_list*)
void destory_hap_overlaps_list(hap_overlaps_list* x)
{
    uint32_t i = 0;
    for (i = 0; i < x->num; i++)
    {
        kv_destroy(x->x[i].a);
    }
    free(x->x);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
cmpl $0x0, 0x8(%rdi)
je 0x10a46f
movl $0x10, %r14d
xorl %r15d, %r15d
movq (%rbx), %rax
movq (%rax,%r14), %rdi
callq 0x2220
incq %r15
movl 0x8(%rbx), %eax
addq $0x18, %r14
cmpq %rax, %r15
jb 0x10a454
movq (%rbx), %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x2220
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: deduplicate_edge(kvec_asg_arc_t_offset*)
void deduplicate_edge(kvec_asg_arc_t_offset* u_buffer)
{
    if(u_buffer->a.n == 0) return;
    long long i = u_buffer->a.n - 1, k, i_off;
    uint32_t v = u_buffer->a.a[i].x.ul>>33, m;

    for (; i >= 0; i--) {
        if((u_buffer->a.a[i].x.ul>>33) != v) break;
    }

    i = i + 1;
    for (m = i; i < (long long)u_buffer->a.n; i++)
    {
        if(u_buffer->a.a[i].x.del) continue;

        i_off = Cal_Off(u_buffer->a.a[i].Off);

        for (k = i + 1; k < (long long)u_buffer->a.n; k++)
        {
            if(u_buffer->a.a[k].x.del) continue;
            if(u_buffer->a.a[i].x.el != u_buffer->a.a[k].x.el) continue;
            if(i_off != Cal_Off(u_buffer->a.a[k].Off)) continue;
            u_buffer->a.a[k].x.del = 1;
            u_buffer->a.a[i].weight += u_buffer->a.a[k].weight;
        }
        u_buffer->a.a[m] = u_buffer->a.a[i];
        m++;
    }

    u_buffer->a.n = m;
    ///fprintf(stderr, "u_buffer->a.n: %u, i: %lld\n", u_buffer->a.n, i);
}

// Assembly:
movq (%rdi), %rcx
testq %rcx, %rcx
je 0x10a601
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
movq %rcx, %rax
decq %rax
js 0x10a5f4
movq 0x10(%rdi), %rsi
leaq (%rax,%rax,4), %rax
movq (%rsi,%rax,8), %rdx
leaq (%rcx,%rcx,4), %rax
leaq (%rsi,%rax,8), %rsi
addq $-0x28, %rsi
movq %rcx, %rax
movq (%rsi), %r8
xorq %rdx, %r8
decq %rax
shrq $0x21, %r8
jne 0x10a51b
addq $-0x28, %rsi
testq %rax, %rax
jg 0x10a4fc
movq $-0x1, %rax
incq %rax
cmpq %rcx, %rax
jge 0x10a5f6
movq %rax, %r10
movq 0x10(%rdi), %rsi
leaq (%r10,%r10,4), %r8
cmpl $0x0, 0xc(%rsi,%r8,8)
js 0x10a5e3
leaq 0x1(%r10), %rdx
cmpq %rcx, %rdx
jge 0x10a5b5
leaq (%rsi,%r8,8), %r9
movq 0x18(%r9), %r9
movl %r9d, %r11d
shrq $0x20, %r9
subq %r11, %r9
shlq $0x3, %r10
leaq (%r10,%r10,4), %r10
movq %rdx, %r11
movl 0x34(%rsi,%r10), %ebx
testl %ebx, %ebx
js 0x10a5a9
movb 0x12(%rsi,%r8,8), %bpl
cmpb 0x3a(%rsi,%r10), %bpl
jne 0x10a5a9
movq 0x40(%rsi,%r10), %r14
movl %r14d, %r15d
shrq $0x20, %r14
subq %r15, %r14
cmpq %r14, %r9
jne 0x10a5a9
orl $0x80000000, %ebx       # imm = 0x80000000
movl %ebx, 0x34(%rsi,%r10)
movq 0x10(%rdi), %rsi
movq 0x48(%rsi,%r10), %rcx
addq %rcx, 0x20(%rsi,%r8,8)
movq (%rdi), %rcx
incq %r11
addq $0x28, %r10
cmpq %rcx, %r11
jl 0x10a564
movl %eax, %ecx
leaq (%rcx,%rcx,4), %rcx
movq 0x20(%rsi,%r8,8), %r9
movq %r9, 0x20(%rsi,%rcx,8)
movups (%rsi,%r8,8), %xmm0
movups 0x10(%rsi,%r8,8), %xmm1
movups %xmm1, 0x10(%rsi,%rcx,8)
movups %xmm0, (%rsi,%rcx,8)
incl %eax
movq (%rdi), %rcx
movq %rdx, %r10
jmp 0x10a5e9
incq %r10
movq %r10, %rdx
cmpq %rcx, %rdx
jl 0x10a52a
jmp 0x10a5f6
movl %ecx, %eax
movl %eax, %eax
movq %rax, (%rdi)
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: cmp_hap_alignment(void const*, void const*)
int cmp_hap_alignment(const void * a, const void * b)
{
    if((*(asg_arc_t_offset*)a).x.el > (*(asg_arc_t_offset*)b).x.el) return 1;
    if((*(asg_arc_t_offset*)a).x.el < (*(asg_arc_t_offset*)b).x.el) return -1;

    long long aOff = Cal_Off((*(asg_arc_t_offset*)a).Off);
    long long bOff = Cal_Off((*(asg_arc_t_offset*)b).Off);

    if(aOff > bOff) return 1;
    if(aOff < bOff) return -1;

    if(((*(asg_arc_t_offset*)a).Off>>32) > ((*(asg_arc_t_offset*)b).Off>>32)) return 1;
    if(((*(asg_arc_t_offset*)a).Off>>32) < ((*(asg_arc_t_offset*)b).Off>>32)) return -1;

    if((uint32_t)((*(asg_arc_t_offset*)a).Off) > (uint32_t)((*(asg_arc_t_offset*)b).Off)) return 1;
    if((uint32_t)((*(asg_arc_t_offset*)a).Off) < (uint32_t)((*(asg_arc_t_offset*)b).Off)) return -1;

    if((*(asg_arc_t_offset*)a).weight < (*(asg_arc_t_offset*)b).weight) return 1;
    if((*(asg_arc_t_offset*)a).weight > (*(asg_arc_t_offset*)b).weight) return -1;

    return 0;
}

// Assembly:
movb 0x12(%rsi), %al
cmpb %al, 0x12(%rdi)
jbe 0x10a610
movl $0x1, %eax
retq
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jae 0x10a618
retq
pushq %rbx
movq 0x18(%rdi), %rcx
movq %rcx, %rdx
shrq $0x20, %rdx
movl %ecx, %r8d
movq %rdx, %r10
subq %r8, %r10
movq 0x18(%rsi), %r8
movq %r8, %r9
shrq $0x20, %r9
movl %r8d, %r11d
movq %r9, %rbx
subq %r11, %rbx
cmpq %rbx, %r10
popq %rbx
jg 0x10a60a
jl 0x10a617
cmpl %r9d, %edx
ja 0x10a60a
cmpl %r9d, %edx
jb 0x10a617
cmpl %r8d, %ecx
ja 0x10a60a
jb 0x10a617
movq 0x20(%rdi), %rcx
movq 0x20(%rsi), %rdx
movl $0x1, %eax
cmpq %rdx, %rcx
jb 0x10a617
xorl %eax, %eax
cmpq %rcx, %rdx
sbbl %eax, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: cmp_hap_alignment_chaining(void const*, void const*)
int cmp_hap_alignment_chaining(const void * a, const void * b)
{
    if((*(asg_arc_t_offset*)a).x.el > (*(asg_arc_t_offset*)b).x.el) return 1;
    if((*(asg_arc_t_offset*)a).x.el < (*(asg_arc_t_offset*)b).x.el) return -1;

    if(((*(asg_arc_t_offset*)a).Off>>32) > ((*(asg_arc_t_offset*)b).Off>>32)) return 1;
    if(((*(asg_arc_t_offset*)a).Off>>32) < ((*(asg_arc_t_offset*)b).Off>>32)) return -1;

    if((uint32_t)((*(asg_arc_t_offset*)a).Off) > (uint32_t)((*(asg_arc_t_offset*)b).Off)) return 1;
    if((uint32_t)((*(asg_arc_t_offset*)a).Off) < (uint32_t)((*(asg_arc_t_offset*)b).Off)) return -1;

    return 0;
}

// Assembly:
movb 0x12(%rsi), %al
cmpb %al, 0x12(%rdi)
jbe 0x10a682
movl $0x1, %eax
retq
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jae 0x10a68a
retq
movq 0x18(%rdi), %rcx
movq %rcx, %rdi
shrq $0x20, %rdi
movq 0x18(%rsi), %rdx
movq %rdx, %rsi
shrq $0x20, %rsi
cmpq %rsi, %rdi
ja 0x10a67c
cmpl %esi, %edi
jb 0x10a689
movl $0x1, %eax
cmpl %edx, %ecx
ja 0x10a689
xorl %eax, %eax
cmpl %edx, %ecx
sbbl %eax, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: cmp_hap_candidates(void const*, void const*)
int cmp_hap_candidates(const void * a, const void * b)
{
    if((*(hap_candidates*)a).weight < (*(hap_candidates*)b).weight) return 1;
    if((*(hap_candidates*)a).weight > (*(hap_candidates*)b).weight) return -1;

    if((*(hap_candidates*)a).index_beg > (*(hap_candidates*)b).index_beg) return 1;
    if((*(hap_candidates*)a).index_beg < (*(hap_candidates*)b).index_beg) return -1;
    
    return 0;
}

// Assembly:
movq (%rsi), %rcx
movl $0x1, %eax
cmpq %rcx, (%rdi)
jb 0x10a6e2
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
ja 0x10a6e2
movl 0x18(%rdi), %ecx
movl 0x18(%rsi), %edx
movl $0x1, %eax
cmpl %edx, %ecx
ja 0x10a6e2
xorl %eax, %eax
cmpl %edx, %ecx
sbbl %eax, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: classify_hap_overlap(long long, long long, long long, long long, long long, long long, long long*, long long*, long long*, long long*)
uint32_t classify_hap_overlap(long long xBeg, long long xEnd, long long xLen,
long long yBeg, long long yEnd, long long yLen, long long* r_xBeg, long long* r_xEnd, 
long long* r_yBeg, long long* r_yEnd)
{
    long long n_x_beg, n_x_end, n_y_beg, n_y_end;
    get_hap_overlapLen(xBeg, xEnd, xLen, yBeg, yEnd, yLen, &n_x_beg, &n_x_end, &n_y_beg, &n_y_end);
    if(r_xBeg) (*r_xBeg) = n_x_beg;
    if(r_xEnd) (*r_xEnd) = n_x_end;
    if(r_yBeg) (*r_yBeg) = n_y_beg;
    if(r_yEnd) (*r_yEnd) = n_y_end;
    if(n_x_beg == 0 && n_x_end == xLen - 1) return YCX;
    if(n_y_beg == 0 && n_y_end == yLen - 1) return XCY;
    if(n_y_beg == 0 && n_x_end == xLen - 1) return X2Y;
    if(n_x_beg == 0 && n_y_end == yLen - 1) return Y2X;
    return XCY;
}

// Assembly:
pushq %rbx
xorl %ebx, %ebx
movq %rdi, %r11
subq %rcx, %r11
movl $0x0, %r10d
cmovgq %r11, %r10
negq %r11
cmpq %rcx, %rdi
movq 0x10(%rsp), %rax
cmovgq %rbx, %r11
movq %rsi, %rdi
notq %rdi
addq %rdx, %rdi
leaq (%rdi,%r8), %rcx
notq %r8
addq %r9, %r8
decq %rdx
addq %r8, %rsi
decq %r9
cmpq %r8, %rdi
cmovgq %r9, %rcx
movq 0x18(%rsp), %rdi
cmovleq %rdx, %rsi
testq %rax, %rax
je 0x10a739
movq %r10, (%rax)
movq 0x20(%rsp), %rax
testq %rdi, %rdi
je 0x10a746
movq %rsi, (%rdi)
movq 0x28(%rsp), %rdi
testq %rax, %rax
je 0x10a753
movq %r11, (%rax)
testq %rdi, %rdi
je 0x10a75b
movq %rcx, (%rdi)
movq %rsi, %rdi
xorq %rdx, %rdi
movl $0x3, %eax
orq %r10, %rdi
je 0x10a797
testq %r11, %r11
jne 0x10a78a
cmpq %rdx, %rsi
sete %sil
xorl %eax, %eax
cmpq %r9, %rcx
sete %dl
orb %dl, %sil
je 0x10a78a
movb %dl, %al
addl %eax, %eax
jmp 0x10a797
xorq %r9, %rcx
xorl %eax, %eax
orq %rcx, %r10
setne %al
incl %eax
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: get_pair_hap_coverage(unsigned long*, unsigned int, ma_hit_t_alloc*, ma_sub_t*)
uint64_t get_pair_hap_coverage(uint64_t* readIDs, uint32_t Len, ma_hit_t_alloc* sources, ma_sub_t* coverage_cut)
{
    uint32_t m, n, qn;
    ma_hit_t *h;
    uint64_t R_bases = 0, C_bases = 0;

    for (m = 0; m < Len; m++)
    {
        qn = readIDs[m]>>33;
        R_bases += coverage_cut[qn].e - coverage_cut[qn].s;
        for (n = 0; n < (uint64_t)(sources[qn].length); n++)
        {
            h = &(sources[qn].buffer[n]);
            C_bases += Get_qe((*h)) - Get_qs((*h));
        }
    }

    return C_bases/R_bases;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %esi, %esi
xorl %r9d, %r9d
movl $0x7fffffff, %r10d      # imm = 0x7FFFFFFF
xorl %eax, %eax
xorl %r8d, %r8d
movq (%rdi,%r9,8), %r11
shrq $0x21, %r11
leaq (%r11,%r11,2), %r11
movl 0xc(%rdx,%r11,8), %r14d
testq %r14, %r14
je 0x10a7ed
leaq (%rdx,%r11,8), %rbx
movq (%rbx), %rbx
shlq $0x3, %r14
leaq (%r14,%r14,4), %r14
xorl %r15d, %r15d
movl 0x8(%rbx,%r15), %r12d
subl (%rbx,%r15), %r12d
addq %r12, %rax
addq $0x28, %r15
cmpq %r15, %r14
jne 0x10a7d8
movl 0x4(%rcx,%r11,4), %ebx
movl (%rcx,%r11,4), %r11d
andl %r10d, %r11d
subl %r11d, %ebx
addq %rbx, %r8
incq %r9
cmpq %rsi, %r9
jne 0x10a7b0
xorl %edx, %edx
divq %r8
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: vote_overlap_type(kvec_asg_arc_t_offset*, hap_candidates*, unsigned long*, ma_utg_t*, ma_utg_t*)
uint32_t vote_overlap_type(kvec_asg_arc_t_offset* u_buffer, hap_candidates* hap_can, 
uint64_t* position_index, ma_utg_t* xReads, ma_utg_t* yReads)
{
    uint32_t i, xBasePos, yBasePos;
    asg_arc_t_offset* arch = NULL;
    uint32_t flag[4];
    flag[X2Y] = flag[Y2X] = flag[XCY] = flag[YCX] = 0;


    for (i = hap_can->index_beg; i <= hap_can->index_end; i++)
    {
        arch = &(u_buffer->a.a[i]);
        xBasePos = (uint32_t)(arch->Off>>32);
        yBasePos = (uint32_t)(arch->Off);
        flag[classify_hap_overlap(xBasePos, xBasePos, xReads->len, yBasePos, yBasePos, yReads->len,
        NULL, NULL, NULL, NULL)]++;
    }
    
    uint32_t max_flag_i = 0;
    for (i = 0; i < 4; i++)
    {
        if(i == max_flag_i) continue;
        if(flag[i] > flag[max_flag_i])
        {
            max_flag_i = i;
        }
    }
    
    return max_flag_i;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x30, %rsp
xorps %xmm0, %xmm0
movaps %xmm0, 0x20(%rsp)
movl 0x18(%rsi), %ebp
movl 0x1c(%rsi), %r15d
cmpl %r15d, %ebp
ja 0x10bde8
movq 0x10(%rdi), %r12
movl (%rcx), %ebx
movl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
andq %rax, %rbx
movl (%r8), %r14d
andq %rax, %r14
movl %ebp, %eax
leaq (%rax,%rax,4), %rax
movq 0x18(%r12,%rax,8), %rdi
movl %edi, %ecx
shrq $0x20, %rdi
movups %xmm0, 0x10(%rsp)
movups %xmm0, (%rsp)
movq %rdi, %rsi
movq %rbx, %rdx
movq %rcx, %r8
movq %r14, %r9
callq 0x10a6e3
xorps %xmm0, %xmm0
movl %eax, %eax
incl 0x20(%rsp,%rax,4)
incl %ebp
cmpl %r15d, %ebp
jbe 0x10bdad
xorl %ecx, %ecx
xorl %eax, %eax
movl %eax, %edx
cmpq %rdx, %rcx
je 0x10be03
movl 0x20(%rsp,%rcx,4), %edi
movl %ecx, %esi
cmpl 0x20(%rsp,%rdx,4), %edi
ja 0x10be01
movl %eax, %esi
movl %esi, %eax
incq %rcx
cmpq $0x4, %rcx
jne 0x10bdec
addq $0x30, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: get_xy_pos_by_pos(asg_t*, asg_arc_t*, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int, unsigned char*)
uint64_t get_xy_pos_by_pos(asg_t *read_g, asg_arc_t* t, uint32_t v_in_unitig, uint32_t w_in_unitig, 
uint32_t v_in_pos, uint32_t w_in_pos, uint32_t xUnitigLen, uint32_t yUnitigLen, uint8_t* rev)
{
    uint32_t x_pos, y_pos, x_dir = 0, y_dir = 0;
    uint64_t tmp;
    x_pos = y_pos = (uint32_t)-1;
    if((t->ul>>32)==v_in_unitig)///end pos
    {
        x_pos = v_in_pos + read_g->seq[v_in_unitig>>1].len - 1;
        x_dir = 0;
    }
    else if((t->ul>>32)==(v_in_unitig^1))///start pos
    {
        x_pos = v_in_pos;
        x_dir = 1;
    }
    else
    {
        fprintf(stderr, "ERROR\n");
    }
    
    if(t->v == w_in_unitig)
    {
        y_pos = w_in_pos + t->ol - 1;
        y_dir = 0;
    }
    else if(t->v == (w_in_unitig^1))
    {
        y_pos = w_in_pos + read_g->seq[w_in_unitig>>1].len - t->ol;
        y_dir = 1;
    }
    else
    {
        fprintf(stderr, "ERROR\n");
    }

    (*rev) = x_dir^y_dir;
    if((*rev))
    {
        if(yUnitigLen <= y_pos)
        {
            y_pos = (uint32_t)-1;
        }
        else
        {
            y_pos = yUnitigLen - y_pos - 1;
        }
    } 

    if(x_pos>=xUnitigLen) x_pos = (uint32_t)-1;
    if(y_pos>=yUnitigLen) y_pos = (uint32_t)-1;
    
    tmp = x_pos; tmp = tmp << 32; tmp = tmp | y_pos;
    return tmp;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r9d, %r14d
movl %r8d, %ebx
movl %ecx, %r12d
movq %rsi, %r15
movq %rdi, %r13
movq (%rsi), %rax
shrq $0x20, %rax
movl %edx, %ecx
cmpq %rcx, %rax
jne 0x10cc9b
movq 0x20(%r13), %rax
shrl %edx
movl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
andl (%rax,%rdx,8), %ecx
addl %ecx, %ebx
decl %ebx
xorl %ebp, %ebp
jmp 0x10cca9
xorl $0x1, %edx
movb $0x1, %bpl
cmpl %edx, %eax
jne 0x10cd38
movq 0x50(%rsp), %r8
movl 0x8(%r15), %eax
cmpl %r12d, %eax
jne 0x10ccc9
movl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
andl 0xc(%r15), %eax
addl %r14d, %eax
decl %eax
xorl %esi, %esi
jmp 0x10ccef
xorl %r12d, %eax
cmpl $0x1, %eax
jne 0x10cd47
movq 0x20(%r13), %rax
shrl %r12d
movl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
movl (%rax,%r12,8), %eax
andl %ecx, %eax
addl %r14d, %eax
andl 0xc(%r15), %ecx
subl %ecx, %eax
movb $0x1, %sil
movl 0x48(%rsp), %ecx
movl 0x40(%rsp), %edx
movl %esi, %edi
xorb %bpl, %dil
movb %dil, (%r8)
cmpb %sil, %bpl
je 0x10cd11
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
cmpl %ecx, %eax
jae 0x10cd13
notl %eax
addl %ecx, %eax
movl %eax, %esi
cmpl %edx, %ebx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmovael %eax, %ebx
cmpl %ecx, %esi
cmovbl %esi, %eax
shlq $0x20, %rbx
orq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x13271
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
jmp 0x10cc97
movq %r8, %r14
callq 0x1328d
movq %r14, %r8
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0x10ccc5
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: get_idx_by_base(ma_utg_t*, asg_t*, long long, long long, long long*, long long*)
void get_idx_by_base(ma_utg_t *x, asg_t *read_g, long long beg_base, long long end_base, 
                                            long long* beg_idx, long long* end_idx)
{
    long long offset, r_beg, r_end;
    uint64_t i, rId;
    (*beg_idx) = (*end_idx) = -1;
    for (i = 0, offset = 0; i < x->n; i++)
    {
        rId = x->a[i]>>33;
        r_beg = offset; r_end = offset + (long long)(read_g->seq[rId].len) - 1;
        offset += (uint32_t)x->a[i];
        if(beg_base > r_end || r_beg > end_base)
        {
            if((*beg_idx) != -1 && (*end_idx) != -1) break;
            continue;
        } 
        if((*beg_idx) == -1) (*beg_idx) = i;
        (*end_idx) = i;
    }
}

// Assembly:
movq $-0x1, %rax
movq %rax, (%r9)
movq %rax, (%r8)
movl 0x10(%rdi), %eax
testq %rax, %rax
je 0x10e5a8
pushq %r15
pushq %r14
pushq %rbx
movq 0x18(%rdi), %rdi
movq 0x20(%rsi), %rsi
xorl %ebx, %ebx
xorl %r10d, %r10d
movq (%rdi,%r10,8), %r15
movl %r15d, %r11d
addq %rbx, %r11
movq (%r8), %r14
cmpq %rcx, %rbx
jg 0x10e58c
shrq $0x21, %r15
movl (%rsi,%r15,8), %r15d
andl $0x7fffffff, %r15d      # imm = 0x7FFFFFFF
addq %r15, %rbx
cmpq %rdx, %rbx
jle 0x10e58c
cmpq $-0x1, %r14
jne 0x10e587
movq %r10, (%r8)
movq %r10, (%r9)
jmp 0x10e598
cmpq $-0x1, %r14
je 0x10e598
cmpq $-0x1, (%r9)
jne 0x10e5a3
incq %r10
movq %r11, %rbx
cmpq %rax, %r10
jb 0x10e555
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: adjust_hap_overlaps_score(ma_utg_t*, float*, long long*, long long, long long, long long, long long)
void adjust_hap_overlaps_score(ma_utg_t* xReads, float *sim, long long *score, 
long long xUid, long long yUid, long long xBeg, long long xEnd)
{
    uint64_t all, found;
    if(count_unique_k_mers(xReads->s + xBeg, xEnd+1-xBeg, xUid, yUid, &all, &found))
    {
        double k_w = 1;
        if(sim) (*sim) = MAX((*sim), (all == 0?0:(((double)found)/((double)all))));
        if(all) k_w += ((double)(found)/(double)(all));
        if(score) (*score) = ((*score)*k_w)/2;
    }
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %r8, %rax
movq %rdx, %rbx
movq %rsi, %r14
movq 0x30(%rsp), %rsi
movq 0x20(%rdi), %rdi
addq %r9, %rdi
subq %r9, %rsi
incq %rsi
leaq 0x10(%rsp), %r8
leaq 0x8(%rsp), %r9
movq %rcx, %rdx
movq %rax, %rcx
callq 0x164630
testq %rax, %rax
je 0x10ff5b
movq 0x10(%rsp), %rax
movq %rax, %xmm0
testq %r14, %r14
je 0x10fee2
movss (%r14), %xmm1
movsd 0x12140b(%rip), %xmm3   # 0x231280
movsd 0x8(%rsp), %xmm4
unpcklps %xmm3, %xmm4            # xmm4 = xmm4[0],xmm3[0],xmm4[1],xmm3[1]
movapd 0x12140a(%rip), %xmm5   # 0x231290
subpd %xmm5, %xmm4
movapd %xmm4, %xmm2
unpckhpd %xmm4, %xmm2            # xmm2 = xmm2[1],xmm4[1]
addsd %xmm4, %xmm2
movdqa %xmm0, %xmm4
punpckldq %xmm3, %xmm4    # xmm4 = xmm4[0],xmm3[0],xmm4[1],xmm3[1]
subpd %xmm5, %xmm4
movapd %xmm4, %xmm3
unpckhpd %xmm4, %xmm3            # xmm3 = xmm3[1],xmm4[1]
addsd %xmm4, %xmm3
divsd %xmm3, %xmm2
xorpd %xmm3, %xmm3
testq %rax, %rax
je 0x10febf
movapd %xmm2, %xmm3
xorps %xmm5, %xmm5
cvtss2sd %xmm1, %xmm5
xorpd %xmm4, %xmm4
je 0x10fed3
xorps %xmm4, %xmm4
cvtsd2ss %xmm2, %xmm4
ucomisd %xmm3, %xmm5
jae 0x10fedd
movapd %xmm4, %xmm1
movss %xmm1, (%r14)
testq %rax, %rax
je 0x10ff32
movsd 0x8(%rsp), %xmm2
movsd 0x12138b(%rip), %xmm3   # 0x231280
unpcklps %xmm3, %xmm2            # xmm2 = xmm2[0],xmm3[0],xmm2[1],xmm3[1]
movapd 0x121390(%rip), %xmm4   # 0x231290
subpd %xmm4, %xmm2
movapd %xmm2, %xmm1
unpckhpd %xmm2, %xmm1            # xmm1 = xmm1[1],xmm2[1]
addsd %xmm2, %xmm1
punpckldq %xmm3, %xmm0    # xmm0 = xmm0[0],xmm3[0],xmm0[1],xmm3[1]
subpd %xmm4, %xmm0
movapd %xmm0, %xmm2
unpckhpd %xmm0, %xmm2            # xmm2 = xmm2[1],xmm0[1]
addsd %xmm0, %xmm2
divsd %xmm2, %xmm1
addsd 0x1213e0(%rip), %xmm1   # 0x231310
jmp 0x10ff3a
movsd 0x1213d6(%rip), %xmm1   # 0x231310
testq %rbx, %rbx
je 0x10ff5b
xorps %xmm0, %xmm0
cvtsi2sdq (%rbx), %xmm0
mulsd %xmm0, %xmm1
mulsd 0x12169d(%rip), %xmm1   # 0x2315f0
cvttsd2si %xmm1, %rax
movq %rax, (%rbx)
addq $0x18, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: get_specific_hap_overlap(kvec_hap_overlaps*, unsigned int, unsigned int)
int get_specific_hap_overlap(kvec_hap_overlaps* x, uint32_t qn, uint32_t tn)
{
    uint32_t i;
    for (i = 0; i < x->a.n; i++)
    {
        if(x->a.a[i].xUid == qn && x->a.a[i].yUid == tn)
        {
            return i;
        }        
    }

    return -1;
}

// Assembly:
movq (%rdi), %rcx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rcx, %rcx
je 0x11122a
movq 0x10(%rdi), %rdi
xorl %r9d, %r9d
xorl %r8d, %r8d
shlq $0x6, %r9
cmpl %esi, 0x24(%rdi,%r9)
jne 0x11121f
addq %rdi, %r9
cmpl %edx, 0x28(%r9)
je 0x11122b
incl %r8d
movq %r8, %r9
cmpq %r8, %rcx
ja 0x11120b
retq
movl %r8d, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: filter_hap_overlaps_by_length(hap_overlaps_list*, unsigned int)
void filter_hap_overlaps_by_length(hap_overlaps_list* all_ovlp, uint32_t minLen)
{
    if(minLen == 0) return;
    hap_overlaps *x = NULL;
    uint32_t v, i, m, uId;    

    for (v = 0; v < all_ovlp->num; v++)
    {
        uId = v;
        m = 0;
        for (i = 0; i < all_ovlp->x[uId].a.n; i++)
        {
            x = &(all_ovlp->x[uId].a.a[i]);
            if(x->x_end_id - x->x_beg_id < minLen) continue;
            all_ovlp->x[uId].a.a[m] = (*x);
            m++;
        }
        all_ovlp->x[uId].a.n = m;
    }
}

// Assembly:
testl %esi, %esi
je 0x111e73
movl 0x8(%rdi), %r8d
testl %r8d, %r8d
je 0x111e73
pushq %rbx
movq (%rdi), %rcx
xorl %eax, %eax
leaq (%rax,%rax,2), %rdx
cmpq $0x0, (%rcx,%rdx,8)
je 0x111e59
xorl %r10d, %r10d
movl $0x1, %r8d
xorl %r9d, %r9d
movq 0x10(%rcx,%rdx,8), %r11
shlq $0x6, %r10
movl 0x18(%r11,%r10), %ebx
subl 0x14(%r11,%r10), %ebx
cmpl %esi, %ebx
jb 0x111e40
addq %r11, %r10
movl %r9d, %ecx
shlq $0x6, %rcx
movups (%r10), %xmm0
movups 0x10(%r10), %xmm1
movups 0x20(%r10), %xmm2
movups 0x30(%r10), %xmm3
movups %xmm3, 0x30(%r11,%rcx)
movups %xmm2, 0x20(%r11,%rcx)
movups %xmm1, 0x10(%r11,%rcx)
movups %xmm0, (%r11,%rcx)
incl %r9d
movq (%rdi), %rcx
movl %r8d, %r10d
incl %r8d
cmpq %r10, (%rcx,%rdx,8)
ja 0x111def
leaq (%rcx,%rdx,8), %rdx
movl 0x8(%rdi), %r8d
movl %r9d, %r9d
jmp 0x111e60
leaq (%rcx,%rdx,8), %rdx
xorl %r9d, %r9d
movq %r9, (%rdx)
incq %rax
movl %r8d, %edx
cmpq %rdx, %rax
jb 0x111dd8
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: print_purge_gfa(ma_ug_t*, asg_t*)
void print_purge_gfa(ma_ug_t *ug, asg_t *purge_g)
{
    uint32_t v, i, n_vtx = purge_g->n_seq * 2;
    for (v = 0; v < n_vtx; v++)
    {
        if(v%2==0) fprintf(stderr, "\n");
        if(purge_g->seq[v>>1].del)
        {
            fprintf(stderr, "(D) v>>1: %u, v&1: %u, utg%.6d%c\n", v>>1, v&1, (v>>1)+1,
            "lc"[ug->u.a[v>>1].circ]);
            continue;
        } 

        fprintf(stderr, "(E) v>>1: %u, v&1: %u, utg%.6dl%c\n", v>>1, v&1, (v>>1)+1,
        "lc"[ug->u.a[v>>1].circ]);
        
        uint32_t nv = asg_arc_n(purge_g, v);
		asg_arc_t *av = asg_arc_a(purge_g, v);
        for (i = 0; i < nv; i++)
        {
            if(av[i].del) continue;
            fprintf(stderr, "av[i].ul: %u (utg%.6d%c, dir: %u, len: %u), av[i].v: %u (utg%.6d%c, dir: %u, len: %u), ol: %u\n", 
                (uint32_t)(av[i].ul>>33), (uint32_t)(av[i].ul>>33)+1, "lc"[ug->u.a[av[i].ul>>33].circ], (uint32_t)(av[i].ul>>32)&1, ug->u.a[av[i].ul>>33].len, 
                av[i].v>>1, (av[i].v>>1)+1, "lc"[ug->u.a[av[i].v>>1].circ], av[i].v&1, ug->u.a[av[i].v>>1].len, av[i].ol);
        }

    }
    
}

// Assembly:
movl 0x14(%rsi), %eax
addl %eax, %eax
je 0x112241
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
addq $0x10, %r14
movl %eax, %ebp
xorl %r12d, %r12d
testb $0x1, %r12b
jne 0x11218d
movq 0x182e60(%rip), %rax    # 0x294fe0
movq (%rax), %rsi
movl $0xa, %edi
callq 0x2270
movl %r12d, %ecx
andl $0x1, %ecx
movq 0x20(%rbx), %rax
movl %r12d, %edx
shrl %edx
leal 0x1(%rdx), %r8d
movq (%r14), %rsi
leaq (%rdx,%rdx,4), %rdi
movl (%rsi,%rdi,8), %esi
shrl $0x1f, %esi
cmpl $0x0, (%rax,%rdx,8)
movq 0x182e28(%rip), %rax    # 0x294fe0
movq (%rax), %rdi
leaq 0x122579(%rip), %rax    # 0x23473b
movsbl (%rsi,%rax), %r9d
js 0x112219
leaq 0x127760(%rip), %rsi    # 0x239930
xorl %eax, %eax
callq 0x22b0
movq 0x28(%rbx), %rax
movq (%rax,%r12,8), %rax
testl %eax, %eax
je 0x112227
movq %rax, %rcx
shrq $0x20, %rcx
leaq (%rcx,%rcx,2), %r13
shlq $0x3, %r13
addq 0x8(%rbx), %r13
movl %eax, %r15d
movl 0xc(%r13), %edx
testl %edx, %edx
jns 0x11220c
addq $0x18, %r13
decq %r15
jne 0x1121f9
jmp 0x112227
movq %r13, %rdi
movq %r14, %rsi
callq 0x1355b
jmp 0x112201
leaq 0x1276ee(%rip), %rsi    # 0x23990e
xorl %eax, %eax
callq 0x22b0
incq %r12
cmpq %rbp, %r12
jne 0x112173
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: asg_pop_bubble_purge_graph(asg_t*)
int asg_pop_bubble_purge_graph(asg_t *purge_g)
{
	uint32_t v, n_vtx = purge_g->n_seq * 2;
	uint64_t n_pop = 0;
	buf_t b;
	if (!purge_g->is_symm) asg_symm(purge_g);
	memset(&b, 0, sizeof(buf_t));
	///set information for each node
	b.a = (binfo_t*)calloc(n_vtx, sizeof(binfo_t));
	//traverse all node with two directions 
	for (v = 0; v < n_vtx; ++v) {
		uint32_t i, n_arc = 0, nv = asg_arc_n(purge_g, v);
		asg_arc_t *av = asg_arc_a(purge_g, v);
		///some node could be deleted
		if (nv < 2 || purge_g->seq[v>>1].del || purge_g->seq[v>>1].c == ALTER_LABLE) continue;
		///some edges could be deleted
		for (i = 0; i < nv; ++i) // asg_bub_pop1() may delete some edges/arcs
			if (!av[i].del) ++n_arc;
		if (n_arc > 1)
			n_pop += asg_bub_pop1_purge_graph(purge_g, v, purge_g->n_seq, &b);            
	}
	free(b.a); free(b.S.a); free(b.T.a); free(b.b.a); free(b.e.a);
	if (n_pop) asg_cleanup(purge_g);

	if(VERBOSE >= 1)
    {
        fprintf(stderr, "[M::%s] popped %lu bubbles\n", __func__, (unsigned long)n_pop);
    }
    return n_pop;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rdi, %rbx
movl 0x14(%rdi), %eax
leal (%rax,%rax), %ebp
testl %eax, %eax
js 0x1128d7
movq %rbx, %rdi
callq 0xa0c1e
xorps %xmm0, %xmm0
movups %xmm0, 0x58(%rsp)
movups %xmm0, 0x48(%rsp)
movups %xmm0, 0x38(%rsp)
movups %xmm0, 0x28(%rsp)
movups %xmm0, 0x18(%rsp)
movups %xmm0, 0x8(%rsp)
movl %ebp, %r15d
movl $0x1c, %esi
movq %r15, %rdi
callq 0x2120
movq %rax, (%rsp)
testl %ebp, %ebp
je 0x11299d
xorl %r12d, %r12d
movl $0x7fffffff, %ebp       # imm = 0x7FFFFFFF
movq %rsp, %r13
xorl %r14d, %r14d
movq 0x28(%rbx), %rax
movq (%rax,%r12,8), %rax
testl $0xfffffffe, %eax       # imm = 0xFFFFFFFE
je 0x11298f
movq 0x20(%rbx), %rcx
movl %r12d, %edx
shrl %edx
cmpl $0x0, (%rcx,%rdx,8)
js 0x11298f
cmpb $0x1, 0x4(%rcx,%rdx,8)
je 0x11298f
movq 0x8(%rbx), %rcx
movq %rax, %rdx
shrq $0x20, %rdx
movl %eax, %eax
leaq (%rdx,%rdx,2), %rdx
leaq (%rcx,%rdx,8), %rdx
addq $0xc, %rdx
xorl %ecx, %ecx
movl (%rdx), %esi
notl %esi
shrl $0x1f, %esi
addl %esi, %ecx
addq $0x18, %rdx
decq %rax
jne 0x112962
cmpl $0x2, %ecx
jb 0x11298f
movl 0x14(%rbx), %edx
andl %ebp, %edx
movq %rbx, %rdi
movl %r12d, %esi
movq %r13, %rcx
callq 0x112289
addq %rax, %r14
incq %r12
cmpq %r15, %r12
jne 0x112922
movq (%rsp), %rax
jmp 0x1129a0
xorl %r14d, %r14d
movq %rax, %rdi
callq 0x2220
movq 0x18(%rsp), %rdi
callq 0x2220
movq 0x30(%rsp), %rdi
callq 0x2220
movq 0x48(%rsp), %rdi
callq 0x2220
movq 0x60(%rsp), %rdi
callq 0x2220
testq %r14, %r14
je 0x1129dd
movq %rbx, %rdi
callq 0xa0a7d
movl %r14d, %eax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq