// File: /workspace/github_c_makefile_star2_O1/lh3[P]fermi2/sub.c
// Function: fm_sub
rld_t *fm_sub(rld_t *e, const uint64_t *sub, int n_threads, int is_comp, int is_both)
{
	shared_t d;
	rld_t *r;
	d.bits = calloc((e->mcnt[0] + 63) / 64, 8);
	d.sub = sub, d.e = e, d.n_threads = n_threads, d.is_both = is_both, d.n_ss = 0;
	kt_for(n_threads, worker, &d, n_threads);
	r = gen_idx(e, d.bits, is_comp);
	free(d.bits);
	if (is_both) fprintf(stderr, "[M::%s] # single-stranded: %ld\n", __func__, (long)d.n_ss);
	return r;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xb8, %rsp
movl %r8d, %ebp
movl %ecx, 0xc(%rsp)
movl %edx, %ebx
movq %rsi, %r12
movq %rdi, %r15
movq 0x28(%rdi), %rax
movq (%rax), %rdi
addq $0x3f, %rdi
shrq $0x6, %rdi
movl $0x8, %esi
callq 0x2190
leaq 0x70(%rsp), %rcx
movq %rax, -0x8(%rcx)
movq %r12, -0x10(%rcx)
movq %r15, -0x18(%rcx)
movl %ebx, 0x8(%rcx)
movl %ebp, 0xc(%rcx)
movq $0x0, (%rcx)
movslq %ebx, %rcx
leaq 0x3ed(%rip), %rsi       # 0x6042
leaq 0x58(%rsp), %rbx
movl %ecx, %edi
movq %rbx, %rdx
callq 0x360c
movq 0x10(%rbx), %rax
movq %rax, 0x50(%rsp)
movzbl (%r15), %edi
movsbl 0x3(%r15), %esi
callq 0x37a8
xorl %r14d, %r14d
leaq 0x80(%rsp), %rsi
movq %rax, 0x10(%rsp)
movq %rax, %rdi
xorl %edx, %edx
callq 0x3967
leaq 0x18(%rsp), %rsi
movq %r15, %rdi
xorl %edx, %edx
callq 0x3967
movl $0xffffffff, %r11d      # imm = 0xFFFFFFFF
movq $0x0, (%rsp)
xorl %ebx, %ebx
movq 0x28(%rsp), %rdi
movq (%rdi), %rax
movl 0x18(%rsp), %esi
movl %esi, %ecx
negb %cl
shlq %cl, %rax
cmpq 0x38(%rsp), %rdi
sete %cl
cmpl $0x40, %esi
sete %dl
orb %cl, %dl
je 0x5cde
xorl %r8d, %r8d
jmp 0x5ce7
movl %esi, %ecx
movq 0x8(%rdi), %r8
shrq %cl, %r8
orq %rax, %r8
js 0x5d21
movq %r8, %rcx
shrq $0x39, %rcx
andb $0x3c, %cl
movabsq $0x333333335555779b, %rax # imm = 0x333333335555779B
shrq %cl, %rax
movl %eax, %ecx
andl $0xf, %ecx
movabsq $0x400000000000000, %rdx # imm = 0x400000000000000
cmpq %rdx, %r8
jae 0x5d2e
cmpl $0xb, %ecx
jne 0x5d2e
xorl %r13d, %r13d
jmp 0x5d87
movl $0x1, %r13d
movl $0x1, %eax
jmp 0x5d5d
negb %cl
movq %r8, %r9
shrq %cl, %r9
andl $0xf, %eax
movq %r8, %r10
movl %eax, %ecx
shlq %cl, %r10
leaq -0x1(%r9), %rdx
movb $0x41, %cl
subb %r9b, %cl
shrq %cl, %r10
movl $0x1, %r13d
movl %edx, %ecx
shll %cl, %r13d
orq %r10, %r13
addl %edx, %eax
movl %eax, %ecx
shlq %cl, %r8
movsbl 0x2(%r15), %ecx
addl %ecx, %eax
negb %cl
shrq %cl, %r8
cmpl %eax, %esi
jg 0x5d7e
addq $0x8, %rdi
movq %rdi, 0x28(%rsp)
addl $0x40, %esi
subl %eax, %esi
movl %esi, 0x18(%rsp)
movl %r8d, %r14d
testq %r13, %r13
je 0x5d99
movzbl (%r15), %eax
cmpl %eax, %r14d
jle 0x5f33
movq 0x10(%r15), %r12
shrq $0x3, %r12
movb 0x3(%r15), %cl
shrq %cl, %r12
shlq %cl, %r12
movq 0x28(%rsp), %rcx
movq 0x40(%rsp), %rax
movq (%rax), %rdi
subq %rdi, %rcx
sarq $0x3, %rcx
movslq 0x8(%r15), %rax
movl $0x800000, %edx         # imm = 0x800000
subq %rax, %rdx
cmpq %rdx, %rcx
jle 0x5dfb
movl %r11d, %r13d
callq 0x2040
movl %r13d, %r11d
movq 0x40(%rsp), %rax
movq $0x0, (%rax)
movq 0x40(%rsp), %rax
leaq 0x8(%rax), %rcx
movq %rcx, 0x40(%rsp)
movq 0x8(%rax), %rax
jmp 0x5e04
shlq $0x3, %rax
addq 0x30(%rsp), %rax
movq %rax, 0x30(%rsp)
movq 0x18(%r15), %rcx
movq %r12, %rdx
shrq $0x17, %rdx
andl $0x7fffff, %r12d        # imm = 0x7FFFFF
shll $0x3, %r12d
addq (%rcx,%rdx,8), %r12
cmpq %r12, %rax
je 0x5eba
movq (%rax), %rcx
shrq $0x3e, %rcx
movsbq 0x5(%r15,%rcx), %rcx
leaq (%rax,%rcx,8), %rsi
movq %rsi, 0x28(%rsp)
movq %rsi, 0x48(%rsp)
movslq 0x8(%r15), %rcx
leaq (%rax,%rcx,8), %rax
movq 0x40(%rsp), %rcx
movq %rax, %rdx
subq (%rcx), %rdx
xorl %ecx, %ecx
cmpq $0x4000000, %rdx        # imm = 0x4000000
setne %cl
shll $0x3, %ecx
orq $-0x10, %rcx
addq %rax, %rcx
movq %rcx, 0x38(%rsp)
movl $0x40, 0x18(%rsp)
movq (%rsi), %rdi
testq %rdi, %rdi
js 0x5ec3
movq %rdi, %rcx
shrq $0x39, %rcx
andb $0x3c, %cl
movabsq $0x333333335555779b, %rax # imm = 0x333333335555779B
shrq %cl, %rax
movl %eax, %ecx
andl $0xf, %ecx
movabsq $0x400000000000000, %rdx # imm = 0x400000000000000
cmpq %rdx, %rdi
jae 0x5ed0
cmpl $0xb, %ecx
jne 0x5ed0
xorl %r13d, %r13d
jmp 0x5f33
movq $-0x1, %r13
jmp 0x5f33
movl $0x1, %r13d
movl $0x1, %eax
jmp 0x5eff
negb %cl
movq %rdi, %r8
shrq %cl, %r8
andl $0xf, %eax
movq %rdi, %r9
movl %eax, %ecx
shlq %cl, %r9
leaq -0x1(%r8), %rdx
movb $0x41, %cl
subb %r8b, %cl
shrq %cl, %r9
movl $0x1, %r13d
movl %edx, %ecx
shll %cl, %r13d
orq %r9, %r13
addl %edx, %eax
movl %eax, %ecx
shlq %cl, %rdi
movsbl 0x2(%r15), %edx
movl %edx, %ecx
negb %cl
shrq %cl, %rdi
addl %edx, %eax
movl $0x40, %ecx
cmpl $0x40, %eax
jl 0x5f2a
addq $0x8, %rsi
movq %rsi, 0x28(%rsp)
movl $0x80, %ecx
subl %eax, %ecx
movl %ecx, 0x18(%rsp)
movl %edi, %r14d
testq %r13, %r13
js 0x5fae
je 0x5cb4
movl %ebp, 0x8(%rsp)
movq %r13, %rbp
movq (%rsp), %r12
cmpl $0x0, 0xc(%rsp)
setne %al
movq %r12, %rcx
sarq $0x6, %rcx
movq 0x50(%rsp), %rdx
movq (%rdx,%rcx,8), %rcx
btq %r12, %rcx
sbbb $0x0, %al
je 0x5f99
cmpl %r11d, %r14d
jne 0x5f73
incq %rbx
jmp 0x5f99
testq %rbx, %rbx
je 0x5f91
movzbl %r11b, %ecx
movq 0x10(%rsp), %rdi
leaq 0x80(%rsp), %rsi
movq %rbx, %rdx
callq 0x39e2
movl $0x1, %ebx
movl %r14d, %r11d
incq %r12
decq %rbp
jne 0x5f49
addq %r13, (%rsp)
movl 0x8(%rsp), %ebp
jmp 0x5cb4
testq %rbx, %rbx
movq 0x10(%rsp), %r14
je 0x5fcf
movzbl %r11b, %ecx
leaq 0x80(%rsp), %rsi
movq %r14, %rdi
movq %rbx, %rdx
callq 0x39e2
movq 0x28(%r15), %rax
movq (%rsp), %rcx
cmpq (%rax), %rcx
jne 0x6023
movq %r15, %rdi
callq 0x38cc
leaq 0x80(%rsp), %rsi
movq %r14, %rdi
callq 0x3fd7
movq 0x68(%rsp), %rdi
callq 0x2040
testl %ebp, %ebp
jne 0x6017
movq %r14, %rax
addq $0xb8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x70(%rsp), %rdi
callq 0x2390
jmp 0x6002
leaq 0x1631a(%rip), %rdi     # 0x1c344
leaq 0x16324(%rip), %rsi     # 0x1c355
leaq 0x16323(%rip), %rcx     # 0x1c35b
movl $0x3d, %edx
callq 0x2120