LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/index.c
// Function: mm_idx_alt_read
int mm_idx_alt_read(mm_idx_t *mi, const char *fn)
{
	int n_alt = 0;
	gzFile fp;
	kstream_t *ks;
	kstring_t str = {0,0,0};
	fp = fn && strcmp(fn, "-")? gzopen(fn, "r") : gzdopen(fileno(stdin), "r");
	if (fp == 0) return -1;
	ks = ks_init(fp);
	if (mi->h == 0) mm_idx_index_name(mi);
	while (ks_getuntil(ks, KS_SEP_LINE, &str, 0) >= 0) {
		char *p;
		int id;
		for (p = str.s; *p && !isspace(*p); ++p) { }
		*p = 0;
		id = mm_idx_name2id(mi, str.s);
		if (id >= 0) mi->seq[id].is_alt = 1, ++n_alt;
	}
	mi->n_alt = n_alt;
	if (mm_verbose >= 3)
		fprintf(stderr, "[M::%s] found %d ALT contigs\n", __func__, n_alt);
	return n_alt;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
andq $0x0, 0x10(%rsp)
testq %rsi, %rsi
je 0x7836
cmpb $0x2d, (%rsi)
jne 0x7822
cmpb $0x0, 0x1(%rsi)
je 0x7836
leaq 0x20452(%rip), %rax     # 0x27c7b
movq %rsi, %rdi
movq %rax, %rsi
callq 0x2350
jmp 0x7853
movq 0x2a79b(%rip), %rax     # 0x31fd8
movq (%rax), %rdi
callq 0x22b0
leaq 0x2042f(%rip), %rsi     # 0x27c7b
movl %eax, %edi
callq 0x20f0
testq %rax, %rax
je 0x7911
movq %rax, %rdi
callq 0x10df8
movq %rax, %r15
cmpq $0x0, 0x58(%rbx)
jne 0x7876
movq %rbx, %rdi
callq 0x5daa
xorl %r14d, %r14d
movq %rsp, %r12
movq %r15, %rdi
movq %r12, %rsi
xorl %edx, %edx
callq 0x7927
testl %eax, %eax
js 0x78dd
movq 0x10(%rsp), %r13
movsbq (%r13), %rbp
testq %rbp, %rbp
je 0x78b0
callq 0x2460
movq (%rax), %rax
testb $0x20, 0x1(%rax,%rbp,2)
jne 0x78b0
incq %r13
jmp 0x7892
movb $0x0, (%r13)
movq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x6048
testl %eax, %eax
js 0x787c
movq 0x20(%rbx), %rcx
movl %eax, %eax
imulq $0x18, %rax, %rax
movl $0x1, 0x14(%rcx,%rax)
incl %r14d
jmp 0x787c
movl %r14d, 0x18(%rbx)
leaq 0x2ae18(%rip), %rax     # 0x32700
cmpl $0x3, (%rax)
jl 0x7915
movq 0x2a704(%rip), %rax     # 0x31ff8
movq (%rax), %rdi
leaq 0x20aa3(%rip), %rsi     # 0x283a1
leaq 0x20aba(%rip), %rdx     # 0x283bf
movl %r14d, %ecx
xorl %eax, %eax
callq 0x2260
jmp 0x7915
pushq $-0x1
popq %r14
movl %r14d, %eax
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]minimap2/index.c
// Function: mm_idx_bed_junc
int mm_idx_bed_junc(const mm_idx_t *mi, int32_t ctg, int32_t st, int32_t en, uint8_t *s)
{
	int32_t i, left, right;
	mm_idx_intv_t *r;
	memset(s, 0, en - st);
	if (mi->I == 0 || ctg < 0 || ctg >= mi->n_seq) return -1;
	r = &mi->I[ctg];
	left = 0, right = r->n;
	while (right > left) {
		int32_t mid = left + ((right - left) >> 1);
		if (r->a[mid].st >= st) right = mid;
		else left = mid + 1;
	}
	for (i = left; i < r->n; ++i) {
		if (st <= r->a[i].st && en >= r->a[i].en && r->a[i].strand != 0) {
			if (r->a[i].strand > 0) {
				s[r->a[i].st - st] |= 1, s[r->a[i].en - 1 - st] |= 2;
			} else {
				s[r->a[i].st - st] |= 8, s[r->a[i].en - 1 - st] |= 4;
			}
		}
	}
	return left;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %r8, %rbx
movl %ecx, %ebp
movl %edx, %r14d
movl %esi, %r15d
movq %rdi, %r12
movl %ecx, %eax
subl %edx, %eax
movslq %eax, %rdx
movq %r8, %rdi
xorl %esi, %esi
callq 0x21b0
movq 0x38(%r12), %rdx
testq %rdx, %rdx
sete %al
testl %r15d, %r15d
sets %cl
orb %al, %cl
pushq $-0x1
popq %rax
jne 0x8576
cmpl %r15d, 0x10(%r12)
jbe 0x8576
movl %r15d, %eax
shlq $0x4, %rax
leaq (%rdx,%rax), %rcx
movl (%rdx,%rax), %edx
xorl %eax, %eax
movl %edx, %esi
movl %esi, %edi
subl %eax, %edi
jle 0x8502
sarl %edi
leal (%rdi,%rax), %r8d
movq 0x8(%rcx), %r9
movslq %r8d, %r10
shlq $0x4, %r10
cmpl %r14d, (%r9,%r10)
jl 0x84fc
movl %r8d, %esi
jmp 0x84da
addl %edi, %eax
incl %eax
jmp 0x84da
movl %r14d, %esi
notl %esi
movslq %eax, %rdi
movq %rdi, %r8
shlq $0x4, %r8
pushq $0x1
popq %r9
pushq $0x8
popq %r10
movslq %edx, %rdx
cmpq %rdx, %rdi
jge 0x8576
movq 0x8(%rcx), %r11
movl (%r11,%r8), %edx
subl %r14d, %edx
jl 0x856b
cmpl %ebp, 0x4(%r11,%r8)
jg 0x856b
cmpl $0x40000000, 0xc(%r11,%r8) # imm = 0x40000000
jb 0x856b
setl %r11b
movslq %edx, %rdx
movl %r10d, %r15d
cmovgel %r9d, %r15d
addb %r11b, %r11b
orb %r15b, (%rbx,%rdx)
addb $0x2, %r11b
movq 0x8(%rcx), %rdx
movl 0x4(%rdx,%r8), %edx
addl %esi, %edx
movslq %edx, %rdx
orb %r11b, (%rbx,%rdx)
incq %rdi
movl (%rcx), %edx
addq $0x10, %r8
jmp 0x8519
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/index.c
// Function: sort_jjump
static void sort_jjump(mm_idx_jjump_t *jj2)
{
	int32_t j0, j, k;
	if (jj2 == 0 || jj2->n == 0) return;
	radix_sort_jj(jj2->a, jj2->a + jj2->n);
	for (j0 = 0, j = 1; j <= jj2->n; ++j) {
		if (j == jj2->n || jj2->a[j0].off != jj2->a[j].off) {
			radix_sort_jj2(jj2->a + j0, jj2->a + j);
			j0 = j;
		}
	}
	// the actual merge
	for (j0 = 0, j = 1, k = 0; j <= jj2->n; ++j) {
		if (j == jj2->n || jj2->a[j0].off != jj2->a[j].off || jj2->a[j0].off2 != jj2->a[j].off2) {
			int32_t t, cnt = 0;
			uint16_t flag = 0;
			for (t = j0; t < j; ++t) cnt += jj2->a[t].cnt, flag |= jj2->a[t].flag;
			jj2->a[k] = jj2->a[j0];
			jj2->a[k].cnt = cnt;
			jj2->a[k++].flag = flag;
			j0 = j;
		}
	}
	jj2->n = k;
	jj2->a = REALLOC(mm_idx_jjump1_t, jj2->a, k);
}

// Assembly:
testq %rdi, %rdi
je 0x9a41
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movslq (%rdi), %rsi
testq %rsi, %rsi
je 0x9a37
movq 0x8(%rbx), %rdi
shlq $0x4, %rsi
addq %rdi, %rsi
callq 0x8806
xorl %eax, %eax
pushq $0x1
popq %r14
pushq $0x10
popq %r15
movslq (%rbx), %rcx
cmpq %rcx, %r14
jg 0x9978
movl %ecx, %ecx
movq 0x8(%rbx), %rsi
movslq %eax, %rdi
cmpq %rcx, %r14
je 0x995d
movq %rdi, %rcx
shlq $0x4, %rcx
movl (%rsi,%rcx), %ecx
cmpl (%rsi,%r15), %ecx
je 0x996f
shlq $0x4, %rdi
addq %rsi, %rdi
addq %r15, %rsi
callq 0x8a7c
movl %r14d, %eax
incq %r14
addq $0x10, %r15
jmp 0x9937
xorl %edi, %edi
pushq $0x1
popq %rax
xorl %r8d, %r8d
movslq %ecx, %rdx
movslq %r8d, %rsi
cmpq %rdx, %rax
jg 0x9a24
movl %ecx, %r9d
movslq %edi, %rdx
cmpq %r9, %rax
je 0x99c6
movq 0x8(%rbx), %r9
movq %rdx, %r10
shlq $0x4, %r10
movl (%r9,%r10), %ebp
movq %rax, %r11
shlq $0x4, %r11
cmpl (%r9,%r11), %ebp
jne 0x99c6
addq %r9, %r10
addq %r9, %r11
movl 0x4(%r10), %r9d
cmpl 0x4(%r11), %r9d
je 0x9a1c
movq 0x8(%rbx), %rcx
movq %rdx, %rdi
shlq $0x4, %rdi
leaq (%rcx,%rdi), %r10
addq $0xe, %r10
xorl %r8d, %r8d
xorl %r9d, %r9d
cmpq %rax, %rdx
jge 0x99f5
addl -0x6(%r10), %r8d
orw (%r10), %r9w
incq %rdx
addq $0x10, %r10
jmp 0x99df
movq %rsi, %rdx
shlq $0x4, %rdx
movups (%rcx,%rdi), %xmm0
movups %xmm0, (%rcx,%rdx)
movq 0x8(%rbx), %rcx
movl %r8d, 0x8(%rcx,%rdx)
incl %esi
movw %r9w, 0xe(%rcx,%rdx)
movl (%rbx), %ecx
movl %eax, %edi
movl %esi, %r8d
incq %rax
jmp 0x9980
movl %esi, (%rbx)
movq 0x8(%rbx), %rdi
shlq $0x4, %rsi
callq 0x2320
movq %rax, 0x8(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/index.c
// Function: mm_idx_jump_get
const mm_idx_jjump1_t *mm_idx_jump_get(const mm_idx_t *db, int32_t cid, int32_t st, int32_t en, int32_t *n)
{
	mm_idx_jjump_t *s;
	int32_t l, r;
	*n = 0;
	if (cid >= db->n_seq || cid < 0 || db->J == 0) return 0;
	if (en < 0 || en > db->seq[cid].len) en = db->seq[cid].len;
	s = &db->J[cid];
	if (s->n == 0) return 0;
	l = mm_idx_jump_get_core(s->n, s->a, st);
	r = mm_idx_jump_get_core(s->n, s->a, en);
	*n = r - l;
	return &s->a[l + 1];
}

// Assembly:
andl $0x0, (%r8)
xorl %eax, %eax
testl %esi, %esi
js 0x8e51
cmpl %esi, 0x10(%rdi)
jbe 0x8e51
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq 0x48(%rdi), %r15
testq %r15, %r15
je 0x8e45
movq %r8, %rbx
movl %esi, %esi
movq %rsi, %r8
shlq $0x4, %r8
movl (%r15,%r8), %eax
testl %eax, %eax
je 0x8e45
addq %r8, %r15
movq 0x20(%rdi), %rdi
imulq $0x18, %rsi, %rsi
movl 0x10(%rdi,%rsi), %esi
cmpl %ecx, %esi
movl %ecx, %ebp
cmovbl %esi, %ebp
testl %ecx, %ecx
cmovsl %esi, %ebp
movq 0x8(%r15), %rsi
movl %eax, %edi
callq 0x8e52
movl %eax, %r14d
movl (%r15), %edi
movq 0x8(%r15), %rsi
movl %ebp, %edx
callq 0x8e52
subl %r14d, %eax
movl %eax, (%rbx)
movq 0x8(%r15), %rax
movslq %r14d, %rcx
shlq $0x4, %rcx
addq %rcx, %rax
addq $0x10, %rax
jmp 0x8e47
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/index.c
// Function: mm_idx_jump_get_core
static int32_t mm_idx_jump_get_core(int32_t n, const mm_idx_jjump1_t *a, int32_t x) // similar to mm_idx_find_intv()
{
	int32_t s = 0, e = n;
	if (n == 0) return -1;
	if (x < a[0].off) return -1;
	while (s < e) {
		int32_t mid = s + (e - s) / 2;
		if (x >= a[mid].off && (mid + 1 >= n || x < a[mid+1].off)) return mid;
		else if (x < a[mid].off) e = mid;
		else s = mid + 1;
	}
	assert(0);
}

// Assembly:
pushq $-0x1
popq %rax
testl %edi, %edi
je 0x8e9c
movl %edx, %ecx
cmpl %edx, (%rsi)
jg 0x8e9c
xorl %r9d, %r9d
pushq $0x2
popq %r8
movl %edi, %r10d
movl %r10d, %eax
movl %eax, %r10d
subl %r9d, %eax
jle 0x8e9d
cltd
idivl %r8d
addl %r9d, %eax
movslq %eax, %rdx
shlq $0x4, %rdx
cmpl %ecx, (%rsi,%rdx)
jg 0x8e6c
leal 0x1(%rax), %r9d
cmpl %edi, %r9d
jge 0x8e9c
movslq %r9d, %rdx
shlq $0x4, %rdx
cmpl %ecx, (%rsi,%rdx)
jle 0x8e69
retq
pushq %rax
leaq 0x1fc1c(%rip), %rdi     # 0x28ac1
leaq 0x1f40d(%rip), %rsi     # 0x282b9
leaq 0x1f83f(%rip), %rcx     # 0x286f2
movl $0x3af, %edx            # imm = 0x3AF
callq 0x21a0
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/index.c
// Function: mm_idx_spsc_get
int64_t mm_idx_spsc_get(const mm_idx_t *db, int32_t cid, int64_t st, int64_t en, int32_t rev, uint8_t *sc)
{
	const mm_idx_spsc_t *s;
	if (cid >= db->n_seq || cid < 0 || db->spsc == 0) return -1;
	if (en < 0 || en > db->seq[cid].len) en = db->seq[cid].len;
	memset(sc, 0xff, en - st);
	s = &db->spsc[cid << 1 | (!!rev)];
	if (s->n > 0) {
		int32_t j, l, r;
		l = mm_idx_find_intv(s->n, s->a, st);
		r = mm_idx_find_intv(s->n, s->a, en);
		for (j = l + 1; j <= r; ++j) {
			int64_t x = (s->a[j]>>8) - st;
			uint8_t score = s->a[j] & 0xff;
			assert(x <= en - st);
			if (x == en - st) continue;
			if (sc[x] == 0xff || sc[x] < score) sc[x] = score;
		}
	}
	return en - st;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
pushq $-0x1
popq %r15
testl %esi, %esi
js 0x9358
movl %esi, %r13d
movq %rdi, %rbp
cmpl %esi, 0x10(%rdi)
jbe 0x9358
cmpq $0x0, 0x40(%rbp)
je 0x9358
movq %r9, %rbx
movq %rdx, %r14
movq 0x20(%rbp), %rax
movl %r13d, %edx
imulq $0x18, %rdx, %rdx
movl 0x10(%rax,%rdx), %eax
cmpq %rcx, %rax
movq %rcx, %r12
cmovbq %rax, %r12
testq %rcx, %rcx
cmovsq %rax, %r12
movq %r12, %r15
subq %r14, %r15
movq %r9, %rdi
movl $0xff, %esi
movq %r15, %rdx
movl %r8d, 0x4(%rsp)
callq 0x21b0
movq 0x40(%rbp), %rbp
xorl %eax, %eax
cmpl $0x0, 0x4(%rsp)
setne %al
leal (%rax,%r13,2), %eax
cltq
shlq $0x4, %rax
movl (%rbp,%rax), %edi
testl %edi, %edi
je 0x9358
addq %rax, %rbp
movq 0x8(%rbp), %rsi
movq %r14, %rdx
callq 0x9389
movl %eax, %r13d
movl (%rbp), %edi
movq 0x8(%rbp), %rsi
movq %r12, %rdx
callq 0x9389
movslq %r13d, %rcx
cltq
movl $0xff, %r10d
cmpq %rax, %rcx
jge 0x9358
movq 0x8(%rbp), %rdx
movq 0x8(%rdx,%rcx,8), %rdx
movq %rdx, %rdi
shrq $0x8, %rdi
movq %rdi, %rsi
subq %r14, %rsi
cmpq %r15, %rsi
jg 0x936a
cmpq %r12, %rdi
je 0x9353
movzbl (%rbx,%rsi), %edi
cmpl %r10d, %edi
setne %r8b
movl %edx, %r9d
andl %r10d, %r9d
cmpl %edi, %r9d
setbe %dil
testb %dil, %r8b
jne 0x9353
movb %dl, (%rbx,%rsi)
incq %rcx
jmp 0x930e
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x1f1e9(%rip), %rdi     # 0x2855a
leaq 0x1ef41(%rip), %rsi     # 0x282b9
leaq 0x1f1e8(%rip), %rcx     # 0x28567
movl $0x42c, %edx            # imm = 0x42C
callq 0x21a0
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/index.c
// Function: mm_idx_find_intv
static int32_t mm_idx_find_intv(int32_t n, const uint64_t *a, int64_t x)
{
	int32_t s = 0, e = n;
	if (n == 0) return -1;
	if (x < a[0]>>8) return -1;
	while (s < e) {
		int32_t mid = s + (e - s) / 2;
		if (x >= a[mid]>>8 && (mid + 1 >= n || x < a[mid+1]>>8)) return mid;
		else if (x < a[mid]>>8) e = mid;
		else s = mid + 1;
	}
	assert(0);
}

// Assembly:
pushq $-0x1
popq %rax
testl %edi, %edi
je 0x93e4
movq %rdx, %rcx
movq (%rsi), %rdx
shrq $0x8, %rdx
cmpq %rcx, %rdx
ja 0x93e4
xorl %r9d, %r9d
pushq $0x2
popq %r8
movl %edi, %r10d
movl %r10d, %eax
movl %eax, %r10d
subl %r9d, %eax
jle 0x93e5
cltd
idivl %r8d
addl %r9d, %eax
movslq %eax, %rdx
movq (%rsi,%rdx,8), %rdx
shrq $0x8, %rdx
cmpq %rcx, %rdx
ja 0x93ac
leal 0x1(%rax), %r9d
cmpl %edi, %r9d
jge 0x93e4
movslq %r9d, %rdx
movq (%rsi,%rdx,8), %rdx
shrq $0x8, %rdx
cmpq %rcx, %rdx
jbe 0x93a9
retq
pushq %rax
leaq 0x1f6d4(%rip), %rdi     # 0x28ac1
leaq 0x1eec5(%rip), %rsi     # 0x282b9
leaq 0x1f33f(%rip), %rcx     # 0x2873a
movl $0x41b, %edx            # imm = 0x41B
callq 0x21a0
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/map.c
// Function: align_regs
static mm_reg1_t *align_regs(const mm_mapopt_t *opt, const mm_idx_t *mi, void *km, int qlen, const char *seq, int *n_regs, mm_reg1_t *regs, mm128_t *a)
{
	if (!(opt->flag & MM_F_CIGAR)) return regs;
	regs = mm_align_skeleton(km, opt, mi, qlen, seq, n_regs, regs, a); // this calls mm_filter_regs()
	if (!(opt->flag & MM_F_ALL_CHAINS)) { // don't choose primary mapping(s)
		mm_set_parent(km, opt->mask_level, opt->mask_len, *n_regs, regs, opt->a * 2 + opt->b, opt->flag&MM_F_HARD_MLEVEL, opt->alt_drop);
		mm_select_sub(km, opt->pri_ratio, mi->k*2, opt->best_n, 0, opt->max_gap * 0.8, n_regs, regs);
		mm_set_sam_pri(*n_regs, regs);
	}
	return regs;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq 0x30(%rsp), %rbx
testb $0x4, (%rdi)
je 0xb3c5
movq %r9, %r14
movq %rdx, %r15
movq %rsi, %r13
movq %rdi, %r12
movq %rdx, %rdi
movq %r12, %rsi
movq %r13, %rdx
pushq 0x38(%rsp)
pushq %rbx
callq 0x15162
popq %rcx
popq %rdx
movq %rax, %rbx
movq (%r12), %r9
btl $0x17, %r9d
jb 0xb3c5
movss 0x50(%r12), %xmm0
movl 0x54(%r12), %esi
movl (%r14), %edx
movl 0x64(%r12), %r8d
addl %r8d, %r8d
addl 0x68(%r12), %r8d
andl $0x20000000, %r9d       # imm = 0x20000000
movss 0x60(%r12), %xmm1
movq %r15, %rdi
movq %rbx, %rcx
callq 0x19686
movss 0x58(%r12), %xmm0
movl 0x8(%r13), %esi
addl %esi, %esi
movl 0x5c(%r12), %edx
cvtsi2sdl 0x1c(%r12), %xmm1
mulsd 0x1d3df(%rip), %xmm1    # 0x28780
cvttsd2si %xmm1, %r8d
subq $0x8, %rsp
movq %r15, %rdi
xorl %ecx, %ecx
movq %r14, %r9
pushq %rbx
callq 0x19dbc
popq %rax
popq %rcx
movl (%r14), %edi
movq %rbx, %rsi
callq 0x19c90
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/map.c
// Function: mm_map_frag
void mm_map_frag(const mm_idx_t *mi, int n_segs, const int *qlens, const char **seqs, int *n_regs, mm_reg1_t **regs, mm_tbuf_t *b, const mm_mapopt_t *opt, const char *qname)
{
	if ((opt->flag & MM_F_WEAK_PAIRING) && n_segs == 2 && opt->pe_ori >= 0 && (opt->flag&MM_F_CIGAR)) {
		int i;
		for (i = 0; i < n_segs; ++i)
			mm_map_frag_core(mi, 1, &qlens[i], &seqs[i], &n_regs[i], &regs[i], b, opt, qname);
		mm_pair(b->km, opt->max_gap_ref, opt->pe_bonus, opt->a * 2 + opt->b, opt->a, qlens, n_regs, regs);
	} else {
		mm_map_frag_core(mi, n_segs, qlens, seqs, n_regs, regs, b, opt, qname);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %r8, 0x10(%rsp)
movq %rcx, %r12
movq %rdx, 0x8(%rsp)
movq %rdi, 0x18(%rsp)
movq 0x68(%rsp), %rbp
movq (%rbp), %rax
btq $0x26, %rax
setae %cl
cmpl $0x2, %esi
setne %dl
orb %cl, %dl
jne 0xb474
testb $0x4, %al
je 0xb474
cmpl $0x0, 0xb8(%rbp)
js 0xb474
movq 0x70(%rsp), %r15
movq 0x60(%rsp), %rbx
xorl %r13d, %r13d
movq %r9, 0x20(%rsp)
movq %r9, %r14
cmpq $0x8, %r13
je 0xb499
movq 0x8(%rsp), %rax
leaq (%rax,%r13), %rdx
movq 0x10(%rsp), %rax
leaq (%rax,%r13), %r8
subq $0x8, %rsp
movq 0x20(%rsp), %rdi
pushq $0x1
popq %rsi
movq %r12, %rcx
movq %r14, %r9
pushq %r15
pushq %rbp
pushq %rbx
callq 0x9c7e
addq $0x20, %rsp
addq $0x4, %r13
addq $0x8, %r14
addq $0x8, %r12
jmp 0xb42f
movq 0x18(%rsp), %rdi
movq 0x8(%rsp), %rdx
movq %r12, %rcx
movq 0x10(%rsp), %r8
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x9c7e
movq (%rbx), %rdi
movl 0xbc(%rbp), %edx
movl 0x20(%rbp), %esi
movl 0x64(%rbp), %r8d
leal (%r8,%r8), %ecx
addl 0x68(%rbp), %ecx
movq 0x8(%rsp), %r9
pushq 0x20(%rsp)
pushq 0x18(%rsp)
callq 0xf826
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/map.c
// Function: mm_map_file_frag
int mm_map_file_frag(const mm_idx_t *idx, int n_segs, const char **fn, const mm_mapopt_t *opt, int n_threads)
{
	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.mi = idx;
	pl.n_threads = n_threads > 1? n_threads : 1;
	pl.mini_batch_size = opt->mini_batch_size;
	if (opt->split_prefix)
		pl.fp_split = mm_split_init(opt->split_prefix, idx);
	pl_threads = n_threads == 1? 1 : (opt->flag&MM_F_2_IO_THREADS)? 3 : 2;
	kt_pipeline(pl_threads, worker_pipeline, &pl, 3);

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

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x68, %rsp
pushq $-0x1
popq %r15
testl %esi, %esi
jle 0xb628
movl %r8d, %ebp
movq %rcx, %rbx
movq %rdi, %r14
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
movaps %xmm0, 0x50(%rsp)
movaps %xmm0, 0x40(%rsp)
movaps %xmm0, 0x30(%rsp)
movaps %xmm0, 0x20(%rsp)
movaps %xmm0, 0x10(%rsp)
andq $0x0, 0x60(%rsp)
movl %esi, 0x8(%rsp)
movl %esi, %edi
movq %rdx, %rsi
callq 0xb636
movq %rax, 0x20(%rsp)
testq %rax, %rax
je 0xb628
movq %rbx, 0x18(%rsp)
movq %r14, 0x28(%rsp)
cmpl $0x2, %ebp
pushq $0x1
popq %r15
movl %r15d, %eax
cmovgel %ebp, %eax
movl %eax, 0x4(%rsp)
movq 0xe8(%rbx), %rax
movq %rax, 0x10(%rsp)
movq 0x100(%rbx), %rdi
testq %rdi, %rdi
je 0xb5be
movq %r14, %rsi
callq 0x1014c
movq %rax, 0x58(%rsp)
cmpl $0x1, %ebp
je 0xb5d2
movb 0x1(%rbx), %al
andb $-0x80, %al
cmpb $0x1, %al
pushq $0x3
popq %r15
sbbl $0x0, %r15d
leaq 0x10c(%rip), %rsi       # 0xb6e5
movq %rsp, %rbx
pushq $0x3
popq %rcx
movl %r15d, %edi
movq %rbx, %rdx
callq 0x10711
movq 0x40(%rbx), %rdi
callq 0x2040
movq 0x58(%rbx), %rdi
testq %rdi, %rdi
je 0xb601
callq 0x2120
xorl %ebx, %ebx
movslq 0x8(%rsp), %rax
movq 0x20(%rsp), %rdi
cmpq %rax, %rbx
jge 0xb620
movq (%rdi,%rbx,8), %rdi
callq 0x1141b
incq %rbx
jmp 0xb603
callq 0x2040
xorl %r15d, %r15d
movl %r15d, %eax
addq $0x68, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/map.c
// Function: open_bseqs
static mm_bseq_file_t **open_bseqs(int n, const char **fn)
{
	mm_bseq_file_t **fp;
	int i, j;
	fp = (mm_bseq_file_t**)calloc(n, sizeof(mm_bseq_file_t*));
	for (i = 0; i < n; ++i) {
		if ((fp[i] = mm_bseq_open(fn[i])) == 0) {
			if (mm_verbose >= 1)
				fprintf(stderr, "ERROR: failed to open file '%s': %s\n", fn[i], strerror(errno));
			for (j = 0; j < i; ++j)
				mm_bseq_close(fp[j]);
			free(fp);
			return 0;
		}
	}
	return fp;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movl %edi, %r15d
movl %edi, %edi
pushq $0x8
popq %rsi
callq 0x2230
movq %rax, %rbx
xorl %r12d, %r12d
testl %r15d, %r15d
cmovlel %r12d, %r15d
cmpq %r12, %r15
je 0xb6a3
movq (%r14,%r12,8), %rdi
callq 0x113b6
movq %rax, (%rbx,%r12,8)
testq %rax, %rax
je 0xb677
incq %r12
jmp 0xb65b
leaq 0x27082(%rip), %rax     # 0x32700
cmpl $0x0, (%rax)
jg 0xb6b2
xorl %r14d, %r14d
cmpq %r14, %r12
je 0xb699
movq (%rbx,%r14,8), %rdi
callq 0x1141b
incq %r14
jmp 0xb686
movq %rbx, %rdi
callq 0x2040
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq 0x2693f(%rip), %rax     # 0x31ff8
movq (%rax), %r15
movq (%r14,%r12,8), %r14
callq 0x2060
movl (%rax), %edi
callq 0x2420
leaq 0x1d21f(%rip), %rsi     # 0x288f2
movq %r15, %rdi
movq %r14, %rdx
movq %rax, %rcx
xorl %eax, %eax
callq 0x2260
jmp 0xb683
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/map.c
// Function: skip_seed
static inline int skip_seed(int flag, uint64_t r, const mm_seed_t *q, const char *qname, int qlen, const mm_idx_t *mi, int *is_self)
{
	*is_self = 0;
	if (qname && (flag & (MM_F_NO_DIAG|MM_F_NO_DUAL))) {
		const mm_idx_seq_t *s = &mi->seq[r>>32];
		int cmp;
		cmp = strcmp(qname, s->name);
		if ((flag&MM_F_NO_DIAG) && cmp == 0 && (int)s->len == qlen) {
			if ((uint32_t)r>>1 == (q->q_pos>>1)) return 1; // avoid the diagnonal anchors
			if ((r&1) == (q->q_pos&1)) *is_self = 1; // this flag is used to avoid spurious extension on self chain
		}
		if ((flag&MM_F_NO_DUAL) && cmp > 0) // all-vs-all mode: map once
			return 1;
	}
	if (flag & (MM_F_FOR_ONLY|MM_F_REV_ONLY)) {
		if ((r&1) == (q->q_pos&1)) { // forward strand
			if (flag & MM_F_REV_ONLY) return 1;
		} else {
			if (flag & MM_F_FOR_ONLY) return 1;
		}
	}
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbp
movq %rsi, %r14
movq 0x40(%rsp), %rax
andl $0x0, (%rax)
testq %rcx, %rcx
sete %al
movl %edi, %r12d
testb $0x3, %r12b
sete %sil
orb %al, %sil
pushq $0x1
popq %rbx
je 0xc661
testl $0x300000, %r12d        # imm = 0x300000
je 0xc6d8
andl $0x1, %r14d
movl 0x4(%rbp), %eax
andl $0x1, %eax
cmpl %eax, %r14d
jne 0xc6d1
btl $0x15, %r12d
jae 0xc6d8
jmp 0xc6da
movl %r8d, 0x4(%rsp)
movq 0x20(%r9), %r13
movq %r14, %rax
shrq $0x20, %rax
imulq $0x18, %rax, %r15
movq (%r13,%r15), %rsi
movq %rcx, %rdi
callq 0x2240
testb $0x1, %r12b
je 0xc6be
testl %eax, %eax
jne 0xc6be
addq %r15, %r13
movl 0x4(%rsp), %ecx
cmpl %ecx, 0x10(%r13)
jne 0xc6be
movl 0x4(%rbp), %ecx
movl %ecx, %esi
xorl %r14d, %esi
cmpl $0x2, %esi
jb 0xc6da
movl %r14d, %esi
andl $0x1, %esi
andl $0x1, %ecx
cmpl %ecx, %esi
jne 0xc6be
movq 0x40(%rsp), %rcx
movl $0x1, (%rcx)
testb $0x2, %r12b
je 0xc63c
testl %eax, %eax
jg 0xc6da
jmp 0xc63c
btl $0x14, %r12d
jb 0xc6da
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/./bseq.h
// Function: mm_revcomp_bseq
static inline void mm_revcomp_bseq(mm_bseq1_t *s)
{
	int i, t, l = s->l_seq;
	for (i = 0; i < l>>1; ++i) {
		t = s->seq[l - i - 1];
		s->seq[l - i - 1] = seq_comp_table[(uint8_t)s->seq[i]];
		s->seq[i] = seq_comp_table[t];
	}
	if (l&1) s->seq[l>>1] = seq_comp_table[(uint8_t)s->seq[l>>1]];
	if (s->qual)
		for (i = 0; i < l>>1; ++i)
			t = s->qual[l - i - 1], s->qual[l - i - 1] = s->qual[i], s->qual[i] = t;
}

// Assembly:
pushq %rbx
movl (%rdi), %eax
movl %eax, %edx
sarl %edx
xorl %r8d, %r8d
testl %edx, %edx
movl $0x0, %ecx
cmovgl %edx, %ecx
leal -0x1(%rax), %r9d
leaq 0x25c05(%rip), %rsi     # 0x32710
cmpq %r8, %rcx
je 0xcb3c
movq 0x10(%rdi), %r10
movslq %r9d, %r9
movsbq (%r10,%r9), %r11
movzbl (%r10,%r8), %ebx
movb (%rsi,%rbx), %bl
movb %bl, (%r10,%r9)
movb (%rsi,%r11), %r10b
movq 0x10(%rdi), %r11
movb %r10b, (%r11,%r8)
incq %r8
decl %r9d
jmp 0xcb0b
testb $0x1, %al
je 0xcb54
movq 0x10(%rdi), %r8
movslq %edx, %rdx
movzbl (%r8,%rdx), %r9d
movb (%rsi,%r9), %sil
movb %sil, (%r8,%rdx)
cmpq $0x0, 0x18(%rdi)
je 0xcb85
decl %eax
xorl %edx, %edx
cmpq %rdx, %rcx
je 0xcb85
movq 0x18(%rdi), %rsi
cltq
movb (%rsi,%rax), %r8b
movb (%rsi,%rdx), %r9b
movb %r9b, (%rsi,%rax)
movq 0x18(%rdi), %rsi
movb %r8b, (%rsi,%rdx)
incq %rdx
decl %eax
jmp 0xcb5f
popq %rbx
retq
nop
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/format.c
// Function: mm_gen_cs_or_MD
int mm_gen_cs_or_MD(void *km, char **buf, int *max_len, const mm_idx_t *mi, const mm_reg1_t *r, const char *seq, int is_MD, int no_iden, int is_qstrand)
{
	mm_bseq1_t t;
	kstring_t str;
	str.s = *buf, str.l = 0, str.m = *max_len;
	t.l_seq = strlen(seq);
	t.seq = (char*)seq;
	write_cs_ds_or_MD(km, &str, mi, &t, r, no_iden, is_MD, 0, 0, is_qstrand);
	*max_len = str.m;
	*buf = str.s;
	return str.l;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %r9, %r12
movq %r8, (%rsp)
movq %rcx, %rbp
movq %rdx, %r14
movq %rsi, %rbx
movq %rdi, %r13
movq (%rsi), %rax
leaq 0x8(%rsp), %r15
movq %rax, 0x10(%r15)
andq $0x0, (%r15)
movslq (%rdx), %rax
movq %rax, 0x8(%r15)
movq %r9, %rdi
callq 0x2130
leaq 0x20(%rsp), %rcx
movl %eax, (%rcx)
movq %r12, 0x10(%rcx)
movq %r13, %rdi
movq %r15, %rsi
movq %rbp, %rdx
movq (%rsp), %r8
movl 0x88(%rsp), %r9d
movl 0x90(%rsp), %eax
pushq %rax
pushq $0x0
pushq $0x0
movl 0x98(%rsp), %eax
pushq %rax
callq 0xd4c5
addq $0x20, %rsp
movl 0x8(%r15), %eax
movl %eax, (%r14)
movq 0x10(%r15), %rax
movq %rax, (%rbx)
movl (%r15), %eax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/format.c
// Function: get_sam_pri
static inline const mm_reg1_t *get_sam_pri(int n_regs, const mm_reg1_t *regs)
{
	int i;
	for (i = 0; i < n_regs; ++i)
		if (regs[i].sam_pri)
			return &regs[i];
	assert(n_regs == 0);
	return NULL;
}

// Assembly:
pushq %rax
xorl %ecx, %ecx
testl %edi, %edi
cmovgl %edi, %ecx
incq %rcx
addq $-0x50, %rsi
decq %rcx
je 0xed62
leaq 0x50(%rsi), %rax
testb $0x10, 0x8d(%rsi)
movq %rax, %rsi
je 0xed4b
jmp 0xed68
testl %edi, %edi
jne 0xed6a
xorl %eax, %eax
popq %rcx
retq
leaq 0x1a129(%rip), %rdi     # 0x28e9a
leaq 0x19cac(%rip), %rsi     # 0x28a24
leaq 0x1a127(%rip), %rcx     # 0x28ea6
movl $0x1e0, %edx            # imm = 0x1E0
callq 0x21a0
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/format.c
// Function: sam_write_sq
static void sam_write_sq(kstring_t *s, char *seq, int l, int rev, int comp)
{
	extern unsigned char seq_comp_table[256];
	if (rev) {
		int i;
		str_enlarge(s, l);
		for (i = 0; i < l; ++i) {
			int c = seq[l - 1 - i];
			s->s[s->l + i] = c < 128 && comp? seq_comp_table[c] : c;
		}
		s->l += l;
	} else str_copy(s, seq, seq + l);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %r15d
movq %rsi, %r14
movq %rdi, %rbx
testl %ecx, %ecx
je 0xf003
movl %r8d, %ebp
movq %rbx, %rdi
movl %r15d, %esi
callq 0xf0cd
xorl %eax, %eax
testl %r15d, %r15d
movl $0x0, %ecx
cmovgl %r15d, %ecx
leal -0x1(%r15), %edx
leaq 0x23748(%rip), %rsi     # 0x32710
cmpq %rax, %rcx
je 0xeff2
movslq %edx, %rdi
movb (%r14,%rdi), %dil
testl %ebp, %ebp
je 0xefe0
movsbq %dil, %rdi
movb (%rsi,%rdi), %dil
movq 0x10(%rbx), %r8
addq (%rbx), %r8
movb %dil, (%rax,%r8)
incq %rax
decl %edx
jmp 0xefc8
movslq %r15d, %rax
addq %rax, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movslq %r15d, %rdx
addq %r14, %rdx
movq %rbx, %rdi
movq %r14, %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0xf09a
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/format.c
// Function: write_indel_ds
static void write_indel_ds(kstring_t *str, int64_t len, const uint8_t *seq, int64_t ll, int64_t lr) // write an indel to ds; adapted from minigraph
{
	int64_t i;
	if (ll + lr >= len) {
		mm_sprintf_lite(str, "[");
		for (i = 0; i < len; ++i)
			mm_sprintf_lite(str, "%c", "acgtn"[seq[i]]);
		mm_sprintf_lite(str, "]");
	} else {
		int64_t k = 0;
		if (ll > 0) {
			mm_sprintf_lite(str, "[");
			for (i = 0; i < ll; ++i)
				mm_sprintf_lite(str, "%c", "acgtn"[seq[k+i]]);
			mm_sprintf_lite(str, "]");
			k += ll;
		}
		for (i = 0; i < len - lr - ll; ++i)
			mm_sprintf_lite(str, "%c", "acgtn"[seq[k+i]]);
		k += len - lr - ll;
		if (lr > 0) {
			mm_sprintf_lite(str, "[");
			for (i = 0; i < lr; ++i)
				mm_sprintf_lite(str, "%c", "acgtn"[seq[k+i]]);
			mm_sprintf_lite(str, "]");
		}
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %r12
movq %rdx, %r14
movq %rdi, %rbx
leaq (%r8,%rcx), %rax
movq %rsi, %rcx
subq %rax, %rcx
jle 0xf1a6
testq %r12, %r12
movq %r8, 0x10(%rsp)
movq %rcx, 0x8(%rsp)
jle 0xf211
leaq 0x19cba(%rip), %rsi     # 0x28e25
movq %rbx, %rdi
xorl %eax, %eax
callq 0xce8e
leaq 0x19c8d(%rip), %rbp     # 0x28e09
leaq 0x19912(%rip), %r13     # 0x28a95
xorl %r15d, %r15d
cmpq %r15, %r12
je 0xf1f9
movzbl (%r14,%r15), %eax
movsbl (%rax,%rbp), %edx
movq %rbx, %rdi
movq %r13, %rsi
xorl %eax, %eax
callq 0xce8e
incq %r15
jmp 0xf186
movq %rsi, %r13
leaq 0x19c75(%rip), %rsi     # 0x28e25
xorl %r15d, %r15d
movq %rbx, %rdi
xorl %eax, %eax
callq 0xce8e
testq %r13, %r13
cmovleq %r15, %r13
leaq 0x19c3e(%rip), %r12     # 0x28e09
leaq 0x198c3(%rip), %r15     # 0x28a95
xorl %ebp, %ebp
cmpq %rbp, %r13
je 0xf2a0
movzbl (%r14,%rbp), %eax
movsbl (%rax,%r12), %edx
movq %rbx, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0xce8e
incq %rbp
jmp 0xf1d4
leaq 0x19c27(%rip), %rsi     # 0x28e27
movq %rbx, %rdi
xorl %eax, %eax
callq 0xce8e
movq 0x8(%rsp), %rcx
jmp 0xf214
xorl %r12d, %r12d
addq %r12, %r14
testq %rcx, %rcx
movl $0x0, %ebp
cmovgq %rcx, %rbp
leaq 0x19bdf(%rip), %r13     # 0x28e09
leaq 0x19864(%rip), %r12     # 0x28a95
xorl %r15d, %r15d
cmpq %r15, %rbp
je 0xf255
movzbl (%r14,%r15), %eax
movsbl (%rax,%r13), %edx
movq %rbx, %rdi
movq %r12, %rsi
xorl %eax, %eax
callq 0xce8e
incq %r15
jmp 0xf234
movq 0x10(%rsp), %rbp
testq %rbp, %rbp
jle 0xf2bf
leaq 0x19bbf(%rip), %rsi     # 0x28e25
movq %rbx, %rdi
xorl %eax, %eax
callq 0xce8e
addq 0x8(%rsp), %r14
leaq 0x19819(%rip), %r12     # 0x28a95
xorl %r15d, %r15d
cmpq %r15, %rbp
je 0xf2a0
movzbl (%r14,%r15), %eax
movsbl (%rax,%r13), %edx
movq %rbx, %rdi
movq %r12, %rsi
xorl %eax, %eax
callq 0xce8e
incq %r15
jmp 0xf27f
leaq 0x19b80(%rip), %rsi     # 0x28e27
movq %rbx, %rdi
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xce8e
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/pe.c
// Function: mm_set_pe_thru
void mm_set_pe_thru(const int *qlens, int *n_regs, mm_reg1_t **regs)
{
	int s, i, n_pri[2], pri[2];
	n_pri[0] = n_pri[1] = 0;
	pri[0] = pri[1] = -1;
	for (s = 0; s < 2; ++s)
		for (i = 0; i < n_regs[s]; ++i)
			if (regs[s][i].id == regs[s][i].parent)
				++n_pri[s], pri[s] = i;
	if (n_pri[0] == 1 && n_pri[1] == 1) {
		mm_reg1_t *p = &regs[0][pri[0]];
		mm_reg1_t *q = &regs[1][pri[1]];
		if (p->rid == q->rid && p->rev == q->rev && abs(p->rs - q->rs) < 3 && abs(p->re - q->re) < 3
			&& ((p->qs == 0 && qlens[1] - q->qe == 0) || (q->qs == 0 && qlens[0] - p->qe == 0)))
		{
			p->pe_thru = q->pe_thru = 1;
		}
	}
}

// Assembly:
pushq %rbp
pushq %rbx
andq $0x0, -0x8(%rsp)
orq $-0x1, -0x10(%rsp)
xorl %eax, %eax
movabsq $0x20, %rcx
xorl %r8d, %r8d
cmpq $0x2, %r8
je 0xf505
movl (%rsi,%r8,4), %r9d
testl %r9d, %r9d
cmovlel %eax, %r9d
movq %rcx, %r10
xorl %r11d, %r11d
cmpq %r11, %r9
je 0xf500
movq (%rdx,%r8,8), %rbx
movl -0x20(%rbx,%r10), %ebp
cmpl (%rbx,%r10), %ebp
jne 0xf4f7
incl -0x8(%rsp,%r8,4)
movl %r11d, -0x10(%rsp,%r8,4)
incq %r11
addq $0x50, %r10
jmp 0xf4d9
incq %r8
jmp 0xf4c2
cmpl $0x1, -0x8(%rsp)
jne 0xf5a8
cmpl $0x1, -0x4(%rsp)
jne 0xf5a8
movslq -0x10(%rsp), %rax
imulq $0x50, %rax, %rsi
movq (%rdx), %rax
movq 0x8(%rdx), %rcx
movslq -0xc(%rsp), %rdx
imulq $0x50, %rdx, %rdx
movl 0x8(%rax,%rsi), %r8d
cmpl 0x8(%rcx,%rdx), %r8d
jne 0xf5a8
addq %rsi, %rax
addq %rdx, %rcx
movl 0x3c(%rcx), %edx
movl 0x3c(%rax), %esi
xorl %edx, %esi
btl $0xa, %esi
jb 0xf5a8
movl 0x18(%rax), %esi
subl 0x18(%rcx), %esi
movl %esi, %r8d
negl %r8d
cmovsl %esi, %r8d
cmpl $0x2, %r8d
ja 0xf5a8
movl 0x1c(%rax), %esi
subl 0x1c(%rcx), %esi
movl %esi, %r8d
negl %r8d
cmovsl %esi, %r8d
cmpl $0x2, %r8d
ja 0xf5a8
cmpl $0x0, 0x10(%rax)
jne 0xf58e
movl 0x4(%rdi), %esi
cmpl 0x14(%rcx), %esi
je 0xf59b
cmpl $0x0, 0x10(%rcx)
jne 0xf5a8
movl (%rdi), %esi
cmpl 0x14(%rax), %esi
jne 0xf5a8
orl $0x4000, %edx           # imm = 0x4000
movl %edx, 0x3c(%rcx)
orb $0x40, 0x3d(%rax)
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/esterr.c
// Function: get_for_qpos
static inline int32_t get_for_qpos(int32_t qlen, const mm128_t *a)
{
	int32_t x = (int32_t)a->y;
	int32_t q_span = a->y>>32 & 0xff;
	if (a->x>>63)
		x = qlen - 1 - (x + 1 - q_span); // revert the position to the forward strand of query
	return x;
}

// Assembly:
movq 0x8(%rsi), %rax
cmpq $0x0, (%rsi)
js 0x10135
retq
movq %rax, %rcx
shrq $0x20, %rcx
movzbl %cl, %ecx
notl %eax
addl %eax, %edi
leal (%rcx,%rdi), %eax
decl %eax
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/splitidx.c
// Function: mm_split_init
FILE *mm_split_init(const char *prefix, const mm_idx_t *mi)
{
	char *fn;
	FILE *fp;
	uint32_t i, k = mi->k;
	fn = (char*)calloc(strlen(prefix) + 10, 1);
	sprintf(fn, "%s.%.4d.tmp", prefix, mi->index);
	if ((fp = fopen(fn, "wb")) == NULL) {
		if (mm_verbose >= 1)
			fprintf(stderr, "[ERROR]\033[1;31m failed to write to temporary file '%s'\033[0m: %s\n", fn, strerror(errno));
		exit(1);
	}
	mm_err_fwrite(&k, 4, 1, fp);
	mm_err_fwrite(&mi->n_seq, 4, 1, fp);
	for (i = 0; i < mi->n_seq; ++i) {
		uint32_t l;
		l = strlen(mi->seq[i].name);
		mm_err_fwrite(&l, 1, 4, fp);
		mm_err_fwrite(mi->seq[i].name, 1, l, fp);
		mm_err_fwrite(&mi->seq[i].len, 4, 1, fp);
	}
	free(fn);
	return fp;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movl 0x8(%rsi), %eax
movl %eax, 0x4(%rsp)
callq 0x2130
leaq 0xa(%rax), %rdi
pushq $0x1
popq %rsi
callq 0x2230
movq %rax, %r15
movl 0x14(%r14), %ecx
leaq 0x18e75(%rip), %rsi     # 0x28ffb
movq %rax, %rdi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x23d0
leaq 0x16213(%rip), %rsi     # 0x263ad
movq %r15, 0x8(%rsp)
movq %r15, %rdi
callq 0x2390
testq %rax, %rax
je 0x1026c
movq %rax, %r15
leaq 0x4(%rsp), %rdi
pushq $0x4
popq %rbx
pushq $0x1
popq %r13
movq %rbx, %rsi
movq %r13, %rdx
movq %rax, %rcx
callq 0x4571
leaq 0x10(%r14), %rdi
movq %rdi, 0x10(%rsp)
movq %rbx, %rsi
movq %r13, %rdx
movq %r15, %rcx
callq 0x4571
pushq $0x10
popq %rbx
xorl %r12d, %r12d
pushq $0x4
popq %rbp
movq 0x10(%rsp), %rax
movl (%rax), %eax
cmpq %rax, %r12
jae 0x10250
movq 0x20(%r14), %rax
movq -0x10(%rax,%rbx), %rdi
callq 0x2130
movl %eax, (%rsp)
movq %rsp, %rdi
movq %r13, %rsi
movq %rbp, %rdx
movq %r15, %rcx
callq 0x4571
movq 0x20(%r14), %rax
movq -0x10(%rax,%rbx), %rdi
movl (%rsp), %edx
movq %r13, %rsi
movq %r15, %rcx
callq 0x4571
movq 0x20(%r14), %rdi
addq %rbx, %rdi
movq %rbp, %rsi
movq %r13, %rdx
movq %r15, %rcx
callq 0x4571
incq %r12
addq $0x18, %rbx
jmp 0x101ed
movq 0x8(%rsp), %rdi
callq 0x2040
movq %r15, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x2248d(%rip), %rax     # 0x32700
cmpl $0x0, (%rax)
jle 0x102a7
movq 0x21d79(%rip), %rax     # 0x31ff8
movq (%rax), %rbx
callq 0x2060
movl (%rax), %edi
callq 0x2420
leaq 0x18d72(%rip), %rsi     # 0x29007
movq %rbx, %rdi
movq 0x8(%rsp), %rdx
movq %rax, %rcx
xorl %eax, %eax
callq 0x2260
pushq $0x1
popq %rdi
callq 0x23e0
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/splitidx.c
// Function: mm_split_rm_tmp
void mm_split_rm_tmp(const char *prefix, int n_splits)
{
	int i;
	char *fn;
	fn = CALLOC(char, strlen(prefix) + 10);
	for (i = 0; i < n_splits; ++i) {
		sprintf(fn, "%s.%.4d.tmp", prefix, i);
		remove(fn);
	}
	free(fn);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %esi, %ebx
movq %rdi, %r14
callq 0x2130
leaq 0xa(%rax), %rdi
pushq $0x1
popq %rsi
callq 0x2230
movq %rax, %r15
xorl %eax, %eax
testl %ebx, %ebx
cmovlel %eax, %ebx
leaq 0x18ada(%rip), %r12     # 0x28ffb
xorl %ebp, %ebp
cmpl %ebp, %ebx
je 0x10545
movq %r15, %rdi
movq %r12, %rsi
movq %r14, %rdx
movl %ebp, %ecx
xorl %eax, %eax
callq 0x23d0
movq %r15, %rdi
callq 0x2070
incl %ebp
jmp 0x10523
movq %r15, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x2040
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/bseq.c
// Function: mm_bseq_open
mm_bseq_file_t *mm_bseq_open(const char *fn)
{
	mm_bseq_file_t *fp;
	gzFile f;
	f = fn && strcmp(fn, "-")? gzopen(fn, "r") : gzdopen(0, "r");
	if (f == 0) return 0;
	fp = (mm_bseq_file_t*)calloc(1, sizeof(mm_bseq_file_t));
	fp->fp = f;
	fp->ks = kseq_init(fp->fp);
	return fp;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
testq %rdi, %rdi
je 0x113d8
cmpb $0x2d, (%rdi)
jne 0x113ca
cmpb $0x0, 0x1(%rdi)
je 0x113d8
leaq 0x168aa(%rip), %rsi     # 0x27c7b
callq 0x2350
jmp 0x113e6
leaq 0x1689c(%rip), %rsi     # 0x27c7b
xorl %edi, %edi
callq 0x20f0
movq %rax, %rbx
testq %rax, %rax
je 0x1140d
pushq $0x1
popq %rdi
pushq $0x38
popq %rsi
callq 0x2230
movq %rax, %r14
movq %rbx, (%rax)
movq %rbx, %rdi
callq 0x110ea
movq %rax, 0x8(%r14)
jmp 0x11410
xorl %r14d, %r14d
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/bseq.c
// Function: mm_bseq_read_frag2
mm_bseq1_t *mm_bseq_read_frag2(int n_fp, mm_bseq_file_t **fp, int64_t chunk_size, int with_qual, int with_comment, int *n_)
{
	int i;
	int64_t size = 0;
	kvec_t(mm_bseq1_t) a = {0,0,0};
	*n_ = 0;
	if (n_fp < 1) return 0;
	while (1) {
		int n_read = 0;
		for (i = 0; i < n_fp; ++i)
			if (kseq_read(fp[i]->ks) >= 0)
				++n_read;
		if (n_read < n_fp) {
			if (n_read > 0)
				fprintf(stderr, "[W::%s]\033[1;31m query files have different number of records; extra records skipped.\033[0m\n", __func__);
			break; // some file reaches the end
		}
		if (a.m == 0) kv_resize(mm_bseq1_t, 0, a, 256);
		for (i = 0; i < n_fp; ++i) {
			mm_bseq1_t *s;
			kv_pushp(mm_bseq1_t, 0, a, &s);
			kseq2bseq(fp[i]->ks, s, with_qual, with_comment);
			size += s->l_seq;
		}
		if (size >= chunk_size) break;
	}
	*n_ = a.n;
	return a.a;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movl %r8d, 0x14(%rsp)
movl %ecx, 0x10(%rsp)
movq %rdx, 0x28(%rsp)
movq %rsi, 0x18(%rsp)
andl $0x0, (%r9)
testl %edi, %edi
jle 0x1192d
movq %r9, 0x20(%rsp)
movl %edi, 0xc(%rsp)
movl %edi, %eax
movq %rax, 0x40(%rsp)
addq %rax, %rax
movq %rax, 0x38(%rsp)
xorl %r15d, %r15d
xorl %r12d, %r12d
xorl %ebp, %ebp
xorl %r14d, %r14d
xorl %r13d, %r13d
xorl %ebx, %ebx
cmpq %r13, 0x40(%rsp)
je 0x11888
movq 0x18(%rsp), %rax
movq (%rax,%r13,8), %rax
movq 0x8(%rax), %rdi
callq 0x11156
notl %eax
shrl $0x1f, %eax
addl %eax, %ebx
incq %r13
jmp 0x11863
cmpl 0xc(%rsp), %ebx
jl 0x11932
testq %rbp, %rbp
jne 0x118ae
movl $0x2800, %edx           # imm = 0x2800
xorl %edi, %edi
movq %r14, %rsi
callq 0x10c04
movq %rax, %r14
movl $0x100, %ebp            # imm = 0x100
leaq (%r12,%r12), %rax
movq %rax, 0x30(%rsp)
imulq $0x28, %r12, %rbx
xorl %r13d, %r13d
cmpq %r13, 0x38(%rsp)
je 0x11920
cmpq %rbp, %r12
jne 0x118ee
movq 0x30(%rsp), %rax
leaq (%rax,%r13), %rbp
testq %r12, %r12
pushq $0x2
popq %rax
cmoveq %rax, %rbp
imulq $0x28, %rbp, %rdx
xorl %edi, %edi
movq %r14, %rsi
callq 0x10c04
movq %rax, %r14
incq %r12
leaq (%r14,%rbx), %rsi
movq 0x18(%rsp), %rax
movq (%rax,%r13,4), %rax
movq 0x8(%rax), %rdi
movl 0x10(%rsp), %edx
movl 0x14(%rsp), %ecx
callq 0x1172d
movslq (%r14,%rbx), %rax
addq %rax, %r15
addq $0x2, %r13
addq $0x28, %rbx
jmp 0x118be
cmpq 0x28(%rsp), %r15
jl 0x1185e
jmp 0x11936
xorl %r14d, %r14d
jmp 0x1193e
testl %ebx, %ebx
jne 0x11950
movq 0x20(%rsp), %rax
movl %r12d, (%rax)
movq %r14, %rax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x206a1(%rip), %rax     # 0x31ff8
movq (%rax), %rdi
leaq 0x17946(%rip), %rsi     # 0x292a7
leaq 0x17998(%rip), %rdx     # 0x29300
xorl %eax, %eax
callq 0x2260
jmp 0x11936
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/sdust.c
// Function: sdust_buf_init
sdust_buf_t *sdust_buf_init(void *km)
{
	sdust_buf_t *buf;
	buf = (sdust_buf_t*)kcalloc(km, 1, sizeof(sdust_buf_t));
	buf->km = km;
	buf->w = kdq_init(int, buf->km);
	kdq_resize(int, buf->w, 8);
	return buf;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
pushq $0x1
popq %r15
pushq $0x40
popq %rdx
movq %r15, %rsi
callq 0x10980
movq %rax, %r14
movq %rbx, 0x38(%rax)
pushq $0x28
popq %rdx
movq %rbx, %rdi
movq %r15, %rsi
callq 0x10980
movq %rax, %r15
movabsq $0x3ffffffffffffff, %rax # imm = 0x3FFFFFFFFFFFFFF
andq (%r15), %rax
btsq $0x3b, %rax
movq %rax, (%r15)
movq $0x3, 0x10(%r15)
pushq $0x10
popq %rsi
movq %rbx, %rdi
callq 0x10afc
movq %rax, 0x18(%r15)
movq %rbx, 0x20(%r15)
movq %r15, (%r14)
pushq $0x8
popq %rsi
movq %r15, %rdi
callq 0x1239a
movq %r14, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/sdust.c
// Function: sdust
uint64_t *sdust(void *km, const uint8_t *seq, int l_seq, int T, int W, int *n)
{
	uint64_t *ret;
	sdust_buf_t *buf;
	buf = sdust_buf_init(km);
	ret = (uint64_t*)sdust_core(seq, l_seq, T, W, n, buf);
	buf->res.a = 0;
	sdust_buf_destroy(buf);
	return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r9, %rbx
movl %r8d, %ebp
movl %ecx, %r14d
movl %edx, %r15d
movq %rsi, %r12
callq 0x12324
movq %rax, %r13
movq %r12, %rdi
movl %r15d, %esi
movl %r14d, %edx
movl %ebp, %ecx
movq %rbx, %r8
movq %rax, %r9
callq 0x12532
movq %rax, %rbx
andq $0x0, 0x30(%r13)
movq %r13, %rdi
callq 0x124d7
movq %rbx, %rax
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]minimap2/lchain.c
// Function: comput_sc_simple
static inline int32_t comput_sc_simple(const mm128_t *ai, const mm128_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 0x14d9b
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 0x14df1
cvtsi2ss %esi, %xmm0
cvtsi2ss %r8d, %xmm2
mulss %xmm1, %xmm2
mulss %xmm0, %xmm3
addss %xmm2, %xmm3
xorps %xmm0, %xmm0
cmpl %eax, %edi
je 0x14ddf
incl %esi
cvtsi2ss %esi, %xmm0
movss %xmm3, 0xc(%rsp)
callq 0x14df9
movss 0xc(%rsp), %xmm3
mulss 0x145f1(%rip), %xmm0    # 0x293d8
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]minimap2/align.c
// Function: mm_enlarge_cigar
void mm_enlarge_cigar(mm_reg1_t *r, uint32_t n_cigar) // TODO: this calls the libc realloc()
{
	if (n_cigar == 0) return;
	if (r->p == 0) {
		uint32_t capacity = n_cigar + sizeof(mm_extra_t)/4;
		kroundup32(capacity);
		r->p = (mm_extra_t*)calloc(capacity, 4);
		r->p->capacity = capacity;
	} else if (r->p->n_cigar + n_cigar + sizeof(mm_extra_t)/4 > r->p->capacity) {
		r->p->capacity = r->p->n_cigar + n_cigar + sizeof(mm_extra_t)/4;
		kroundup32(r->p->capacity);
		r->p = (mm_extra_t*)realloc(r->p, r->p->capacity * 4);
	}
}

// Assembly:
testl %esi, %esi
je 0x14ee5
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x48(%rdi), %rdi
testq %rdi, %rdi
je 0x14ea1
addl 0x18(%rdi), %esi
addq $0x7, %rsi
movl (%rdi), %eax
cmpq %rax, %rsi
jbe 0x14ede
decl %esi
movl %esi, %eax
shrl %eax
orl %esi, %eax
movl %eax, %ecx
shrl $0x2, %ecx
orl %eax, %ecx
movl %ecx, %eax
shrl $0x4, %eax
orl %ecx, %eax
movl %eax, %ecx
shrl $0x8, %ecx
orl %eax, %ecx
movl %ecx, %eax
shrl $0x10, %eax
orl %ecx, %eax
leal 0x1(%rax), %ecx
movl %ecx, (%rdi)
leal 0x4(,%rax,4), %esi
callq 0x2320
movq %rax, 0x48(%rbx)
jmp 0x14ede
addl $0x6, %esi
movl %esi, %eax
shrl %eax
orl %esi, %eax
movl %eax, %ecx
shrl $0x2, %ecx
orl %eax, %ecx
movl %ecx, %eax
shrl $0x4, %eax
orl %ecx, %eax
movl %eax, %ecx
shrl $0x8, %ecx
orl %eax, %ecx
movl %ecx, %r14d
shrl $0x10, %r14d
orl %ecx, %r14d
incl %r14d
pushq $0x4
popq %rsi
movq %r14, %rdi
callq 0x2230
movq %rax, 0x48(%rbx)
movl %r14d, (%rax)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/align.c
// Function: mm_event_identity
double mm_event_identity(const mm_reg1_t *r)
{
	int32_t n_gap, n_gapo;
	if (r->p == 0) return -1.0f;
	mm_count_gaps(r, &n_gap, &n_gapo);
	return (double)r->mlen / (r->blen + r->p->n_ambi - n_gap + n_gapo);
}

// Assembly:
movq 0x48(%rdi), %rax
testq %rax, %rax
je 0x14f44
movl 0x18(%rax), %esi
xorl %r8d, %r8d
xorl %r9d, %r9d
xorl %edx, %edx
xorl %ecx, %ecx
cmpq %r9, %rsi
je 0x14f27
movl 0x1c(%rax,%r9,4), %r10d
movl %r10d, %r11d
andl $0xf, %r11d
decl %r11d
shrl $0x4, %r10d
cmpl $0x2, %r11d
cmovael %r8d, %r10d
adcl $0x0, %ecx
addl %r10d, %edx
incq %r9
jmp 0x14efc
cvtsi2sdl 0x2c(%rdi), %xmm0
movl $0x3fffffff, %esi       # imm = 0x3FFFFFFF
andl 0x14(%rax), %esi
subl %edx, %ecx
addl 0x30(%rdi), %ecx
addl %esi, %ecx
cvtsi2sd %ecx, %xmm1
divsd %xmm1, %xmm0
retq
movsd 0x1464c(%rip), %xmm0    # 0x29598
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/align.c
// Function: mm_insert_reg
static inline mm_reg1_t *mm_insert_reg(const mm_reg1_t *r, int i, int *n_regs, mm_reg1_t *regs)
{
	regs = (mm_reg1_t*)realloc(regs, (*n_regs + 1) * sizeof(mm_reg1_t));
	if (i + 1 != *n_regs)
		memmove(&regs[i + 2], &regs[i + 1], sizeof(mm_reg1_t) * (*n_regs - i - 1));
	regs[i + 1] = *r;
	++*n_regs;
	return regs;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movl %esi, %r12d
movq %rdi, %r14
movslq (%rdx), %rax
imulq $0x50, %rax, %rsi
addq $0x50, %rsi
movq %rcx, %rdi
callq 0x2320
movq %rax, %r15
leal 0x1(%r12), %eax
movl (%rbx), %ebp
cmpl %ebp, %eax
jne 0x17f5b
movslq %eax, %r13
jmp 0x17f89
movslq %r12d, %rcx
imulq $0x50, %rcx, %rcx
leaq (%r15,%rcx), %rdi
addq $0xa0, %rdi
movslq %eax, %r13
imulq $0x50, %r13, %rsi
addq %r15, %rsi
notl %r12d
addl %ebp, %r12d
movslq %r12d, %rax
imulq $0x50, %rax, %rdx
callq 0x2340
imulq $0x50, %r13, %rax
movq %r15, %rdi
addq %rax, %rdi
pushq $0xa
popq %rcx
movq %r14, %rsi
rep  movsq (%rsi), %es:(%rdi)
incl %ebp
movl %ebp, (%rbx)
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/lh3[P]minimap2/align.c
// Function: ksw_gen_ts_mat
static void ksw_gen_simple_mat(int m, int8_t *mat, int8_t a, int8_t b, int8_t sc_ambi)
{
	int i, j;
	a = a < 0? -a : a;
	b = b > 0? -b : b;
	sc_ambi = sc_ambi > 0? -sc_ambi : sc_ambi;
	for (i = 0; i < m - 1; ++i) {
		for (j = 0; j < m - 1; ++j)
			mat[i * m + j] = i == j? a : b;
		mat[i * m + m - 1] = sc_ambi;
	}
	for (j = 0; j < m; ++j)
		mat[(m - 1) * m + j] = sc_ambi;
}

// Assembly:
pushq %rbp
pushq %rbx
movl %esi, %eax
sarb $0x7, %al
xorb %al, %sil
subb %al, %sil
movl %edx, %r9d
sarb $0x7, %r9b
movl %edx, %eax
xorb %r9b, %al
subb %al, %r9b
movl %r8d, %eax
sarb $0x7, %al
xorb %al, %r8b
subb %r8b, %al
xorl %r8d, %r8d
movzbl %sil, %esi
movzbl %r9b, %r9d
movq %rdi, %r10
cmpq $0x4, %r8
je 0x18061
leaq (%r8,%r8,4), %r11
xorl %ebx, %ebx
cmpq $0x4, %rbx
je 0x18053
cmpq %rbx, %r8
movl %r9d, %ebp
cmovel %esi, %ebp
movb %bpl, (%r10,%rbx)
incq %rbx
jmp 0x1803b
movb %al, 0x4(%rdi,%r11)
incq %r8
addq $0x5, %r10
jmp 0x1802f
xorl %esi, %esi
cmpq $0x5, %rsi
je 0x18072
movb %al, 0x14(%rdi,%rsi)
incq %rsi
jmp 0x18063
testb %cl, %cl
sete %al
cmpb %dl, %cl
sete %dl
orb %al, %dl
jne 0x18095
movl %ecx, %eax
sarb $0x7, %al
xorb %al, %cl
subb %cl, %al
movb %al, 0x2(%rdi)
movb %al, 0x8(%rdi)
movb %al, 0xa(%rdi)
movb %al, 0x10(%rdi)
popq %rbx
popq %rbp
retq