LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/lchain.c
// Function: mg_chain_bk_end
static int64_t mg_chain_bk_end(int32_t max_drop, const mg128_t *z, const int32_t *f, const int64_t *p, int32_t *t, int64_t k)
{
	int64_t i = z[k].y, end_i = -1, max_i = i;
	int32_t max_s = 0;
	if (i < 0 || t[i] != 0) return i;
	do {
		int32_t s;
		t[i] = 2;
		end_i = i = p[i];
		s = i < 0? z[k].x : (int32_t)z[k].x - f[i];
		if (s > max_s) max_s = s, max_i = i;
		else if (max_s - s > max_drop) break;
	} while (i >= 0 && t[i] == 0);
	for (i = z[k].y; i >= 0 && i != end_i; i = p[i]) // reset modified t[]
		t[i] = 0;
	return max_i;
}

// Assembly:
shlq $0x4, %r9
movq 0x8(%rsi,%r9), %rax
testq %rax, %rax
js 0x134c5
cmpl $0x0, (%r8,%rax,4)
je 0x134c6
retq
pushq %rbp
pushq %r14
pushq %rbx
addq %r9, %rsi
movl (%rsi), %r10d
xorl %r11d, %r11d
movq %rax, %r9
movq %rax, %rsi
movl $0x2, (%r8,%r9,4)
movq (%rcx,%r9,8), %r9
movl %r10d, %ebx
testq %r9, %r9
js 0x134f4
movl %r10d, %ebx
subl (%rdx,%r9,4), %ebx
movl %r11d, %r14d
subl %ebx, %r14d
cmovlq %r9, %rsi
setl %bpl
cmpl %edi, %r14d
setle %r14b
testq %r9, %r9
js 0x13531
orb %r14b, %bpl
je 0x13531
cmpl %r11d, %ebx
cmovgl %ebx, %r11d
cmpl $0x0, (%r8,%r9,4)
je 0x134d9
jmp 0x13531
cmpq %r9, %rax
je 0x13536
andl $0x0, (%r8,%rax,4)
movq (%rcx,%rax,8), %rax
testq %rax, %rax
jns 0x13523
movq %rsi, %rax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/lchain.c
// Function: comput_sc_simple
static inline int32_t comput_sc_simple(const mg128_t *ai, const mg128_t *aj, float chn_pen_gap, float chn_pen_skip, int32_t *exact, int32_t *width)
{
	int32_t dq = (int32_t)ai->y - (int32_t)aj->y, dr, dd, dg, q_span, sc;
	dr = (int32_t)(ai->x - aj->x);
	*width = dd = dr > dq? dr - dq : dq - dr;
	dg = dr < dq? dr : dq;
	q_span = aj->y>>32&0xff;
	sc = q_span < dg? q_span : dg;
	if (exact) *exact = (dd == 0 && dg <= q_span);
	if (dd || dq > q_span) {
		float lin_pen, log_pen;
		lin_pen = chn_pen_gap * (float)dd + chn_pen_skip * (float)dg;
		log_pen = dd >= 1? mg_log2(dd + 1) : 0.0f; // mg_log2() only works for dd>=2
		sc -= (int)(lin_pen + .5f * log_pen);
	}
	return sc;
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movaps %xmm0, %xmm3
movl (%rdi), %eax
movl 0x8(%rdi), %edi
movq 0x8(%rsi), %r9
subl %r9d, %edi
subl (%rsi), %eax
movl %edi, %r10d
subl %eax, %r10d
movl %eax, %r8d
cmovll %edi, %r8d
movl %r10d, %esi
negl %esi
cmovsl %r10d, %esi
movl %esi, (%rcx)
shrq $0x20, %r9
movzbl %r9b, %ecx
cmpl %r8d, %ecx
movl %r8d, %ebx
cmovll %ecx, %ebx
testq %rdx, %rdx
je 0x153b2
cmpl %eax, %edi
sete %r9b
cmpl %ecx, %r8d
setle %r10b
andb %r9b, %r10b
movzbl %r10b, %r9d
movl %r9d, (%rdx)
cmpl %eax, %edi
setne %dl
cmpl %ecx, %edi
setg %cl
orb %dl, %cl
cmpb $0x1, %cl
jne 0x15408
cvtsi2ss %esi, %xmm0
cvtsi2ss %r8d, %xmm2
mulss %xmm1, %xmm2
mulss %xmm0, %xmm3
addss %xmm2, %xmm3
xorps %xmm0, %xmm0
cmpl %eax, %edi
je 0x153f6
incl %esi
cvtsi2ss %esi, %xmm0
movss %xmm3, 0xc(%rsp)
callq 0x15687
movss 0xc(%rsp), %xmm3
mulss 0xee36(%rip), %xmm0     # 0x24234
addss %xmm3, %xmm0
cvttss2si %xmm0, %eax
subl %eax, %ebx
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/lchain.c
// Function: mg_lchain_gen
mg_lchain_t *mg_lchain_gen(void *km, uint32_t hash, int qlen, int n_u, uint64_t *u, mg128_t *a)
{
	mg128_t *z;
	mg_lchain_t *r;
	int i, k;

	if (n_u == 0) return 0;
	KCALLOC(km, r, n_u);

	// sort by query position
	KMALLOC(km, z, n_u);
	for (i = k = 0; i < n_u; ++i) {
		int32_t qs = (int32_t)a[k].y + 1 - (a[k].y>>32 & 0xff);
		z[i].x = (uint64_t)qs << 32 | u[i] >> 32;
		z[i].y = (uint64_t)k << 32 | (int32_t)u[i];
		k += (int32_t)u[i];
	}
	radix_sort_128x(z, z + n_u);

	// populate r[]
	for (i = 0; i < n_u; ++i) {
		mg_lchain_t *ri = &r[i];
		int32_t k = z[i].y >> 32, q_span = a[k].y >> 32 & 0xff;
		ri->off = k;
		ri->cnt = (int32_t)z[i].y;
		ri->score = (uint32_t)z[i].x;
		ri->v = a[k].x >> 32;
		ri->rs = (int32_t)a[k].x + 1 > q_span? (int32_t)a[k].x + 1 - q_span : 0; // for HPC k-mer
		ri->qs = z[i].x >> 32;
		ri->re = (int32_t)a[k + ri->cnt - 1].x + 1;
		ri->qe = (int32_t)a[k + ri->cnt - 1].y + 1;
	}
	kfree(km, z);
	return r;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
xorl %r14d, %r14d
testl %ecx, %ecx
je 0x155a6
movq %r9, %rbx
movq %r8, %rbp
movq %rdi, %r12
movq %rcx, (%rsp)
movslq (%rsp), %r13
pushq $0x28
popq %rdx
movq %r13, %rsi
callq 0x24f0
movq %rax, %r15
shlq $0x4, %r13
movq %r12, 0x10(%rsp)
movq %r12, %rdi
movq %r13, 0x8(%rsp)
movq %r13, %rsi
movq (%rsp), %r13
callq 0x266c
movq %rax, %r12
testl %r13d, %r13d
cmovlel %r14d, %r13d
leaq (,%r13,8), %rax
xorl %ecx, %ecx
cmpq %rcx, %rax
je 0x154c9
movslq %r14d, %r14
movq %r14, %rdx
shlq $0x4, %rdx
movq 0x8(%rbx,%rdx), %rdx
movq %rdx, %rsi
shrq $0x20, %rsi
movzbl %sil, %esi
subl %esi, %edx
incl %edx
movq (%rbp,%rcx), %rsi
shrdq $0x20, %rdx, %rsi
movq %rsi, (%r12,%rcx,2)
movq %r14, %rdx
shlq $0x20, %rdx
movslq (%rbp,%rcx), %rsi
orq %rdx, %rsi
movq %rsi, 0x8(%r12,%rcx,2)
addl (%rbp,%rcx), %r14d
addq $0x8, %rcx
jmp 0x15479
movq 0x8(%rsp), %rsi
addq %r12, %rsi
movq %r12, %rdi
callq 0xcb7f
imulq $0x28, %r13, %rax
movq %r12, %rcx
addq $0x8, %rcx
xorl %edx, %edx
movl $0x80000000, %esi       # imm = 0x80000000
xorl %edi, %edi
cmpq %rdi, %rax
je 0x15597
movq (%rcx), %r8
movq %r8, %r9
shrq $0x20, %r9
movq %r8, %r10
sarq $0x20, %r10
shlq $0x4, %r10
movzbl 0xc(%rbx,%r10), %r11d
movl %r9d, (%r15,%rdi)
movl %r8d, %ebp
andl $0x7fffffff, %ebp       # imm = 0x7FFFFFFF
movl 0x4(%r15,%rdi), %r14d
andl %esi, %r14d
orl %ebp, %r14d
movl %r14d, 0x4(%r15,%rdi)
movq -0x8(%rcx), %r14
movl %r14d, 0x1c(%r15,%rdi)
movq (%rbx,%r10), %r10
movq %r10, %r13
shrq $0x20, %r13
movl %r13d, 0x8(%r15,%rdi)
subl %r11d, %r10d
leal 0x1(%r10), %r10d
cmovll %edx, %r10d
movl %r10d, 0xc(%r15,%rdi)
shrq $0x20, %r14
movl %r14d, 0x14(%r15,%rdi)
addl %r8d, %r8d
sarl %r8d
addl %r9d, %r8d
movslq %r8d, %r8
shlq $0x4, %r8
movl -0x10(%rbx,%r8), %r9d
incl %r9d
movl %r9d, 0x10(%r15,%rdi)
movl -0x8(%rbx,%r8), %r8d
incl %r8d
movl %r8d, 0x18(%r15,%rdi)
addq $0x28, %rdi
addq $0x10, %rcx
jmp 0x154ed
movq 0x10(%rsp), %rdi
movq %r12, %rsi
callq 0x2577
jmp 0x155a9
xorl %r15d, %r15d
movq %r15, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/lchain.c
// Function: mg_update_anchors
void mg_update_anchors(int32_t n_a, mg128_t *a, int32_t n, const int32_t *mini_pos)
{
	int32_t st, j, k;
	if (n_a <= 0) return;
	st = get_mini_idx(&a[0], n, mini_pos);
	assert(st >= 0);
	for (k = 0, j = st; j < n && k < n_a; ++j)
		if ((int32_t)a[k].y == mini_pos[j])
			a[k].x = (uint64_t)j << 32 | (a[k].x & 0xffffffffU), ++k;
	assert(k == n_a);
}

// Assembly:
pushq %rbx
testl %edi, %edi
jle 0x15647
movl 0x8(%rsi), %r8d
xorl %r9d, %r9d
movl %edx, %r10d
leal -0x1(%r10), %eax
movslq %eax, %r11
cmpl %r10d, %r9d
jge 0x15649
movslq %r9d, %rax
addq %r11, %rax
shrq %rax
cmpl %r8d, (%rcx,%rax,4)
jge 0x155ef
leal 0x1(%rax), %r9d
jmp 0x155d5
movl %eax, %r10d
jg 0x155ce
testl %eax, %eax
js 0x15649
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movq %rax, %r8
shlq $0x20, %r8
xorl %r9d, %r9d
movabsq $0x100000000, %r10      # imm = 0x100000000
cmpl %edx, %eax
jge 0x15642
cmpl %edi, %r9d
jge 0x15642
movslq %r9d, %r11
shlq $0x4, %r11
movl (%rcx,%rax,4), %ebx
cmpl 0x8(%rsi,%r11), %ebx
jne 0x1563a
addq %rsi, %r11
movl (%r11), %ebx
addq %r8, %rbx
movq %rbx, (%r11)
incl %r9d
incq %rax
addq %r10, %r8
jmp 0x15611
cmpl %edi, %r9d
jne 0x15668
popq %rbx
retq
leaq 0xedf3(%rip), %rdi      # 0x24443
leaq 0xec19(%rip), %rsi      # 0x24270
leaq 0xeded(%rip), %rcx      # 0x2444b
movl $0x1b4, %edx            # imm = 0x1B4
callq 0x2160
leaq 0xee21(%rip), %rdi      # 0x24490
leaq 0xebfa(%rip), %rsi      # 0x24270
leaq 0xedce(%rip), %rcx      # 0x2444b
movl $0x1b8, %edx            # imm = 0x1B8
callq 0x2160
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/./mgpriv.h
// Function: mg_log2
static inline float mg_log2(float x) // NB: this doesn't work when x<2
{
	union { float f; uint32_t i; } z = { x };
	float log_2 = ((z.i >> 23) & 255) - 128;
	z.i &= ~(255 << 23);
	z.i += 127 << 23;
	log_2 += (-0.34484843f * z.f + 2.02466578f) * z.f - 0.67487759f;
	return log_2;
}

// Assembly:
movd %xmm0, %eax
movl %eax, %ecx
shrl $0x17, %ecx
movzbl %cl, %ecx
addl $-0x80, %ecx
cvtsi2ss %rcx, %xmm1
andl $0x807fffff, %eax       # imm = 0x807FFFFF
orl $0x3f800000, %eax       # imm = 0x3F800000
movd %eax, %xmm2
movss 0xeb87(%rip), %xmm0     # 0x24238
mulss %xmm2, %xmm0
addss 0xeb7f(%rip), %xmm0     # 0x2423c
mulss %xmm2, %xmm0
addss 0xeb77(%rip), %xmm0     # 0x24240
addss %xmm1, %xmm0
retq
nop
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/gchain1.c
// Function: rs_sort_gc
static int32_t find_max(int32_t n, const gc_frag_t *gf, int32_t x)
{
	int32_t s = 0, e = n;
	if (n == 0) return -1;
	if (gf[n-1].srt < x) return n - 1;
	if (gf[0].srt >= x) return -1;
	while (e > s) { // TODO: finish this block
		int32_t m = s + (e - s) / 2;
		if (gf[m].srt >= x) e = m;
		else s = m + 1;
	}
	assert(s == e);
	return s;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1008, %rsp           # imm = 0x1008
movl %ecx, %ebx
movl %edx, %ebp
pushq $0x1
popq %rax
movl %ebp, %ecx
shll %cl, %eax
cmpl $0x8, %edx
jg 0x158c0
movslq %eax, %r14
decl %eax
movq %r14, %rcx
shlq $0x4, %rcx
leaq (%rsp,%rcx), %rdx
movq %rsp, %r8
testq %rcx, %rcx
je 0x1575c
movq %rdi, 0x8(%r8)
movq %rdi, (%r8)
addq $0x10, %r8
addq $-0x10, %rcx
jmp 0x15746
movq %rdi, %r8
cmpq %rsi, %r8
je 0x1577f
movl (%r8), %r9d
movl %ebx, %ecx
shrl %cl, %r9d
andl %eax, %r9d
shlq $0x4, %r9
addq $0x8, 0x8(%rsp,%r9)
addq $0x8, %r8
jmp 0x1575f
leaq 0x10(%rsp), %rsi
shlq $0x4, %r14
leaq -0x10(%r14), %rcx
movq %rsi, %r8
testq %rcx, %rcx
je 0x157af
movq -0x8(%r8), %r9
movq %r9, %r10
subq %rdi, %r10
addq %r10, 0x8(%r8)
movq %r9, (%r8)
addq $0x10, %r8
addq $-0x10, %rcx
jmp 0x1578f
movq %rsp, %r8
cmpq %rdx, %r8
je 0x15846
movq (%r8), %r10
cmpq 0x8(%r8), %r10
je 0x1583d
movl (%r10), %r9d
movl %r9d, %r11d
movl %ebx, %ecx
shrl %cl, %r11d
andl %eax, %r11d
shlq $0x4, %r11
leaq (%rsp,%r11), %rcx
cmpq %r8, %rcx
je 0x15831
movl 0x4(%r10), %r10d
movl %r9d, %r11d
movl %r10d, %r15d
movq (%rcx), %r12
movl (%r12), %r9d
movl 0x4(%r12), %r10d
leaq 0x8(%r12), %r13
movq %r13, (%rcx)
movl %r11d, (%r12)
movl %r15d, 0x4(%r12)
movl %r9d, %r11d
movl %ebx, %ecx
shrl %cl, %r11d
andl %eax, %r11d
shlq $0x4, %r11
leaq (%rsp,%r11), %rcx
cmpq %r8, %rcx
jne 0x157e3
movq (%r8), %rcx
leaq 0x8(%rcx), %r11
movq %r11, (%r8)
movl %r9d, (%rcx)
movl %r10d, 0x4(%rcx)
jmp 0x157b2
addq $0x8, %r10
movq %r10, (%r8)
jmp 0x157b2
addq $0x10, %r8
jmp 0x157b2
movq %rdi, (%rsp)
leaq -0x10(%r14), %rax
testq %rax, %rax
je 0x15864
movq -0x8(%rsi), %rcx
movq %rcx, (%rsi)
addq $0x10, %rsi
addq $-0x10, %rax
jmp 0x1584e
testl %ebx, %ebx
je 0x158ae
xorl %eax, %eax
subl %ebp, %ebx
cmovlel %eax, %ebx
movq %rsp, %r15
testq %r14, %r14
je 0x158ae
movq (%r15), %rdi
movq 0x8(%r15), %rsi
movq %rsi, %rax
subq %rdi, %rax
sarq $0x3, %rax
cmpq $0x41, %rax
jl 0x15899
movl %ebp, %edx
movl %ebx, %ecx
callq 0x1570e
jmp 0x158a4
cmpq $0x2, %rax
jl 0x158a4
callq 0x156d0
addq $0x10, %r15
addq $-0x10, %r14
jmp 0x15872
addq $0x1008, %rsp           # imm = 0x1008
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xd855(%rip), %rdi      # 0x2311c
leaq 0xec02(%rip), %rsi      # 0x244d0
leaq 0xec05(%rip), %rcx      # 0x244da
pushq $0xe
popq %rdx
callq 0x2160
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/gchain1.c
// Function: cal_sc
static inline int32_t cal_sc(const mg_path_dst_t *dj, const mg_lchain_t *li, const mg_lchain_t *lc, const mg128_t *an, const gc_frag_t *a, const int32_t *f,
							 int bw, int ref_bonus, float chn_pen_gap)
{
	const mg_lchain_t *lj;
	int32_t gap, sc, segi, segj;
	float lin_pen, log_pen;
	if (dj->n_path == 0) return INT32_MIN;
	segi = (an[li->off].y & MG_SEED_SEG_MASK) >> MG_SEED_SEG_SHIFT;
	gap = dj->dist - dj->target_dist;
	lj = &lc[a[dj->meta].i];
	segj = (an[lj->off + lj->cnt - 1].y & MG_SEED_SEG_MASK) >> MG_SEED_SEG_SHIFT;
	if (gap < 0) gap = -gap;
	if (segi == segj && gap > bw) return INT32_MIN;
	if (lj->qe <= li->qs) sc = li->score;
	else sc = (int32_t)((double)(li->qe - lj->qe) / (li->qe - li->qs) * li->score + .499); // dealing with overlap on query
	//sc += dj->mlen; // TODO: is this line the right thing to do?
	if (dj->is_0) sc += ref_bonus;
	lin_pen = chn_pen_gap * (float)gap;
	log_pen = gap >= 2? mg_log2(gap) : 0.0f;
	sc -= (int32_t)(lin_pen + log_pen);
	sc += f[dj->meta];
	return sc;
}

// Assembly:
movl 0x14(%rdi), %r10d
movl $0x80000000, %eax       # imm = 0x80000000
testl $0x7fffffff, %r10d      # imm = 0x7FFFFFFF
je 0x16682
pushq %rbp
pushq %r14
pushq %rbx
movslq (%rsi), %rbx
shlq $0x4, %rbx
movl 0xc(%rdi), %r11d
movl 0x1c(%rdi), %ebp
subl 0x4(%rdi), %ebp
andl $0x3fffffff, %r11d      # imm = 0x3FFFFFFF
movslq 0x4(%r8,%r11,8), %rdi
imulq $0x28, %rdi, %r8
movslq (%rdx,%r8), %rdi
movl 0x4(%rdx,%r8), %r14d
shlq $0x21, %r14
sarq $0x21, %r14
addq %rdi, %r14
shlq $0x4, %r14
movq -0x8(%rcx,%r14), %r14
movl %ebp, %edi
negl %edi
cmovsl %ebp, %edi
xorq 0x8(%rcx,%rbx), %r14
shrq $0x30, %r14
testb %r14b, %r14b
sete %cl
cmpl 0x20(%rsp), %edi
setg %bl
testb %bl, %cl
jne 0x1667e
movl 0x28(%rsp), %eax
addq %r8, %rdx
movl 0x18(%rdx), %edx
movl 0x14(%rsi), %ecx
cmpl %ecx, %edx
jle 0x1660b
movl 0x18(%rsi), %r8d
movl %r8d, %ebx
subl %edx, %ebx
cvtsi2sd %ebx, %xmm1
subl %ecx, %r8d
cvtsi2sd %r8d, %xmm2
divsd %xmm2, %xmm1
cvtsi2sdl 0x1c(%rsi), %xmm2
mulsd %xmm1, %xmm2
addsd 0xdec3(%rip), %xmm2     # 0x244c8
cvttsd2si %xmm2, %ecx
jmp 0x1660e
movl 0x1c(%rsi), %ecx
sarl $0x1f, %r10d
andl %eax, %r10d
cvtsi2ss %edi, %xmm2
addl %ecx, %r10d
mulss %xmm2, %xmm0
xorpd %xmm1, %xmm1
cmpl $0x2, %edi
jb 0x1666c
movd %xmm2, %eax
movl %eax, %ecx
shrl $0x17, %ecx
addl $-0x80, %ecx
cvtsi2ss %rcx, %xmm2
andl $0x7fffff, %eax         # imm = 0x7FFFFF
orl $0x3f800000, %eax       # imm = 0x3F800000
movd %eax, %xmm3
movss 0xdbe8(%rip), %xmm1     # 0x24238
mulss %xmm3, %xmm1
addss 0xdbe0(%rip), %xmm1     # 0x2423c
mulss %xmm3, %xmm1
addss 0xdbd8(%rip), %xmm1     # 0x24240
addss %xmm2, %xmm1
addss %xmm1, %xmm0
cvttss2si %xmm0, %eax
addl (%r9,%r11,4), %r10d
subl %eax, %r10d
movl %r10d, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/gchain1.c
// Function: copy_lchain
static inline void copy_lchain(mg_llchain_t *q, const mg_lchain_t *p, int32_t *n_a, mg128_t *a_new, const mg128_t *a_old, int32_t ed)
{
	q->cnt = p->cnt, q->v = p->v, q->score = p->score, q->ed = ed;
	memcpy(&a_new[*n_a], &a_old[p->off], q->cnt * sizeof(mg128_t));
	q->off = *n_a;
	(*n_a) += q->cnt;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rdi, %r14
movl 0x4(%rsi), %edx
leal (%rdx,%rdx), %eax
sarl %eax
movl %eax, 0x4(%rdi)
movl 0x8(%rsi), %eax
movl %eax, 0x8(%rdi)
movl 0x1c(%rsi), %eax
movl %eax, 0xc(%rdi)
movl %r9d, 0x10(%rdi)
movslq (%rbx), %rdi
shlq $0x4, %rdi
addq %rcx, %rdi
movslq (%rsi), %rsi
shlq $0x4, %rsi
addq %r8, %rsi
shlq $0x21, %rdx
sarq $0x21, %rdx
shlq $0x4, %rdx
callq 0x2230
movl (%rbx), %eax
movl %eax, (%r14)
addl 0x4(%r14), %eax
movl %eax, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/gchain1.c
// Function: mg_gchain_free
void mg_gchain_free(mg_gchains_t *gs)
{
	void *km;
	int32_t i;
	if (gs == 0) return;
	km = gs->km;
	for (i = 0; i < gs->n_gc; ++i) {
		if (gs->gc[i].p) kfree(km, gs->gc[i].p);
		if (gs->gc[i].ds.ds) kfree(km, gs->gc[i].ds.ds);
		if (gs->gc[i].ds.off) kfree(km, gs->gc[i].ds.off);
	}
	kfree(km, gs->gc); kfree(km, gs->a); kfree(km, gs->lc);
	kfree(km, gs);
}

// Assembly:
testq %rdi, %rdi
je 0x17730
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %r14
xorl %r15d, %r15d
xorl %r12d, %r12d
movslq 0x8(%rbx), %rax
movq 0x18(%rbx), %rsi
cmpq %rax, %r12
jge 0x176fa
movq 0x48(%rsi,%r15), %rax
testq %rax, %rax
je 0x176c6
movq %r14, %rdi
movq %rax, %rsi
callq 0x2577
movq 0x18(%rbx), %rsi
movq 0x60(%rsi,%r15), %rax
testq %rax, %rax
je 0x176df
movq %r14, %rdi
movq %rax, %rsi
callq 0x2577
movq 0x18(%rbx), %rsi
movq 0x58(%rsi,%r15), %rsi
testq %rsi, %rsi
je 0x176f1
movq %r14, %rdi
callq 0x2577
incq %r12
addq $0x68, %r15
jmp 0x176a0
movq %r14, %rdi
callq 0x2577
movq 0x28(%rbx), %rsi
movq %r14, %rdi
callq 0x2577
movq 0x20(%rbx), %rsi
movq %r14, %rdi
callq 0x2577
movq %r14, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x2577
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/galign.c
// Function: append_cigar1
static void append_cigar1(void *km, mg64_v *c, int32_t op, int32_t len)
{
	if (c->n > 0 && (c->a[c->n - 1]&0xf) == op) {
		c->a[c->n - 1] += (uint64_t)len<<4;
	} else {
		if (c->n == c->m) {
			c->m += (c->m>>1) + 16;
			KREALLOC(km, c->a, c->m);
		}
		c->a[c->n++] = (uint64_t)len<<4 | op;
	}
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %ecx, %r14d
movl %edx, %ebp
movq %rsi, %rbx
movslq (%rsi), %rcx
testq %rcx, %rcx
jle 0x180cf
movq 0x8(%rbx), %rax
movq -0x8(%rax,%rcx,8), %rdx
movl %edx, %esi
andl $0xf, %esi
cmpl %ebp, %esi
jne 0x180cf
movslq %r14d, %rsi
shlq $0x4, %rsi
addq %rsi, %rdx
movq %rdx, -0x8(%rax,%rcx,8)
jmp 0x18114
cmpl 0x4(%rbx), %ecx
jne 0x180f8
movl %ecx, %eax
sarl %eax
addl %ecx, %eax
addl $0x10, %eax
movl %eax, 0x4(%rbx)
movq 0x8(%rbx), %rsi
movslq %eax, %rdx
shlq $0x3, %rdx
callq 0x2774
movq %rax, 0x8(%rbx)
movl (%rbx), %ecx
jmp 0x180fc
movq 0x8(%rbx), %rax
movslq %r14d, %rdx
shlq $0x4, %rdx
movl %ebp, %esi
orq %rdx, %rsi
leal 0x1(%rcx), %edx
movl %edx, (%rbx)
movslq %ecx, %rcx
movq %rsi, (%rax,%rcx,8)
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/gcmisc.c
// Function: mg_gchain_restore_order
void mg_gchain_restore_order(void *km, mg_gchains_t *gcs)
{
	int32_t i, n_a, n_lc;
	mg_llchain_t *lc;
	mg128_t *a;
	KMALLOC(km, lc, gcs->n_lc);
	KMALLOC(km, a, gcs->n_a);
	for (i = 0, n_a = n_lc = 0; i < gcs->n_gc; ++i) {
		mg_gchain_t *gc = &gcs->gc[i];
		assert(gc->cnt > 0);
		memcpy(&lc[n_lc], &gcs->lc[gc->off], gc->cnt * sizeof(mg_llchain_t));
		memcpy(&a[n_a], &gcs->a[gcs->lc[gc->off].off], gc->n_anchor * sizeof(mg128_t));
		n_lc += gc->cnt, n_a += gc->n_anchor;
	}
	memcpy(gcs->lc, lc, gcs->n_lc * sizeof(mg_llchain_t));
	memcpy(gcs->a, a, gcs->n_a * sizeof(mg128_t));
	kfree(km, lc); kfree(km, a);
	for (i = 0, n_lc = 0; i < gcs->n_gc; ++i) {
		mg_gchain_t *gc = &gcs->gc[i];
		gc->off = n_lc;
		n_lc += gc->cnt;
	}
	for (i = 0, n_a = 0; i < gcs->n_lc; ++i) {
		mg_llchain_t *lc = &gcs->lc[i];
		lc->off = n_a;
		n_a += lc->cnt;
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movslq 0xc(%rsi), %rax
imulq $0x14, %rax, %rsi
callq 0x266c
movq %rax, 0x8(%rsp)
movslq 0x10(%rbx), %rsi
shlq $0x4, %rsi
movq %r14, 0x10(%rsp)
movq %r14, %rdi
callq 0x266c
movq %rax, (%rsp)
xorl %r13d, %r13d
pushq $0x10
popq %rbp
xorl %r14d, %r14d
xorl %r15d, %r15d
movslq 0x8(%rbx), %rax
cmpq %rax, %r13
jge 0x18b0d
movq 0x18(%rbx), %r12
movslq -0x4(%r12,%rbp), %rax
testq %rax, %rax
jle 0x18bb2
movslq %r14d, %r14
imulq $0x14, %r14, %rdi
addq 0x8(%rsp), %rdi
movslq -0x8(%r12,%rbp), %rcx
imulq $0x14, %rcx, %rsi
addq 0x20(%rbx), %rsi
imulq $0x14, %rax, %rdx
callq 0x2230
movslq %r15d, %r15
movq %r15, %rdi
shlq $0x4, %rdi
addq (%rsp), %rdi
movq 0x20(%rbx), %rax
movslq -0x8(%r12,%rbp), %rcx
imulq $0x14, %rcx, %rcx
movslq (%rax,%rcx), %rsi
shlq $0x4, %rsi
addq 0x28(%rbx), %rsi
movslq (%r12,%rbp), %rdx
shlq $0x4, %rdx
callq 0x2230
addl -0x4(%r12,%rbp), %r14d
addl (%r12,%rbp), %r15d
incq %r13
addq $0x68, %rbp
jmp 0x18a87
movq 0x20(%rbx), %rdi
movslq 0xc(%rbx), %rax
imulq $0x14, %rax, %rdx
movq 0x8(%rsp), %r15
movq %r15, %rsi
callq 0x2230
movq 0x28(%rbx), %rdi
movslq 0x10(%rbx), %rdx
shlq $0x4, %rdx
movq (%rsp), %r12
movq %r12, %rsi
callq 0x2230
movq 0x10(%rsp), %r14
movq %r14, %rdi
movq %r15, %rsi
callq 0x2577
movq %r14, %rdi
movq %r12, %rsi
callq 0x2577
movslq 0x8(%rbx), %rax
xorl %ecx, %ecx
pushq $0xc
popq %rdx
xorl %esi, %esi
cmpq %rax, %rcx
jge 0x18b7d
movq 0x18(%rbx), %rdi
movl %esi, -0x4(%rdi,%rdx)
addl (%rdi,%rdx), %esi
incq %rcx
addq $0x68, %rdx
jmp 0x18b64
movl 0xc(%rbx), %ecx
xorl %eax, %eax
testl %ecx, %ecx
cmovlel %eax, %ecx
imulq $0x14, %rcx, %rcx
xorl %edx, %edx
cmpq %rax, %rcx
je 0x18ba3
movq 0x20(%rbx), %rsi
movl %edx, (%rsi,%rax)
addl 0x4(%rsi,%rax), %edx
addq $0x14, %rax
jmp 0x18b8d
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xbf83(%rip), %rdi      # 0x24b3c
leaq 0xbf88(%rip), %rsi      # 0x24b48
leaq 0xbf8a(%rip), %rcx      # 0x24b51
pushq $0x11
popq %rdx
callq 0x2160
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/gcmisc.c
// Function: mg_gchain_restore_offset
void mg_gchain_restore_offset(mg_gchains_t *gcs)
{
	int32_t i, j, n_a, n_lc;
	for (i = 0, n_a = n_lc = 0; i < gcs->n_gc; ++i) {
		mg_gchain_t *gc = &gcs->gc[i];
		gc->off = n_lc;
		for (j = 0, gc->n_anchor = 0; j < gc->cnt; ++j) {
			mg_llchain_t *lc = &gcs->lc[n_lc + j];
			lc->off = n_a;
			n_a += lc->cnt;
			gc->n_anchor += lc->cnt;
		}
		n_lc += gc->cnt;
	}
	assert(n_lc == gcs->n_lc && n_a == gcs->n_a);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl 0x8(%rdi), %eax
xorl %ecx, %ecx
testl %eax, %eax
cmovlel %ecx, %eax
xorl %edx, %edx
xorl %esi, %esi
cmpq %rax, %rcx
je 0x18c43
movq 0x18(%rdi), %r9
imulq $0x68, %rcx, %r10
leaq (%r9,%r10), %r8
movl %esi, 0x8(%r9,%r10)
andl $0x0, 0x10(%r9,%r10)
movl 0xc(%r9,%r10), %r9d
movslq %esi, %rbx
xorl %r10d, %r10d
testl %r9d, %r9d
movl $0x0, %r11d
cmovgl %r9d, %r11d
imulq $0x14, %rbx, %rbx
subq $0x1, %r11
jb 0x18c3b
movq 0x20(%rdi), %r14
movl %edx, (%r14,%rbx)
movl 0x4(%r14,%rbx), %ebp
addl %ebp, %edx
addl %ebp, %r10d
movl %r10d, 0x10(%r8)
addq $0x14, %rbx
jmp 0x18c19
addl %r9d, %esi
incq %rcx
jmp 0x18be1
cmpl 0xc(%rdi), %esi
jne 0x18c52
cmpl 0x10(%rdi), %edx
jne 0x18c52
popq %rbx
popq %r14
popq %rbp
retq
leaq 0xbf2d(%rip), %rdi      # 0x24b86
leaq 0xbee8(%rip), %rsi      # 0x24b48
leaq 0xbf44(%rip), %rcx      # 0x24bab
pushq $0x34
popq %rdx
callq 0x2160
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/gcmisc.c
// Function: mg_gchain_sort_by_score
void mg_gchain_sort_by_score(void *km, mg_gchains_t *gcs)
{
	mg128_t *z;
	mg_gchain_t *gc;
	int32_t i;
	KMALLOC(km, z, gcs->n_gc);
	KMALLOC(km, gc, gcs->n_gc);
	for (i = 0; i < gcs->n_gc; ++i)
		z[i].x = (uint64_t)gcs->gc[i].score << 32 | gcs->gc[i].hash, z[i].y = i;
	radix_sort_128x(z, z + gcs->n_gc);
	for (i = gcs->n_gc - 1; i >= 0; --i)
		gc[gcs->n_gc - 1 - i] = gcs->gc[z[i].y];
	memcpy(gcs->gc, gc, gcs->n_gc * sizeof(mg_gchain_t));
	kfree(km, z); kfree(km, gc);
	mg_gchain_restore_order(km, gcs); // this put gcs in the proper order
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movslq 0x8(%rsi), %rsi
shlq $0x4, %rsi
callq 0x266c
movq %rax, %r15
movslq 0x8(%rbx), %rax
imulq $0x68, %rax, %rsi
movq %r14, %rdi
callq 0x266c
movq %rax, %r12
movslq 0x8(%rbx), %rsi
xorl %eax, %eax
testl %esi, %esi
movl $0x0, %ecx
cmovgl %esi, %ecx
leaq 0x8(%r15), %rdx
pushq $0x38
popq %rdi
cmpq %rax, %rcx
je 0x18ce4
movq 0x18(%rbx), %r8
movl -0x24(%r8,%rdi), %r9d
movl (%r8,%rdi), %r8d
shlq $0x20, %r9
orq %r9, %r8
movq %r8, -0x8(%rdx)
movq %rax, (%rdx)
incq %rax
addq $0x10, %rdx
addq $0x68, %rdi
jmp 0x18cb7
shlq $0x4, %rsi
addq %r15, %rsi
movq %r15, %rdi
callq 0xcb7f
movl 0x8(%rbx), %edx
movl %edx, %r8d
negl %r8d
movq %rdx, %rax
shlq $0x4, %rax
leaq (%rax,%r15), %r9
addq $-0x8, %r9
pushq $0xd
popq %rax
movslq 0x8(%rbx), %rcx
testl %edx, %edx
jle 0x18d3c
addl %r8d, %ecx
movslq %ecx, %rcx
imulq $0x68, %rcx, %rdi
imulq $0x68, (%r9), %rsi
addq 0x18(%rbx), %rsi
addq %r12, %rdi
movq %rax, %rcx
rep  movsq (%rsi), %es:(%rdi)
incl %r8d
decl %edx
addq $-0x10, %r9
jmp 0x18d0e
movq 0x18(%rbx), %rdi
imulq $0x68, %rcx, %rdx
movq %r12, %rsi
callq 0x2230
movq %r14, %rdi
movq %r15, %rsi
callq 0x2577
movq %r14, %rdi
movq %r12, %rsi
callq 0x2577
movq %r14, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x18a3c
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/gcmisc.c
// Function: mg_gchain_flt_sub
int mg_gchain_flt_sub(float pri_ratio, int min_diff, int best_n, int n, mg_gchain_t *r)
{
	if (pri_ratio > 0.0f && n > 0) {
		int i, k, n_2nd = 0;
		for (i = k = 0; i < n; ++i) {
			int p = r[i].parent;
			if (p == i) { // primary
				r[i].flt = 0, ++k;
			} else if ((r[i].score >= r[p].score * pri_ratio || r[i].score + min_diff >= r[p].score) && n_2nd < best_n) {
				if (!(r[i].qs == r[p].qs && r[i].qe == r[p].qe && r[i].ps == r[p].ps && r[i].pe == r[p].pe)) // not identical hits; TODO: check path as well
					r[i].flt = 0, ++n_2nd, ++k;
				else r[i].flt = 1;
			} else r[i].flt = 1;
		}
		return k;
	}
	return n;
}

// Assembly:
movl %edx, %eax
xorps %xmm1, %xmm1
ucomiss %xmm1, %xmm0
setbe %dl
testl %eax, %eax
setle %r8b
orb %dl, %r8b
jne 0x19119
pushq %rbp
pushq %r14
pushq %rbx
movl %eax, %edx
leaq 0x44(%rcx), %r8
xorl %r9d, %r9d
xorl %eax, %eax
xorl %r10d, %r10d
cmpq %r9, %rdx
je 0x19115
movl -0x40(%r8), %r11d
cmpq %r11, %r9
jne 0x19090
andb $-0x2, 0x1(%r8)
jmp 0x19107
movslq %r11d, %r11
movl -0x30(%r8), %ebx
cvtsi2ss %ebx, %xmm1
imulq $0x68, %r11, %r11
movl 0x14(%rcx,%r11), %ebp
cvtsi2ss %ebp, %xmm2
mulss %xmm0, %xmm2
ucomiss %xmm2, %xmm1
setae %r14b
addl %edi, %ebx
cmpl %ebp, %ebx
setge %bl
orb %r14b, %bl
cmpl %esi, %r10d
setl %bpl
andb %bl, %bpl
cmpb $0x1, %bpl
jne 0x190f8
addq %rcx, %r11
movl -0x2c(%r8), %ebx
cmpl 0x18(%r11), %ebx
jne 0x190ff
movl -0x28(%r8), %ebx
cmpl 0x1c(%r11), %ebx
jne 0x190ff
movl -0x20(%r8), %ebx
cmpl 0x24(%r11), %ebx
jne 0x190ff
movl -0x1c(%r8), %ebx
cmpl 0x28(%r11), %ebx
jne 0x190ff
orb $0x1, 0x1(%r8)
jmp 0x19109
andb $-0x2, 0x1(%r8)
incl %r10d
incl %eax
incq %r9
addq $0x68, %r8
jmp 0x19077
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/map-algo.c
// Function: collect_long_gaps
static int *collect_long_gaps(void *km, int as1, int cnt1, mg128_t *a, int min_gap, int *n_)
{
	int i, n, *K;
	*n_ = 0;
	for (i = 1, n = 0; i < cnt1; ++i) { // count the number of gaps longer than min_gap
		int gap = ((int32_t)a[as1 + i].y - a[as1 + i - 1].y) - ((int32_t)a[as1 + i].x - a[as1 + i - 1].x);
		if (gap < -min_gap || gap > min_gap) ++n;
	}
	if (n <= 1) return 0;
	K = (int*)kmalloc(km, n * sizeof(int));
	for (i = 1, n = 0; i < cnt1; ++i) { // store the positions of long gaps
		int gap = ((int32_t)a[as1 + i].y - a[as1 + i - 1].y) - ((int32_t)a[as1 + i].x - a[as1 + i - 1].x);
		if (gap < -min_gap || gap > min_gap)
			K[n++] = i;
	}
	*n_ = n;
	return K;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r8d, %ebp
andl $0x0, (%r9)
movl %r8d, %r15d
negl %r15d
movslq %edx, %r12
movslq %esi, %rbx
shlq $0x4, %rbx
leaq (%rbx,%rcx), %r10
addq $0x18, %r10
xorl %eax, %eax
pushq $0x1
popq %rdx
cmpq %r12, %rdx
jge 0x1b1e9
movl -0x10(%r10), %esi
movl (%r10), %r8d
addl -0x8(%r10), %esi
subl %esi, %r8d
addl -0x18(%r10), %r8d
cmpl %r15d, %r8d
setl %sil
cmpl %ebp, %r8d
setg %r8b
orb %sil, %r8b
movzbl %r8b, %esi
addl %esi, %eax
incq %rdx
addq $0x10, %r10
jmp 0x1b1b2
xorl %r13d, %r13d
cmpl $0x2, %eax
jae 0x1b1f5
xorl %eax, %eax
jmp 0x1b24e
movl %eax, %esi
shlq $0x2, %rsi
movq %r9, %r14
movq %rcx, (%rsp)
callq 0x266c
movq (%rsp), %rcx
addq %rbx, %rcx
addq $0x18, %rcx
pushq $0x1
popq %rdx
cmpq %r12, %rdx
jge 0x1b24b
movl -0x10(%rcx), %esi
movl (%rcx), %edi
addl -0x8(%rcx), %esi
subl %esi, %edi
addl -0x18(%rcx), %edi
cmpl %r15d, %edi
setge %sil
cmpl %ebp, %edi
setle %dil
testb %dil, %sil
jne 0x1b242
movslq %r13d, %rsi
incl %r13d
movl %edx, (%rax,%rsi,4)
incq %rdx
addq $0x10, %rcx
jmp 0x1b215
movl %r13d, (%r14)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/./gfa-priv.h
// Function: gfa_find_arc
static inline int64_t gfa_find_arc(const gfa_t *g, uint32_t v, uint32_t w)
{
	uint32_t i, nv = gfa_arc_n(g, v), nw = 0, k = (uint32_t)-1;
	gfa_arc_t *av = gfa_arc_a(g, v);
	for (i = 0; i < nv; ++i)
		if (av[i].w == w) ++nw, k = i;
	return nw == 1? (int64_t)(&av[k] - g->arc) : nw == 0? -1 : -2;
}

// Assembly:
movq 0x48(%rdi), %rcx
movq 0x58(%rdi), %rax
movl %esi, %esi
movq (%rax,%rsi,8), %rax
movl %eax, %esi
shrq $0x1b, %rax
andq $-0x20, %rax
leaq (%rax,%rcx), %r8
addq $0x8, %r8
addq %rcx, %rax
pushq $-0x1
popq %rdi
xorl %r10d, %r10d
xorl %r9d, %r9d
cmpq %r10, %rsi
je 0x1b663
xorl %r11d, %r11d
cmpl %edx, (%r8)
cmovel %r10d, %edi
sete %r11b
addl %r11d, %r9d
incq %r10
addq $0x20, %r8
jmp 0x1b644
cmpl $0x1, %r9d
jne 0x1b67a
movl %edi, %edx
shlq $0x5, %rdx
addq %rdx, %rax
subq %rcx, %rax
sarq $0x5, %rax
retq
xorl %eax, %eax
testl %r9d, %r9d
sete %al
orq $-0x2, %rax
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/gmap.c
// Function: mg_map_file_frag
int mg_map_file_frag(const mg_idx_t *idx, int n_segs, const char **fn, const mg_mapopt_t *opt, int n_threads, double *c_seg, double *c_link)
{
	int i, pl_threads;
	pipeline_t pl;
	if (n_segs < 1) return -1;
	memset(&pl, 0, sizeof(pipeline_t));
	pl.n_fp = n_segs;
	pl.fp = open_bseqs(pl.n_fp, fn);
	if (pl.fp == 0) return -1;
	pl.opt = opt, pl.gi = idx;
	pl.n_threads = n_threads > 1? n_threads : 1;
	pl.mini_batch_size = opt->mini_batch_size;
	pl.c_seg = c_seg, pl.c_link = c_link;
	pl_threads = n_threads == 1? 1 : (opt->flag&MG_M_2_IO_THREADS)? 3 : 2;
	kt_pipeline(pl_threads, worker_pipeline, &pl, 3);

	free(pl.str.s);
	for (i = 0; i < pl.n_fp; ++i)
		mg_bseq_close(pl.fp[i]);
	free(pl.fp);
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
pushq $-0x1
popq %rbx
testl %esi, %esi
jle 0x1cf4e
movl %r8d, %ebp
movq %rdx, %r13
movq %rdi, (%rsp)
movq %r9, 0x8(%rsp)
movq %rcx, 0x10(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%rsp)
andq $0x0, 0x50(%rsp)
movups %xmm0, 0x40(%rsp)
movups %xmm0, 0x30(%rsp)
movl %esi, 0x28(%rsp)
movl %esi, %r15d
pushq $0x8
popq %rsi
movq %r15, %rdi
callq 0x21e0
movq %rax, %r12
xorl %r14d, %r14d
cmpq %r14, %r15
je 0x1ce7a
movq (%r13,%r14,8), %rdi
callq 0xcd00
movq %rax, (%r12,%r14,8)
testq %rax, %rax
je 0x1cf1b
incq %r14
jmp 0x1ce59
movq %r12, 0x38(%rsp)
testq %r12, %r12
je 0x1cf4e
movq 0x10(%rsp), %rcx
movq %rcx, 0x30(%rsp)
movq (%rsp), %rax
movq %rax, 0x40(%rsp)
cmpl $0x2, %ebp
pushq $0x1
popq %rdi
movl %edi, %eax
cmovgel %ebp, %eax
movl %eax, 0x24(%rsp)
movq 0x8(%rcx), %rax
movq %rax, 0x18(%rsp)
movq 0x8(%rsp), %rax
movq %rax, 0x58(%rsp)
movq 0xa0(%rsp), %rax
movq %rax, 0x60(%rsp)
cmpl $0x1, %ebp
je 0x1cedc
movb 0x2(%rcx), %al
andb $0x8, %al
cmpb $0x1, %al
pushq $0x3
popq %rdi
sbbl $0x0, %edi
leaq 0x9b(%rip), %rsi        # 0x1cf7e
leaq 0x18(%rsp), %rbx
pushq $0x3
popq %rcx
movq %rbx, %rdx
callq 0x2b21
movq 0x38(%rbx), %rdi
callq 0x2040
xorl %ebx, %ebx
movslq 0x28(%rsp), %rax
movq 0x38(%rsp), %rdi
cmpq %rax, %rbx
jge 0x1cf47
movq (%rdi,%rbx,8), %rdi
callq 0xcda3
incq %rbx
jmp 0x1cefe
leaq 0x114de(%rip), %rax     # 0x2e400
cmpl $0x0, (%rax)
jg 0x1cf5f
xorl %r15d, %r15d
cmpq %r15, %r14
je 0x1cf3d
movq (%r12,%r15,8), %rdi
callq 0xcda3
incq %r15
jmp 0x1cf2a
movq %r12, %rdi
callq 0x2040
jmp 0x1cf4e
callq 0x2040
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x11092(%rip), %rax     # 0x2dff8
movq (%rax), %rdi
movq (%r13,%r14,8), %rdx
leaq 0x80a5(%rip), %rsi      # 0x2501a
xorl %eax, %eax
callq 0x2210
jmp 0x1cf27
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/gmap.c
// Function: mg_map_files
int mg_map_files(gfa_t *g, int n_fn, const char **fn, const mg_idxopt_t *ipt, const mg_mapopt_t *opt0, int n_threads)
{
	mg_mapopt_t opt = *opt0;
	mg_idx_t *gi;
	int i, ret = 0;
	double *cov_seg = 0, *cov_link = 0;
	if ((gi = mg_index(g, ipt, n_threads, &opt)) == 0) return -1;
	if (opt.flag & MG_M_CAL_COV) {
		KCALLOC(0, cov_seg,  g->n_seg);
		KCALLOC(0, cov_link, g->n_arc);
	}
	if (opt.flag & MG_M_FRAG_MODE) {
		ret = mg_map_file_frag(gi, n_fn, fn, &opt, n_threads, cov_seg, cov_link);
	} else {
		for (i = 0; i < n_fn; ++i) {
			ret = mg_map_file_frag(gi, 1, &fn[i], &opt, n_threads, cov_seg, cov_link);
			if (ret != 0) break;
		}
	}
	if (opt.flag & MG_M_CAL_COV) {
		gfa_aux_update_cv(g, "dc", cov_seg, cov_link);
		free(cov_seg); free(cov_link);
	}
	mg_idx_destroy(gi);
	return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
movl %r9d, %ebp
movq %rcx, %rbx
movq %rdx, %r14
movl %esi, %r15d
movq %rdi, %r13
leaq 0x20(%rsp), %r12
movl $0xa8, %edx
movq %r12, %rdi
movq %r8, %rsi
callq 0x2230
movq %r13, %rdi
movq %rbx, %rsi
movl %ebp, %edx
movq %r12, %rcx
callq 0x12e3e
movq %rax, 0x10(%rsp)
testq %rax, %rax
je 0x1d57d
movq 0x20(%rsp), %rax
btl $0xe, %eax
movq %r13, 0x18(%rsp)
jb 0x1d585
xorl %r13d, %r13d
xorl %ebx, %ebx
jmp 0x1d5b2
pushq $-0x1
popq %rbp
jmp 0x1d653
movl 0x4(%r13), %esi
pushq $0x8
popq %rbx
xorl %edi, %edi
movq %rbx, %rdx
callq 0x24f0
movq %r13, %rcx
movq %rax, %r13
movq 0x40(%rcx), %rsi
xorl %edi, %edi
movq %rbx, %rdx
callq 0x24f0
movq %rax, %rbx
movq 0x20(%rsp), %rax
testb $0x40, %al
jne 0x1d5f6
xorl %eax, %eax
testl %r15d, %r15d
cmovlel %eax, %r15d
incq %r15
decq %r15
je 0x1d619
leaq 0x8(%r14), %r12
movq %rbx, (%rsp)
movq 0x10(%rsp), %rdi
pushq $0x1
popq %rsi
movq %r14, %rdx
leaq 0x20(%rsp), %rcx
movl %ebp, %r8d
movq %r13, %r9
callq 0x1cdfc
movq %r12, %r14
testl %eax, %eax
je 0x1d5c2
pushq $-0x1
popq %rbp
jmp 0x1d61b
movq %rbx, (%rsp)
leaq 0x20(%rsp), %rcx
movq 0x10(%rsp), %rdi
movl %r15d, %esi
movq %r14, %rdx
movl %ebp, %r8d
movq %r13, %r9
callq 0x1cdfc
movl %eax, %ebp
jmp 0x1d61b
xorl %ebp, %ebp
testb $0x40, 0x21(%rsp)
je 0x1d649
leaq 0x79ee(%rip), %rsi      # 0x25017
movq 0x18(%rsp), %rdi
movq %r13, %rdx
movq %rbx, %rcx
callq 0x56cf
movq %r13, %rdi
callq 0x2040
movq %rbx, %rdi
callq 0x2040
movq 0x10(%rsp), %rdi
callq 0x1256f
movl %ebp, %eax
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/./bseq.h
// Function: mg_revcomp_seq
static inline void mg_revcomp_seq(int32_t len, char *seq)
{
	int32_t i;
	for (i = 0; i < len>>1; ++i) {
		int32_t t = seq[len - i - 1];
		seq[len - i - 1] = gfa_comp_table[(uint8_t)seq[i]];
		seq[i] = gfa_comp_table[t];
	}
	if (len&1) seq[len>>1] = gfa_comp_table[(uint8_t)seq[len>>1]];
}

// Assembly:
movl %edi, %eax
sarl %eax
xorl %edx, %edx
testl %eax, %eax
movl $0x0, %r8d
cmovgl %eax, %r8d
leal -0x1(%rdi), %r9d
leaq 0xf034(%rip), %rcx      # 0x2e200
cmpq %rdx, %r8
je 0x1f1f6
movslq %r9d, %r9
movsbq (%rsi,%r9), %r10
movzbl (%rsi,%rdx), %r11d
movb (%rcx,%r11), %r11b
movb %r11b, (%rsi,%r9)
movb (%rcx,%r10), %r10b
movb %r10b, (%rsi,%rdx)
incq %rdx
decl %r9d
jmp 0x1f1cc
testb $0x1, %dil
je 0x1f208
cltq
movzbl (%rsi,%rax), %edx
movb (%rcx,%rdx), %cl
movb %cl, (%rsi,%rax)
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/ggen.c
// Function: mg_ggen_aug
int mg_ggen_aug(gfa_t *g, int32_t n_fn, const char **fn, const mg_idxopt_t *ipt, const mg_mapopt_t *opt0, const mg_ggopt_t *go, int n_threads)
{
	int i;
	mg_mapopt_t opt = *opt0;
	if (g == 0) return -1;
	for (i = 0; i < n_fn; ++i) {
		mg_idx_t *gi;
		maprst_t *r;
		if ((gi = mg_index(g, ipt, n_threads, &opt)) == 0) return -1;
		r = ggen_map(gi, &opt, fn[i], n_threads);
		if (opt0->flag & MG_M_CIGAR)
			mg_ggsimple_cigar(0, go, g, r->n_seq, r->seq, r->gcs);
		else
			mg_ggsimple(0, go, g, r->n_seq, r->seq, r->gcs);
		mg_free_maprst(r);
		mg_idx_destroy(gi);
	}
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movq %r9, 0x10(%rsp)
movq %rcx, 0x28(%rsp)
movq %rdx, 0x18(%rsp)
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x30(%rsp), %rdi
movl $0xa8, %edx
movq %r8, 0x20(%rsp)
movq %r8, %rsi
callq 0x2230
pushq $-0x1
popq %rax
movq %rbx, 0x8(%rsp)
testq %rbx, %rbx
je 0x205f5
movl 0x110(%rsp), %r14d
xorl %ebx, %ebx
testl %ebp, %ebp
cmovlel %ebx, %ebp
leaq 0x30(%rsp), %r12
cmpq %rbx, %rbp
je 0x205ee
movq 0x8(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl %r14d, %edx
movq %r12, %rcx
callq 0x12e3e
testq %rax, %rax
je 0x205f2
movq %rax, %r15
movq 0x18(%rsp), %rax
movq (%rax,%rbx,8), %rdx
movq %r15, %rdi
movq %r12, %r13
movq %r12, %rsi
movl %r14d, %r12d
movl %r14d, %ecx
callq 0x20607
movq 0x20(%rsp), %rcx
testb $0x4, 0x3(%rcx)
movq %rax, %r14
movl (%rax), %ecx
movq 0x8(%rax), %r8
movq 0x10(%rax), %r9
jne 0x205bf
xorl %edi, %edi
movq 0x10(%rsp), %rsi
movq 0x8(%rsp), %rdx
callq 0x1dee4
jmp 0x205d0
xorl %edi, %edi
movq 0x10(%rsp), %rsi
movq 0x8(%rsp), %rdx
callq 0x1f209
movq %r14, %rdi
callq 0x20868
movq %r15, %rdi
callq 0x1256f
incq %rbx
movl %r12d, %r14d
movq %r13, %r12
jmp 0x20551
xorl %eax, %eax
jmp 0x205f5
pushq $-0x1
popq %rax
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/ggen.c
// Function: mg_free_maprst
static void mg_free_maprst(maprst_t *r)
{
	int i;
	for (i = 0; i < r->n_seq; ++i) {
		mg_gchain_free(r->gcs[i]);
		free(r->seq[i].seq); free(r->seq[i].name);
	}
	free(r->gcs); free(r->seq);
	free(r);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
xorl %r14d, %r14d
xorl %r15d, %r15d
movslq (%rbx), %rax
movq 0x10(%rbx), %rdi
cmpq %rax, %r15
jge 0x208b0
movq (%rdi,%r15,8), %rdi
callq 0x17683
movq 0x8(%rbx), %rax
movq 0x10(%rax,%r14), %rdi
callq 0x2040
movq 0x8(%rbx), %rax
movq 0x8(%rax,%r14), %rdi
callq 0x2040
incq %r15
addq $0x28, %r14
jmp 0x20876
callq 0x2040
movq 0x8(%rbx), %rdi
callq 0x2040
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x2040
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/ggen.c
// Function: mg_ggen_cov
int mg_ggen_cov(gfa_t *g, int32_t n_fn, const char **fn, const mg_idxopt_t *ipt, const mg_mapopt_t *opt0, const mg_ggopt_t *go, int n_threads)
{
	int32_t i;
	mg_mapopt_t opt = *opt0;
	mg_idx_t *gi;
	double *cov_seg, *cov_link;
	int64_t j;
	if ((gi = mg_index(g, ipt, n_threads, &opt)) == 0) return -1;
	KCALLOC(0, cov_seg,  g->n_seg);
	KCALLOC(0, cov_link, g->n_arc);
	for (i = 0; i < n_fn; ++i) {
		maprst_t *r;
		r = ggen_map(gi, &opt, fn[i], n_threads);
		mg_cov_asm(g, r->n_seq, r->gcs, go->min_mapq, go->min_map_len, cov_seg, cov_link);
		mg_free_maprst(r);
	}
	mg_idx_destroy(gi);
	for (j = 0; j < g->n_seg; ++j) cov_seg[j] /= n_fn;
	for (j = 0; j < g->n_arc; ++j) cov_link[j] /= n_fn;
	gfa_aux_update_cv(g, "cf", cov_seg, cov_link);
	free(cov_seg); free(cov_link);
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movq %r9, %r12
movq %rcx, %rbx
movq %rdx, 0x28(%rsp)
movl %esi, %ebp
movq %rdi, %r15
movl 0x110(%rsp), %r13d
leaq 0x30(%rsp), %r14
movl $0xa8, %edx
movq %r14, %rdi
movq %r8, %rsi
callq 0x2230
movq %r15, %rdi
movq %rbx, %rsi
movl %r13d, %edx
movq %r14, %rcx
callq 0x12e3e
movq %rax, 0x20(%rsp)
testq %rax, %rax
je 0x20a34
movl 0x4(%r15), %esi
xorl %r13d, %r13d
pushq $0x8
popq %rbx
xorl %edi, %edi
movq %rbx, %rdx
callq 0x24f0
movq %rax, %r14
movq %r15, 0x18(%rsp)
movq 0x40(%r15), %rsi
xorl %edi, %edi
movq %rbx, %rdx
callq 0x24f0
movq %rax, %r15
testl %ebp, %ebp
movl %ebp, %eax
movl $0x0, %ebp
movl %eax, 0x14(%rsp)
cmovgl %eax, %ebp
cmpq %r13, %rbp
je 0x209ba
movq 0x28(%rsp), %rax
movq (%rax,%r13,8), %rdx
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rsi
movl 0x110(%rsp), %ecx
callq 0x20607
movq %rax, %rbx
movl (%rax), %esi
movq 0x10(%rax), %rdx
movl 0xc(%r12), %ecx
movl 0x10(%r12), %r8d
movq %r15, (%rsp)
movq 0x18(%rsp), %rdi
movq %r14, %r9
callq 0x1b687
movq %rbx, %rdi
callq 0x20868
incq %r13
jmp 0x20965
movq 0x20(%rsp), %rdi
callq 0x1256f
movq 0x18(%rsp), %rdi
movl 0x4(%rdi), %eax
cvtsi2sdl 0x14(%rsp), %xmm0
xorl %ecx, %ecx
cmpq %rax, %rcx
jae 0x209ee
movsd (%r14,%rcx,8), %xmm1
divsd %xmm0, %xmm1
movsd %xmm1, (%r14,%rcx,8)
incq %rcx
jmp 0x209d4
movq 0x40(%rdi), %rax
xorl %ecx, %ecx
cmpq %rcx, %rax
je 0x20a0e
movsd (%r15,%rcx,8), %xmm1
divsd %xmm0, %xmm1
movsd %xmm1, (%r15,%rcx,8)
incq %rcx
jmp 0x209f4
leaq 0x4c06(%rip), %rsi      # 0x2561b
movq %r14, %rdx
movq %r15, %rcx
callq 0x56cf
movq %r14, %rdi
callq 0x2040
movq %r15, %rdi
callq 0x2040
xorl %eax, %eax
jmp 0x20a37
pushq $-0x1
popq %rax
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/ggen.c
// Function: mg_ggen_call
int mg_ggen_call(gfa_t *g, const char *fn, const mg_idxopt_t *ipt, const mg_mapopt_t *opt0, const mg_ggopt_t *go, int n_threads)
{
	mg_mapopt_t opt = *opt0;
	mg_idx_t *gi;
	maprst_t *r;
	if ((gi = mg_index(g, ipt, n_threads, &opt)) == 0) return -1;
	r = ggen_map(gi, &opt, fn, n_threads);
	mg_call_asm(g, r->n_seq, r->seq, r->gcs, go->min_mapq, go->min_map_len);
	mg_free_maprst(r);
	mg_idx_destroy(gi);
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movl %r9d, %ebp
movq %r8, %rbx
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %r14
movq %rsp, %r13
movl $0xa8, %edx
movq %r13, %rdi
movq %rcx, %rsi
callq 0x2230
movq %r14, %rdi
movq %r15, %rsi
movl %ebp, %edx
movq %r13, %rcx
callq 0x12e3e
testq %rax, %rax
je 0x20ad5
movq %rax, %r15
movq %rsp, %rsi
movq %rax, %rdi
movq %r12, %rdx
movl %ebp, %ecx
callq 0x20607
movq %rax, %r12
movl (%rax), %esi
movq 0x8(%rax), %rdx
movq 0x10(%rax), %rcx
movl 0xc(%rbx), %r8d
movl 0x10(%rbx), %r9d
movq %r14, %rdi
callq 0x20e94
movq %r12, %rdi
callq 0x20868
movq %r15, %rdi
callq 0x1256f
xorl %eax, %eax
jmp 0x20ad8
pushq $-0x1
popq %rax
addq $0xa8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/ggen.c
// Function: worker_for
static void worker_for(void *_data, long i, int tid) // kt_for() callback
{
    step_t *s = (step_t*)_data;
	if (mg_dbg_flag & MG_DBG_QNAME)
		fprintf(stderr, "QR\t%s\t%d\t%d\n", s->r->seq[i].name, tid, s->r->seq[i].l_seq);
	if ((s->opt->flag & MG_M_SKIP_GCHECK) == 0 && mg_verbose >= 2) {
		if (gfa_sseq_get(s->gi->g, s->r->seq[i].name) >= 0)
			fprintf(stderr, "[W::%s] stable sequence \"%s\" already present in the graph. This will lead to inconsistent rGFA.\n",
					__func__, s->r->seq[i].name);
	}
	s->r->gcs[i] = mg_map(s->gi, s->r->seq[i].l_seq, s->r->seq[i].seq, s->buf[tid], s->opt, s->r->seq[i].name);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0xd8cd(%rip), %rax      # 0x2e678
testb $0x2, (%rax)
jne 0x20e2e
movq (%r14), %rax
testb $0x2, 0x3(%rax)
jne 0x20de6
leaq 0xd640(%rip), %rax      # 0x2e400
cmpl $0x2, (%rax)
jl 0x20de6
movq 0x8(%r14), %rax
movq 0x18(%r14), %rcx
movq (%rax), %rdi
movq 0x8(%rcx), %rax
imulq $0x28, %rbx, %r15
movq 0x8(%rax,%r15), %rsi
callq 0x44ac
testl %eax, %eax
jns 0x20e62
movq (%r14), %r8
movq 0x8(%r14), %rdi
movq 0x18(%r14), %rax
movq 0x8(%rax), %rax
imulq $0x28, %rbx, %r9
movl (%rax,%r9), %esi
movq 0x10(%rax,%r9), %rdx
movq 0x10(%r14), %rcx
movslq %ebp, %r10
movq (%rcx,%r10,8), %rcx
movq 0x8(%rax,%r9), %r9
callq 0x1af64
movq 0x18(%r14), %rcx
movq 0x10(%rcx), %rcx
movq %rax, (%rcx,%rbx,8)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq 0xd1c3(%rip), %rax      # 0x2dff8
movq (%rax), %rdi
movq 0x18(%r14), %rax
movq 0x8(%rax), %rax
imulq $0x28, %rbx, %rcx
movq 0x8(%rax,%rcx), %rdx
movl (%rax,%rcx), %r8d
leaq 0x4263(%rip), %rsi      # 0x250b7
movl %ebp, %ecx
xorl %eax, %eax
callq 0x2210
jmp 0x20db0
movq 0xd18f(%rip), %rax      # 0x2dff8
movq (%rax), %rdi
movq 0x18(%r14), %rax
movq 0x8(%rax), %rax
movq 0x8(%rax,%r15), %rcx
leaq 0x48c3(%rip), %rsi      # 0x25743
leaq 0x491d(%rip), %rdx      # 0x257a4
xorl %eax, %eax
callq 0x2210
jmp 0x20de6
nop
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/main.c
// Function: mm_parse_num2
static inline int64_t mm_parse_num2(const char *str, char **q)
{
	double x;
	char *p;
	x = strtod(str, &p);
	if (*p == 'G' || *p == 'g') x *= 1e9, ++p;
	else if (*p == 'M' || *p == 'm') x *= 1e6, ++p;
	else if (*p == 'K' || *p == 'k') x *= 1e3, ++p;
	if (q) *q = p;
	return (int64_t)(x + .499);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rsp, %r14
movq %r14, %rsi
callq 0x20c0
movq (%r14), %rax
movzbl (%rax), %ecx
addl $-0x47, %ecx
cmpl $0x26, %ecx
ja 0x22964
movabsq $0x100000001, %rdx      # imm = 0x100000001
btq %rcx, %rdx
jb 0x22959
movabsq $0x1000000010, %rdx     # imm = 0x1000000010
btq %rcx, %rdx
jb 0x2294f
movabsq $0x4000000040, %rdx     # imm = 0x4000000040
btq %rcx, %rdx
jae 0x22964
mulsd 0x3003(%rip), %xmm0     # 0x25950
jmp 0x22961
mulsd 0x2ff1(%rip), %xmm0     # 0x25948
jmp 0x22961
mulsd 0x2ff7(%rip), %xmm0     # 0x25958
incq %rax
testq %rbx, %rbx
je 0x2296c
movq %rax, (%rbx)
addsd 0x1b54(%rip), %xmm0     # 0x244c8
cvttsd2si %xmm0, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/main.c
// Function: yes_or_no
static inline void yes_or_no(uint64_t *flag_, uint64_t f, int long_idx, const char *arg, int yes_to_set)
{
	uint64_t flag = *flag_;
	if (yes_to_set) {
		if (strcmp(arg, "yes") == 0 || strcmp(arg, "y") == 0) flag |= f;
		else if (strcmp(arg, "no") == 0 || strcmp(arg, "n") == 0) flag &= ~f;
		else fprintf(stderr, "[WARNING]\033[1;31m option '--%s' only accepts 'yes' or 'no'.\033[0m\n", long_options[long_idx].name);
	} else {
		if (strcmp(arg, "yes") == 0 || strcmp(arg, "y") == 0) flag &= ~f;
		else if (strcmp(arg, "no") == 0 || strcmp(arg, "n") == 0) flag |= f;
		else fprintf(stderr, "[WARNING]\033[1;31m option '--%s' only accepts 'yes' or 'no'.\033[0m\n", long_options[long_idx].name);
	}
	*flag_ = flag;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r8d, %r12d
movq %rcx, %r15
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
movq (%rdi), %r13
leaq 0x3c07(%rip), %rsi      # 0x265ab
movq %rcx, %rdi
callq 0x21f0
testl %r12d, %r12d
je 0x229c5
testl %eax, %eax
je 0x22a0b
movzbl (%r15), %eax
cmpl $0x6e, %eax
je 0x229d9
cmpl $0x79, %eax
je 0x22a04
jmp 0x22a20
testl %eax, %eax
je 0x229ee
movzbl (%r15), %eax
cmpl $0x6e, %eax
je 0x229f6
cmpl $0x79, %eax
je 0x229e7
jmp 0x22a20
cmpb $0x6f, 0x1(%r15)
jne 0x229e7
cmpb $0x0, 0x2(%r15)
je 0x229ee
cmpb $0x0, 0x1(%r15)
jne 0x22a20
notq %r14
andq %r14, %r13
jmp 0x22a0e
cmpb $0x6f, 0x1(%r15)
jne 0x22a04
cmpb $0x0, 0x2(%r15)
je 0x22a0b
cmpb $0x0, 0x1(%r15)
jne 0x22a20
orq %r14, %r13
movq %r13, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0xb5d1(%rip), %rax      # 0x2dff8
movq (%rax), %rdi
movslq %ebp, %rax
shlq $0x4, %rax
leaq 0xb9d8(%rip), %rcx      # 0x2e410
movq (%rax,%rcx), %rdx
leaq 0x3b6c(%rip), %rsi      # 0x265af
xorl %eax, %eax
callq 0x2210
jmp 0x22a0e
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minigraph/./ketopt.h
// Function: ketopt_permute
static void ketopt_permute(char *argv[], int j, int n) /* move argv[j] over n elements to the left */
{
	int k;
	char *p = argv[j];
	for (k = 0; k < n; ++k)
		argv[j - k] = argv[j - k - 1];
	argv[j - k] = p;
}

// Assembly:
movslq %esi, %rax
leaq (%rdi,%rax,8), %rcx
movq (%rcx), %rax
xorl %r8d, %r8d
testl %edx, %edx
cmovlel %r8d, %edx
movq %rdx, %r9
negq %r9
cmpq %r8, %r9
je 0x22a78
movq -0x8(%rcx,%r8,8), %r10
movq %r10, (%rcx,%r8,8)
decq %r8
jmp 0x22a65
subl %edx, %esi
movslq %esi, %rcx
movq %rax, (%rdi,%rcx,8)
retq