LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: push_cov_interval_advance(kvec_t_u64_warp*, long long, long long, long long, unsigned int)
uint32_t push_cov_interval_advance(kvec_t_u64_warp* a, long long x_beg, long long x_end, long long utg_len, uint32_t is_circle)
{
    if(x_beg > x_end) return 0;
    
    if(push_cov_interval_direct(a, x_beg, x_end, utg_len, 0)) return 1;
    

    if(x_beg < 0 && x_end < 0)
    {
        x_beg = utg_len + x_beg;
        x_end = utg_len + x_end;
        return push_cov_interval_direct(a, x_beg, x_end, utg_len, 0);
    }

    if(x_beg >= utg_len && x_end >= utg_len)
    {
        x_beg = x_beg - utg_len;
        x_end = x_end - utg_len;
        return push_cov_interval_direct(a, x_beg, x_end, utg_len, 0);
    }

    if(x_beg < 0 && x_end >= 0)
    {
        x_beg = utg_len + x_beg;
        if(push_cov_interval_direct(a, x_beg, utg_len - 1, utg_len, is_circle) || 
             push_cov_interval_direct(a, 0, x_end, utg_len, is_circle))
        {
            return 1;
        }
    }

    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
xorl %ebp, %ebp
cmpq %rdx, %rsi
jg 0xb8423
movl %r8d, %r13d
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
xorl %r8d, %r8d
callq 0xb830d
movl $0x1, %ebp
testl %eax, %eax
je 0xb8434
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
testq %r12, %r14
js 0xb8499
movq %r12, %rsi
subq %rbx, %rsi
setl %al
movq %r14, %rdx
subq %rbx, %rdx
setl %cl
orb %al, %cl
je 0xb84aa
testq %r12, %r12
setns %al
testq %r14, %r14
sets %cl
orb %al, %cl
jne 0xb8495
addq %rbx, %r12
leaq -0x1(%rbx), %rdx
movl %r13d, %r13d
movq %r15, %rdi
movq %r12, %rsi
movq %rbx, %rcx
movq %r13, %r8
callq 0xb830d
testl %eax, %eax
jne 0xb8423
movq %r15, %rdi
xorl %esi, %esi
movq %r14, %rdx
movq %rbx, %rcx
movq %r13, %r8
callq 0xb830d
testl %eax, %eax
jne 0xb8423
xorl %ebp, %ebp
jmp 0xb8423
addq %rbx, %r12
addq %rbx, %r14
movq %r15, %rdi
movq %r12, %rsi
movq %r14, %rdx
jmp 0xb84ad
movq %r15, %rdi
movq %rbx, %rcx
xorl %r8d, %r8d
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xb830d
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: debug_r_contig_pos(ma_utg_t*, unsigned int, All_reads*)
void debug_r_contig_pos(ma_utg_t *u, uint32_t tn, All_reads *RNF)
{
    uint32_t c_beg, c_end, l, k;
    for (k = l = 0; k < u->n; k++)
    {
        c_beg = l;
        c_end = c_beg + Get_READ_LENGTH((*RNF), (u->a[k]>>33));
        l += (uint32_t)u->a[k];
        if((u->a[k]>>33) == tn)
        {
            fprintf(stderr, "#####c_beg: %u, c_end: %u\n", c_beg, c_end);
            break;
        }
    }
}

// Assembly:
movl 0x10(%rdi), %ecx
testq %rcx, %rcx
je 0xb86dc
movq 0x18(%rdi), %rdi
movl %esi, %esi
xorl %r8d, %r8d
xorl %eax, %eax
movq (%rdi,%r8,8), %r9
movq %r9, %r10
shrq $0x21, %r10
cmpq %rsi, %r10
je 0xb86dd
addl %r9d, %eax
incq %r8
cmpl %r8d, %ecx
jne 0xb86c1
retq
movq 0x18(%rdx), %rcx
movl (%rcx,%r10,8), %ecx
addl %eax, %ecx
movq 0x1d18f2(%rip), %rdx    # 0x289fe0
movq (%rdx), %rdi
leaq 0x171efc(%rip), %rsi    # 0x22a5f4
movl %eax, %edx
xorl %eax, %eax
jmp 0x22b0
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: get_overlap_contig_dir(unsigned int, unsigned int, ma_hit_t*, All_reads*, long long, unsigned int, unsigned int)
uint32_t get_overlap_contig_dir(uint32_t v, uint32_t tn, ma_hit_t *h, All_reads *RNF, long long ctg_beg,
uint32_t p_beg, uint32_t p_end)
{
    long long qs, qe, ts, te, c_beg, c_end;

    qs = Get_qs((*h)); qe = Get_qe((*h)) - 1;
    ts = Get_ts((*h)); te = Get_te((*h)) - 1;
    if(h->rev)
    {
        ts = (long long)(Get_READ_LENGTH((*RNF), tn)) - ((long long)(Get_te((*h))) - 1) - 1;
        te = (long long)(Get_READ_LENGTH((*RNF), tn)) - (long long)(Get_ts((*h))) - 1;
    }
    ts = qs - ts;
    te = qe + ((long long)(Get_READ_LENGTH((*RNF), tn)) - te - 1);
    c_beg = ts; c_end = te;

    if(v&1)
    {
        ts = (long long)(Get_READ_LENGTH((*RNF), v>>1)) - ts - 1;
        te = (long long)(Get_READ_LENGTH((*RNF), v>>1)) - te - 1;
        c_beg = te; c_end = ts;
    }

    c_end++;
    c_beg += ctg_beg; c_end += ctg_beg;

    if((p_beg != p_end && c_beg <= p_beg && c_end >= p_end) || 
                    (p_beg == p_end && c_beg < p_beg && c_end > p_end))
    {
        return 2;
    }

    if(c_beg < p_beg) return 0;
    if(c_end > p_end) return 1;

    return 2;

}

// Assembly:
pushq %r14
pushq %rbx
movl (%rdx), %r10d
movl 0x8(%rdx), %r11d
decl %r11d
movl 0x10(%rdx), %ebx
movl 0x14(%rdx), %eax
testb $-0x80, 0x1b(%rdx)
movl %esi, %esi
jne 0xb8720
decl %eax
jmp 0xb873a
movq 0x18(%rcx), %rdx
movq (%rdx,%rsi,8), %rdx
movq %rdx, %r14
subq %rax, %r14
notq %rbx
movq %rbx, %rax
addq %rdx, %rax
movq %r14, %rbx
subq %rbx, %r10
movl 0x18(%rsp), %edx
movq 0x18(%rcx), %rcx
notq %rax
addq %r11, %rax
addq (%rcx,%rsi,8), %rax
testb $0x1, %dil
je 0xb8770
shrl %edi
movq (%rcx,%rdi,8), %rcx
notq %r10
movq %r10, %rsi
addq %rcx, %rsi
notq %rax
addq %rcx, %rax
movq %rax, %r10
movq %rsi, %rax
addq %r8, %r10
leaq (%r8,%rax), %rsi
incq %rsi
movl %r9d, %ecx
movl %edx, %edi
movl $0x2, %eax
cmpl %edx, %r9d
je 0xb8793
cmpq %rcx, %r10
jg 0xb8793
cmpq %rdi, %rsi
jge 0xb87b4
cmpl %edx, %r9d
jne 0xb87a2
cmpq %rcx, %r10
jge 0xb87a2
cmpq %rdi, %rsi
jg 0xb87b4
xorl %edx, %edx
cmpq %rdi, %rsi
setle %dl
incl %edx
xorl %eax, %eax
cmpq %rcx, %r10
cmovgel %edx, %eax
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: push_sub_unitig(ma_ug_t*, ma_utg_t*, asg_t*, kvec_asg_arc_t_warp*, unsigned int, unsigned int)
void push_sub_unitig(ma_ug_t *n_ug, ma_utg_t *src_u, asg_t *read_g, kvec_asg_arc_t_warp* edge, 
uint32_t beg_idx, uint32_t occ)
{
    uint32_t i;
    uint64_t totalLen;
    ma_utg_t* p = NULL;
    kv_pushp(ma_utg_t, n_ug->u, &p);
    p->s = NULL;
    p->n = occ;
    p->circ = 0;
    if(beg_idx == 0 && occ == src_u->n) p->circ = src_u->circ;
    p->m = p->n;
    p->a = (uint64_t*)malloc(8 * p->m);
    for (i = 0; i < occ; i++) p->a[i] = src_u->a[beg_idx+i];
    fill_unitig(p->a, occ, read_g, edge, p->circ, &totalLen);
    p->len = totalLen;
    if(!p->circ)
    {
        p->start = p->a[0]>>32;
        p->end = (p->a[p->n-1]>>32)^1;
    }
    else
    {
        p->start = p->end = UINT32_MAX;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r9d, %ebp
movl %r8d, %r15d
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r13
movq 0x8(%rdi), %rax
cmpq %rax, (%rdi)
jne 0xba007
leaq (%rax,%rax), %rcx
testq %rax, %rax
movl $0x2, %eax
cmovneq %rcx, %rax
movq %rax, 0x8(%r13)
movq 0x10(%r13), %rdi
shlq $0x3, %rax
leaq (%rax,%rax,4), %rsi
callq 0x2370
movq %rax, 0x10(%r13)
movq (%r13), %rax
movq 0x10(%r13), %rcx
leaq 0x1(%rax), %rdx
movq %rdx, (%r13)
leaq (%rax,%rax,4), %rax
leaq (%rcx,%rax,8), %r13
movq $0x0, 0x20(%r13)
movl %ebp, 0x10(%r13)
movl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
andl (%r13), %eax
movl %eax, (%r13)
testl %r15d, %r15d
jne 0xba053
cmpl %ebp, 0x10(%r12)
jne 0xba053
movl $0x80000000, %ecx       # imm = 0x80000000
andl (%r12), %ecx
orl %eax, %ecx
movl %ecx, (%r13)
movl 0x10(%r13), %edi
movl %edi, 0xc(%r13)
shll $0x3, %edi
callq 0x2280
movq %rax, 0x18(%r13)
testl %ebp, %ebp
je 0xba08b
movq 0x18(%r12), %rcx
movl %ebp, %edx
movl %r15d, %esi
xorl %edi, %edi
leal (%rsi,%rdi), %r8d
movq (%rcx,%r8,8), %r8
movq %r8, (%rax,%rdi,8)
incq %rdi
cmpq %rdi, %rdx
jne 0xba077
movl (%r13), %r8d
shrl $0x1f, %r8d
movq %rsp, %r15
movq %rax, %rdi
movl %ebp, %esi
movq %r14, %rdx
movq %rbx, %rcx
movq %r15, %r9
callq 0x10e9f4
movl (%r13), %eax
movl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
andl (%r15), %ecx
movl %eax, %edx
andl $0x80000000, %edx       # imm = 0x80000000
orl %ecx, %edx
movl %edx, (%r13)
testl %eax, %eax
js 0xba0e5
movq 0x18(%r13), %rax
movl 0x4(%rax), %ecx
movl %ecx, 0x4(%r13)
movl 0x10(%r13), %ecx
decl %ecx
movl 0x4(%rax,%rcx,8), %eax
xorl $0x1, %eax
movl %eax, 0x8(%r13)
jmp 0xba0ed
movq $-0x1, 0x4(%r13)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: renew_utg(ma_ug_t**, asg_t*, kvec_asg_arc_t_warp*)
void renew_utg(ma_ug_t **ug, asg_t* read_g, kvec_asg_arc_t_warp* edge)
{
    ma_ug_t* high_level_ug = NULL;
    asg_t* nsg = (*ug)->g;
    uint32_t i;
    ma_utg_t *u;
    high_level_ug = ma_ug_gen(nsg);
    for (i = 0; i < high_level_ug->u.n; i++)
    {
        high_level_ug->g->seq[i].c = PRIMARY_LABLE;
        u = &(high_level_ug->u.a[i]);
        if(u->m == 0) continue;
        merge_unitig_content(u, (*ug), read_g, edge);
        high_level_ug->g->seq[i].len = u->len;
    }
    ma_ug_destroy((*ug));
    (*ug) = high_level_ug;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, (%rsp)
movq %rsi, %r15
movq %rdi, %rbx
movq (%rdi), %rax
movq 0x18(%rax), %rdi
callq 0xb0285
movq %rax, %r12
cmpq $0x0, (%rax)
je 0xba7f7
movl $0x1, %ebp
xorl %r14d, %r14d
movq 0x18(%r12), %rax
movq 0x20(%rax), %rax
movb $0x0, 0x4(%rax,%r14,8)
movq 0x10(%r12), %rax
leaq (%r14,%r14,4), %rcx
cmpl $0x0, 0xc(%rax,%rcx,8)
je 0xba7ec
leaq (%rax,%rcx,8), %r13
movq (%rbx), %rsi
movq %r13, %rdi
movq %r15, %rdx
movq (%rsp), %rcx
callq 0xcc400
movl (%r13), %eax
movl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
andl %ecx, %eax
movq 0x18(%r12), %rcx
movq 0x20(%rcx), %rcx
movl (%rcx,%r14,8), %edx
movl $0x80000000, %esi       # imm = 0x80000000
andl %esi, %edx
orl %eax, %edx
movl %edx, (%rcx,%r14,8)
movl %ebp, %r14d
incl %ebp
cmpq %r14, (%r12)
ja 0xba792
movq (%rbx), %rdi
callq 0xa0004
movq %r12, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: get_num_trio_flag(ma_ug_t*, unsigned int, unsigned int)
uint32_t get_num_trio_flag(ma_ug_t *ug, uint32_t v, uint32_t flag)
{
    if(flag == (uint32_t)-1) return 0;
    ma_utg_t* u = NULL;
    asg_t* nsg = ug->g;
    uint32_t k, rId, flag_occ = 0;
    if (nsg->seq[v].del) return 0;
    u = &(ug->u.a[v]);
    if(u->m == 0) return 0;
    for (k = 0; k < u->n; k++)
    {
        rId = u->a[k]>>33;
        if(R_INF.trio_flag[rId] == flag) flag_occ++;
    }

    return flag_occ;
}

// Assembly:
xorl %eax, %eax
cmpl $-0x1, %edx
je 0xbb723
movq 0x18(%rdi), %rcx
movq 0x20(%rcx), %r8
movl %esi, %ecx
cmpl $0x0, (%r8,%rcx,8)
js 0xbb723
movq 0x10(%rdi), %rsi
leaq (%rcx,%rcx,4), %rcx
cmpl $0x0, 0xc(%rsi,%rcx,8)
je 0xbb723
leaq (%rsi,%rcx,8), %rsi
movl 0x10(%rsi), %ecx
testq %rcx, %rcx
je 0xbb723
movq 0x18(%rsi), %rsi
leaq 0x1cfb38(%rip), %rax    # 0x28b230
movq 0x28(%rax), %rdi
xorl %r8d, %r8d
xorl %eax, %eax
movq (%rsi,%r8,8), %r9
shrq $0x21, %r9
movzbl (%rdi,%r9), %r9d
xorl %r10d, %r10d
cmpl %edx, %r9d
sete %r10b
addl %r10d, %eax
incq %r8
cmpq %r8, %rcx
jne 0xbb701
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: reset_u_trans_hit_idx(u_trans_hit_idx*, unsigned int*, unsigned int, ma_ug_t*, asg_t*, trans_chain*, unsigned int, unsigned int)
void reset_u_trans_hit_idx(u_trans_hit_idx *t, uint32_t* i_x_a, uint32_t i_x_n, ma_ug_t *i_ug, 
asg_t *i_read_sg, trans_chain* i_t_ch, uint32_t i_cBeg, uint32_t i_cEnd)
{
    t->a = i_x_a;
    t->an = i_x_n;
    t->ug = i_ug;
    t->read_sg = i_read_sg;
    t->t_ch = i_t_ch;
    t->cBeg = i_cBeg;
    t->cEnd = i_cEnd;
    t->u_i = t->r_i = t->len = t->s_pos_cur = t->s_pre_v = t->s_pre_w = 0;
    t->p_v = t->p_uId = t->p_idx = (uint32_t)-1; 
}

// Assembly:
movl 0x10(%rsp), %eax
movl 0x8(%rsp), %r10d
movq %rsi, 0x30(%rdi)
movl %edx, 0x38(%rdi)
movq %rcx, 0x40(%rdi)
movq %r8, 0x48(%rdi)
movq %r9, 0x50(%rdi)
movl %r10d, 0x24(%rdi)
movl %eax, 0x28(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movl $0xffffffff, 0x20(%rdi) # imm = 0xFFFFFFFF
movq $-0x1, 0x18(%rdi)
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: set_r_het_flag(ma_ug_t*, asg_t*, ma_sub_t*, ma_hit_t_alloc*, R_to_U*, unsigned char*)
void set_r_het_flag(ma_ug_t *ug, asg_t *sg, ma_sub_t* coverage_cut, ma_hit_t_alloc* sources, R_to_U* ruIndex, uint8_t* is_r_het)
{
    uint64_t m, dip_thre_max, dip_thres;
    uint8_t* primary_flag = (uint8_t*)calloc(sg->n_seq, sizeof(uint8_t));

    if(asm_opt.hom_global_coverage_set)
    {
        dip_thre_max = asm_opt.hom_global_coverage;
    }
    else
    {
        dip_thre_max = ((double)asm_opt.hom_global_coverage)/((double)HOM_PEAK_RATE);
    }
    // dip_thre_max *= 0.75;
    dip_thre_max = (double)(dip_thre_max) - (((double)(dip_thre_max)*0.5)/asm_opt.polyploidy);

    // fprintf(stderr, "dip_thre_max: %lu\n", dip_thre_max);
            
    for (m = 0; m < ug->g->n_seq; m++)
    {
        dip_thres = dip_thre_max;
        ///if(ug->u.a[m].n <= dip_thre_max) dip_thres = dip_thre_max * 1.1;
        set_ug_coverage_aggressive(ug, m, sg, coverage_cut, sources, ruIndex, primary_flag, is_r_het, dip_thres);
    }
    free(primary_flag); 
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r9, 0x10(%rsp)
movq %r8, 0x8(%rsp)
movq %rcx, (%rsp)
movq %rdx, %r12
movq %rsi, %r13
movq %rdi, %rbp
movl 0x14(%rsi), %edi
andl $0x7fffffff, %edi       # imm = 0x7FFFFFFF
movl $0x1, %esi
callq 0x2120
leaq 0x1cc4a8(%rip), %rcx    # 0x28a758
movslq 0x144(%rcx), %rsi
cvtsi2sd %esi, %xmm1
divsd 0x16b8a5(%rip), %xmm1   # 0x229b68
cvttsd2si %xmm1, %rdi
movsd 0x166f98(%rip), %xmm0   # 0x225268
subsd %xmm0, %xmm1
cvttsd2si %xmm1, %r8
movq %rdi, %rdx
sarq $0x3f, %rdx
andq %r8, %rdx
orq %rdi, %rdx
cmpl $0x0, 0x148(%rcx)
cmovneq %rsi, %rdx
movq %rax, %rbx
movq 0x18(%rbp), %rax
testl $0x7fffffff, 0x14(%rax) # imm = 0x7FFFFFFF
je 0xbe39e
movq %rdx, %xmm1
punpckldq 0x166f2e(%rip), %xmm1 # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1]
subpd 0x166f36(%rip), %xmm1   # 0x225250
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
movsd 0x16b84a(%rip), %xmm1   # 0x229b78
mulsd %xmm2, %xmm1
cvtsi2sdl 0x1bc(%rcx), %xmm3
divsd %xmm3, %xmm1
addsd %xmm2, %xmm1
cvttsd2si %xmm1, %rax
movq %rax, %rcx
subsd %xmm0, %xmm1
cvttsd2si %xmm1, %r15
sarq $0x3f, %rcx
andq %rcx, %r15
orq %rax, %r15
xorl %r14d, %r14d
subq $0x8, %rsp
movq %rbp, %rdi
movl %r14d, %esi
movq %r13, %rdx
movq %r12, %rcx
movq 0x8(%rsp), %r8
movq 0x10(%rsp), %r9
pushq %r15
pushq 0x20(%rsp)
pushq %rbx
callq 0xbde02
addq $0x20, %rsp
incq %r14
movq 0x18(%rbp), %rax
movl 0x14(%rax), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
cmpq %rax, %r14
jb 0xbe360
movq %rbx, %rdi
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x2220
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: init_hc_links(hc_links*, unsigned long, trans_chain*)
void init_hc_links(hc_links* link, uint64_t ug_num, trans_chain* t_ch)
{
    kv_malloc(link->a, ug_num); link->a.n = ug_num;
    kv_malloc(link->enzymes, ug_num); link->enzymes.n = ug_num;
    uint64_t i;
    for (i = 0; i < link->a.n; i++)
    {
        kv_init(link->a.a[i].e);
        kv_init(link->a.a[i].f);
    }

    if(t_ch)
    {
        kv_u_trans_t *ta = &(t_ch->k_trans);
        uint64_t d = RC_1;
        for (i = 0; i < ta->n; i++)
        {
            if(ta->a[i].f == RC_2) continue;
            push_hc_edge(&(link->a.a[ta->a[i].qn]), ta->a[i].tn, 1, 1, &d);
            push_hc_edge(&(link->a.a[ta->a[i].tn]), ta->a[i].qn, 1, 1, &d);
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r13
movq %rdi, %r14
xorl %ebp, %ebp
movq %rbp, (%rdi)
movq %rsi, 0x8(%rdi)
movq %rsi, %rax
shlq $0x4, %rax
leaq (%rax,%rax,2), %r15
movq %r15, %rdi
callq 0x2280
movq %rax, %r12
movq %rax, 0x10(%r14)
movq %r13, (%r14)
movq %rbp, 0x18(%r14)
movq %r13, 0x20(%r14)
leaq (,%r13,8), %rdi
callq 0x2280
movq %rax, 0x28(%r14)
movq %r13, 0x18(%r14)
testq %r13, %r13
je 0xbe83b
movq %r12, %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0x20e0
testq %rbx, %rbx
je 0xbe8e5
movq $0x1, (%rsp)
cmpq $0x0, 0x138(%rbx)
je 0xbe8e5
movl $0x14, %r12d
xorl %r13d, %r13d
movq %rsp, %r15
movq 0x148(%rbx), %rax
movb 0x14(%rax,%r12), %cl
andb $0x3f, %cl
cmpb $0x2, %cl
je 0xbe8d5
movl -0xc(%rax,%r12), %ecx
movl (%rax,%r12), %esi
leaq (%rcx,%rcx,2), %rdi
shlq $0x4, %rdi
addq 0x10(%r14), %rdi
movsd 0x1669d9(%rip), %xmm0   # 0x225270
movl $0x1, %edx
movq %r15, %rcx
callq 0x13b8bb
movq 0x148(%rbx), %rax
movl -0xc(%rax,%r12), %esi
movl (%rax,%r12), %eax
leaq (%rax,%rax,2), %rdi
shlq $0x4, %rdi
addq 0x10(%r14), %rdi
movsd 0x1669a8(%rip), %xmm0   # 0x225270
movl $0x1, %edx
movq %r15, %rcx
callq 0x13b8bb
incq %r13
addq $0x30, %r12
cmpq 0x138(%rbx), %r13
jb 0xbe866
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: destory_hc_links(hc_links*)
void destory_hc_links(hc_links* link)
{
    uint64_t i;
    for (i = 0; i < link->a.n; i++)
    {
        kv_destroy(link->a.a[i].e);
        kv_destroy(link->a.a[i].f);
    }
    kv_destroy(link->a);
    kv_destroy(link->enzymes);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
cmpq $0x0, (%rdi)
je 0xbe930
xorl %r14d, %r14d
xorl %r15d, %r15d
movq 0x10(%rbx), %rax
movq 0x10(%rax,%r14), %rdi
callq 0x2220
movq 0x10(%rbx), %rax
movq 0x28(%rax,%r14), %rdi
callq 0x2220
incq %r15
addq $0x30, %r14
cmpq (%rbx), %r15
jb 0xbe908
movq 0x10(%rbx), %rdi
callq 0x2220
movq 0x28(%rbx), %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x2220
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: write_trans_chain(trans_chain*, char const*)
void write_trans_chain(trans_chain* t_ch, const char *fn)
{
    char *buf = (char*)calloc(strlen(fn) + 25, 1);
    sprintf(buf, "%s.hic.trans.bin", fn);
    FILE* fp = fopen(buf, "w");

    fwrite(&t_ch->r_num, sizeof(t_ch->r_num), 1, fp);
    fwrite(t_ch->ir_het, sizeof(uint8_t), t_ch->r_num, fp);
    
    uint32_t i;
    fwrite(&t_ch->bed.n, sizeof(t_ch->bed.n), 1, fp);
    for (i = 0; i < t_ch->bed.n; i++)
    {
        fwrite(&t_ch->bed.a[i].n, sizeof(t_ch->bed.a[i].n), 1, fp);
        fwrite(t_ch->bed.a[i].a, sizeof(bed_interval), t_ch->bed.a[i].n, fp);
    }

    fwrite(&t_ch->k_trans.n, sizeof(t_ch->k_trans.n), 1, fp);
    fwrite(t_ch->k_trans.a, sizeof(u_trans_t), t_ch->k_trans.n, fp);

    fwrite(&t_ch->k_trans.idx.n, sizeof(t_ch->k_trans.idx.n), 1, fp);
    fwrite(t_ch->k_trans.idx.a, sizeof(uint64_t), t_ch->k_trans.idx.n, fp);


    fclose(fp);
    free(buf);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %r15
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x2090
leaq 0x19(%rax), %rdi
movl $0x1, %esi
callq 0x2120
movq %rax, %r14
leaq 0x16bf2a(%rip), %rsi    # 0x22a89f
movq %rax, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0x2050
leaq 0x17da75(%rip), %rsi    # 0x23c3fe
movq %r14, %rdi
callq 0x2210
movq %rax, %r15
leaq 0x18(%rbx), %rdi
movl $0x4, %esi
movl $0x1, %edx
movq %rax, %rcx
callq 0x2410
movq 0x10(%rbx), %rdi
movl 0x18(%rbx), %edx
movl $0x1, %esi
movq %r15, %rcx
callq 0x2410
leaq 0x20(%rbx), %rdi
movl $0x8, %esi
movl $0x1, %edx
movq %r15, %rcx
callq 0x2410
cmpq $0x0, 0x20(%rbx)
je 0xbea27
movl $0x1, %ebp
xorl %eax, %eax
shlq $0x3, %rax
leaq (%rax,%rax,2), %r12
movq 0x30(%rbx), %rdi
addq %r12, %rdi
movl $0x8, %esi
movl $0x1, %edx
movq %r15, %rcx
callq 0x2410
movq 0x30(%rbx), %rax
movq (%rax,%r12), %rdx
movq 0x10(%rax,%r12), %rdi
movl $0x10, %esi
movq %r15, %rcx
callq 0x2410
movl %ebp, %eax
incl %ebp
cmpq %rax, 0x20(%rbx)
ja 0xbe9e2
leaq 0x138(%rbx), %rdi
movl $0x8, %esi
movl $0x1, %edx
movq %r15, %rcx
callq 0x2410
movq 0x138(%rbx), %rdx
movq 0x148(%rbx), %rdi
movl $0x30, %esi
movq %r15, %rcx
callq 0x2410
leaq 0x150(%rbx), %rdi
movl $0x8, %esi
movl $0x1, %edx
movq %r15, %rcx
callq 0x2410
movq 0x150(%rbx), %rdx
movq 0x160(%rbx), %rdi
movl $0x8, %esi
movq %r15, %rcx
callq 0x2410
movq %r15, %rdi
callq 0x2190
movq %r14, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x2220
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: update_dump_trio(unsigned char*, unsigned int, unsigned char*, ma_ug_t*)
void update_dump_trio(uint8_t* trio_flag, uint32_t rn, uint8_t *rf, ma_ug_t *ug)
{
    uint32_t k, i, x;
    ma_utg_t *p = NULL; 
    if(ug) {
        for (i = 0; i < ug->u.n; ++i) { // the Segment lines in GFA
            p = &ug->u.a[i];
            if(p->m == 0) continue;
            for (k = 0; k < p->n; k++) {
                x = p->a[k]>>33;
                if(trio_flag[x] == FATHER || trio_flag[x] == MOTHER) {
                    rf[x] = trio_flag[x];
                } else if(rf[x] != FATHER && rf[x] != MOTHER) {
                    rf[x] = DROP;
                }
            }
        }
    } else {
        for (i = 0; i < rn; i++) {
            if(rf[i]) {
                rf[i] <<= 1; rf[i] += 1;
            } else {
                rf[i] = trio_flag[i]; rf[i] <<= 1;
            }

            if(trio_flag[i] == FATHER || trio_flag[i] == MOTHER) {
                trio_flag[i] = ((rf[i]&1)?MOTHER:FATHER);
            } else {
                trio_flag[i] = ((rf[i]&1)?DROP:AMBIGU);
            }
        }
    }    
}

// Assembly:
testq %rcx, %rcx
je 0xc1f1e
cmpq $0x0, (%rcx)
je 0xc1f76
xorl %eax, %eax
movq 0x10(%rcx), %rsi
leaq (%rax,%rax,4), %r8
cmpl $0x0, 0xc(%rsi,%r8,8)
je 0xc1f15
leaq (%rsi,%r8,8), %rsi
cmpl $0x0, 0x10(%rsi)
je 0xc1f15
xorl %r8d, %r8d
movq 0x18(%rsi), %r9
movq (%r9,%r8,8), %r9
shrq $0x21, %r9
movb (%rdi,%r9), %r10b
leal -0x1(%r10), %r11d
cmpb $0x2, %r11b
jb 0xc1f05
movb (%rdx,%r9), %r11b
decb %r11b
movb $0x5, %r10b
cmpb $0x2, %r11b
jb 0xc1f09
movb %r10b, (%rdx,%r9)
incq %r8
movl 0x10(%rsi), %r9d
cmpq %r9, %r8
jb 0xc1edb
incl %eax
cmpq %rax, (%rcx)
ja 0xc1ebe
jmp 0xc1f76
testl %esi, %esi
je 0xc1f76
movl %esi, %eax
xorl %ecx, %ecx
movb (%rdx,%rcx), %sil
testb %sil, %sil
je 0xc1f37
addb %sil, %sil
incb %sil
jmp 0xc1f3e
movb (%rdi,%rcx), %sil
addb %sil, %sil
movb %sil, (%rdx,%rcx)
movb (%rdi,%rcx), %r8b
decb %r8b
andb $0x1, %sil
movl %esi, %r9d
negb %r9b
andb $0x5, %r9b
incb %sil
cmpb $0x2, %r8b
movzbl %sil, %esi
movzbl %r9b, %r8d
cmovbl %esi, %r8d
movb %r8b, (%rdi,%rcx)
incq %rcx
cmpq %rcx, %rax
jne 0xc1f26
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: update_poly_trio(unsigned int, unsigned int*, unsigned int)
void update_poly_trio(uint32_t mm, uint32_t *hapS, uint32_t rn)
{
    uint32_t i;
    for (i = 0; i < rn; i++) {
        if(R_INF.trio_flag[i] == DROP) continue;
        R_INF.trio_flag[i] = AMBIGU;
        if(!hapS[i]) continue;
        R_INF.trio_flag[i] = (hapS[i]&mm?FATHER:MOTHER);
    }    
}

// Assembly:
testl %edx, %edx
je 0xc1fc0
movl %edx, %eax
xorl %ecx, %ecx
leaq 0x1c92aa(%rip), %rdx    # 0x28b230
movq 0x28(%rdx), %r8
cmpb $0x5, (%r8,%rcx)
je 0xc1fb8
movb $0x0, (%r8,%rcx)
movl (%rsi,%rcx,4), %r8d
testl %r8d, %r8d
je 0xc1fb8
andl %edi, %r8d
cmpl $0x1, %r8d
movl $0x0, %r8d
adcb $0x1, %r8b
movq 0x28(%rdx), %r9
movb %r8b, (%r9,%rcx)
incq %rcx
cmpq %rcx, %rax
jne 0xc1f86
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: write_dbug(ma_ug_t*, _IO_FILE*)
void write_dbug(ma_ug_t* ug, FILE* fp)
{
    ma_utg_t *u = NULL;
    uint32_t t, i;
    fwrite(&(ug->u.n), sizeof(ug->u.n), 1, fp);
    for (i = 0; i < ug->u.n; i++)
    {
        u = &(ug->u.a[i]);
        t = u->len;
        fwrite(&t, sizeof(t), 1, fp);
        t = u->circ;
        fwrite(&t, sizeof(t), 1, fp);
        fwrite(&(u->start), sizeof(u->start), 1, fp);
        fwrite(&(u->end), sizeof(u->end), 1, fp);
        fwrite(&(u->n), sizeof(u->n), 1, fp);
        fwrite(u->a, sizeof(uint64_t), u->n, fp);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movl $0x8, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x2410
cmpq $0x0, (%r14)
je 0xc2a50
movl $0x1, %ebp
xorl %eax, %eax
movq %r14, 0x10(%rsp)
movq 0x10(%r14), %r13
leaq (%rax,%rax,4), %r15
leaq 0x4(,%r15,8), %r12
addq %r13, %r12
movl -0x4(%r12), %eax
movl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
andl %ecx, %eax
movl %eax, 0xc(%rsp)
movl $0x4, %esi
movl $0x1, %edx
leaq 0xc(%rsp), %r14
movq %r14, %rdi
movq %rbx, %rcx
callq 0x2410
movl -0x4(%r12), %eax
shrl $0x1f, %eax
movl %eax, 0xc(%rsp)
movl $0x4, %esi
movl $0x1, %edx
movq %r14, %rdi
movq 0x10(%rsp), %r14
movq %rbx, %rcx
callq 0x2410
movl $0x4, %esi
movl $0x1, %edx
movq %r12, %rdi
movq %rbx, %rcx
callq 0x2410
leaq 0x8(,%r15,8), %rdi
addq %r13, %rdi
movl $0x4, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x2410
leaq 0x10(,%r15,8), %r12
addq %r13, %r12
movl $0x4, %esi
movl $0x1, %edx
movq %r12, %rdi
movq %rbx, %rcx
callq 0x2410
movq 0x8(%r12), %rdi
movl (%r12), %edx
movl $0x8, %esi
movq %rbx, %rcx
callq 0x2410
movl %ebp, %eax
incl %ebp
cmpq %rax, (%r14)
ja 0xc2978
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: filter_u_trans(kv_u_trans_t*, unsigned char, unsigned char, unsigned char, unsigned char)
void filter_u_trans(kv_u_trans_t *ta, uint8_t keep_bub, uint8_t keep_topo, uint8_t keep_read, uint8_t keep_base)
{
    if(keep_bub && keep_topo && keep_read && keep_base) return;
    uint32_t i, m;
    for (i = m = 0; i < ta->n; i++) {
        if((!keep_bub) && (ta->a[i].f == RC_0)) continue;
        if((!keep_topo) && (ta->a[i].f == RC_1)) continue;
        if((!keep_read) && (ta->a[i].f == RC_2)) continue;
        if((!keep_base) && (ta->a[i].f == RC_3)) continue;
        ta->a[m++] = ta->a[i];
    }
    ta->n = m;
}

// Assembly:
testl %esi, %esi
setne %al
testl %edx, %edx
setne %r9b
andb %al, %r9b
testl %ecx, %ecx
setne %al
andb %r9b, %al
testl %r8d, %r8d
setne %r9b
testb %r9b, %al
jne 0xc2b65
xorl %eax, %eax
cmpq $0x0, (%rdi)
je 0xc2b62
pushq %rbx
movl $0x1, %r9d
xorl %r10d, %r10d
testb %sil, %sil
jne 0xc2ab8
movq 0x10(%rdi), %r11
leaq (%r10,%r10,2), %rbx
shlq $0x4, %rbx
testb $0x3f, 0x28(%r11,%rbx)
je 0xc2b50
testb %dl, %dl
jne 0xc2ad7
movq 0x10(%rdi), %r11
leaq (%r10,%r10,2), %rbx
shlq $0x4, %rbx
movb 0x28(%r11,%rbx), %r11b
andb $0x3f, %r11b
cmpb $0x1, %r11b
je 0xc2b50
testb %cl, %cl
jne 0xc2af6
movq 0x10(%rdi), %r11
leaq (%r10,%r10,2), %rbx
shlq $0x4, %rbx
movb 0x28(%r11,%rbx), %r11b
andb $0x3f, %r11b
cmpb $0x2, %r11b
je 0xc2b50
testb %r8b, %r8b
jne 0xc2b16
movq 0x10(%rdi), %r11
leaq (%r10,%r10,2), %rbx
shlq $0x4, %rbx
movb 0x28(%r11,%rbx), %r11b
andb $0x3f, %r11b
cmpb $0x3, %r11b
je 0xc2b50
movq 0x10(%rdi), %r11
leaq (%r10,%r10,2), %r10
shlq $0x4, %r10
movl %eax, %ebx
incl %eax
leaq (%rbx,%rbx,2), %rbx
shlq $0x4, %rbx
movups (%r11,%r10), %xmm0
movups 0x10(%r11,%r10), %xmm1
movups 0x20(%r11,%r10), %xmm2
movups %xmm2, 0x20(%r11,%rbx)
movups %xmm1, 0x10(%r11,%rbx)
movups %xmm0, (%r11,%rbx)
movl %r9d, %r10d
incl %r9d
cmpq %r10, (%rdi)
ja 0xc2a9b
movl %eax, %eax
popq %rbx
movq %rax, (%rdi)
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: is_connect_arc(u_trans_t*, u_trans_t*, ma_ug_t*, double)
uint32_t is_connect_arc(u_trans_t *li, u_trans_t *lj, ma_ug_t *ug, double diff_ec_ul)
{
    if(li->qs >= lj->qs && li->qe >= lj->qe) {
        int64_t dq = infer_utrans_ovlp_len(li, lj, ug);
        uint32_t v = (li->tn<<1)|li->rev, w = (lj->tn<<1)|lj->rev;
        int64_t dt = -1, dif, mm; uint32_t nv, i; asg_arc_t *av;
        nv = asg_arc_n(ug->g, v); av = asg_arc_a(ug->g, v);
		for (i = 0; i < nv; i++) {
			if(av[i].del || av[i].v != w) continue;
			dt = av[i].ol;
			break;
		}

        if(dt < 0) return 0;
	    dif = (dq>dt? dq-dt:dt-dq);
	    mm = MAX(dq, dt); mm *= diff_ec_ul; if(mm < 8) mm = 8;
        if(dif <= mm) return 1;
    }
    return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl (%rdi), %eax
cmpl (%rsi), %eax
jb 0xc31f3
movq %rsi, %rbx
movq %rdi, %r15
movl 0x4(%rdi), %eax
cmpl 0x4(%rsi), %eax
jb 0xc31f3
movq %rdx, %r14
movsd %xmm0, 0x8(%rsp)
movq %r15, %rdi
movq %rbx, %rsi
callq 0xc2f39
movl 0x14(%r15), %ecx
movl 0x28(%r15), %edx
shrl $0x6, %edx
andl $0x1, %edx
leal (%rdx,%rcx,2), %ecx
movq 0x18(%r14), %rsi
movq 0x28(%rsi), %rdx
movq (%rdx,%rcx,8), %rdx
testl %edx, %edx
je 0xc319e
movl 0x14(%rbx), %ecx
movl 0x28(%rbx), %edi
shrl $0x6, %edi
andl $0x1, %edi
leal (%rdi,%rcx,2), %ecx
movq 0x8(%rsi), %rsi
movq %rdx, %rdi
shrq $0x20, %rdi
movl %edx, %edx
leaq (%rdi,%rdi,2), %rdi
leaq (%rsi,%rdi,8), %rsi
addq $0xc, %rsi
shlq $0x3, %rdx
leaq (%rdx,%rdx,2), %rdi
xorl %r8d, %r8d
movslq (%rsi,%r8), %rdx
testq %rdx, %rdx
js 0xc3195
cmpl %ecx, -0x4(%rsi,%r8)
je 0xc31a5
addq $0x18, %r8
cmpq %r8, %rdi
jne 0xc3185
movq $-0x1, %rdx
testq %rdx, %rdx
js 0xc31eb
movq %rax, %rcx
subq %rdx, %rcx
cmovgq %rax, %rdx
movq %rcx, %rax
negq %rax
cmovsq %rcx, %rax
xorps %xmm0, %xmm0
cvtsi2sd %rdx, %xmm0
mulsd 0x8(%rsp), %xmm0
cvttsd2si %xmm0, %rcx
cmpq $0x9, %rcx
movl $0x8, %edx
cmovgeq %rcx, %rdx
cmpq %rdx, %rax
seta %cl
movl $0x1, %eax
jmp 0xc31ef
xorl %eax, %eax
xorl %ecx, %ecx
testb %cl, %cl
je 0xc31f5
xorl %eax, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: kt_u_trans_t_idx(kv_u_trans_t*, unsigned int)
void kt_u_trans_t_idx(kv_u_trans_t *ta, uint32_t n)
{
    radix_sort_u_trans(ta->a, ta->a + ta->n);
    kv_resize(uint64_t, ta->idx, n);
    ta->idx.n = n;
    memset(ta->idx.a, 0, ta->idx.n*sizeof(uint64_t));
    uint32_t st, i;
    for (st = 0, i = 1; i <= ta->n; ++i)
    {
        if (i == ta->n || ta->a[i].qn != ta->a[st].qn)
        {
            ta->idx.a[ta->a[st].qn] = (uint64_t)st << 32 | (i - st);
            st = i;
        }
    }
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %ebp
movq %rdi, %rbx
movq (%rdi), %rax
movq 0x10(%rdi), %rdi
leaq (%rax,%rax,2), %rsi
shlq $0x4, %rsi
addq %rdi, %rsi
callq 0x9df03
movl %ebp, %r14d
cmpq %r14, 0x20(%rbx)
jae 0xc40d5
leaq -0x1(%r14), %rax
movq %rax, %rcx
shrq %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x2, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x4, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x8, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x10, %rcx
orq %rax, %rcx
leaq 0x1(%rcx), %rax
movq %rax, 0x20(%rbx)
movq 0x28(%rbx), %rdi
leaq 0x8(,%rcx,8), %rsi
callq 0x2370
movq %rax, 0x28(%rbx)
movq %r14, 0x18(%rbx)
movq 0x28(%rbx), %rdi
shlq $0x3, %r14
xorl %ebp, %ebp
xorl %esi, %esi
movq %r14, %rdx
callq 0x20e0
movq (%rbx), %rcx
testq %rcx, %rcx
je 0xc4156
movl $0x1, %eax
movl $0x1, %esi
movl %ebp, %edx
cmpq %rsi, %rcx
je 0xc4124
movq 0x10(%rbx), %rcx
leaq (%rsi,%rsi,2), %rsi
shlq $0x4, %rsi
movl 0x8(%rcx,%rsi), %esi
leaq (%rdx,%rdx,2), %rdi
shlq $0x4, %rdi
cmpl 0x8(%rcx,%rdi), %esi
je 0xc4149
leaq (%rdx,%rdx,2), %rcx
shlq $0x20, %rdx
movl %eax, %esi
subl %ebp, %esi
orq %rdx, %rsi
movq 0x10(%rbx), %rdx
movq 0x28(%rbx), %rdi
shlq $0x4, %rcx
movl 0x8(%rdx,%rcx), %ecx
movq %rsi, (%rdi,%rcx,8)
movl %eax, %ebp
incl %eax
movq (%rbx), %rcx
movq %rax, %rsi
cmpq %rax, %rcx
jae 0xc40ff
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: refine_hic_trans(ug_opt_t*, kv_u_trans_t*, asg_t*, ma_ug_t*)
void refine_hic_trans(ug_opt_t *opt, kv_u_trans_t *ta, asg_t *sg, ma_ug_t *ug)
{
    filter_u_trans(ta, asm_opt.is_bub_trans, asm_opt.is_topo_trans, asm_opt.is_read_trans, asm_opt.is_base_trans);
    if(asm_opt.is_base_trans) {
        trans_base_infer(ug, sg, opt, ta, NULL);
    } 
    // dbg_prt_utg_trans(ta, ug, "pre");
    clean_u_trans_t_idx_filter_adv(ta, ug, sg, 0.95, 0);
    // dbg_prt_utg_trans(ta, ug, "after");
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rcx, %r14
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r12
leaq 0x1c4d4f(%rip), %r13    # 0x28a758
movzbl 0x24d(%r13), %esi
movzbl 0x24c(%r13), %edx
movzbl 0x24b(%r13), %ecx
movzbl 0x24a(%r13), %r8d
movq %r15, %rdi
callq 0xc2a5f
cmpb $0x0, 0x24a(%r13)
je 0xc5a4f
movq %r14, %rdi
movq %rbx, %rsi
movq %r12, %rdx
movq %r15, %rcx
xorl %r8d, %r8d
callq 0x1e0907
movsd 0x15fa41(%rip), %xmm0   # 0x225498
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
xorl %ecx, %ecx
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0xc476d
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: set_rset(ma_ug_t*, unsigned int, unsigned char*, unsigned char)
void set_rset(ma_ug_t *ug, uint32_t uid, uint8_t *ff, uint8_t s)
{
    if(ug->g->seq[uid].del) return;
    ma_utg_t* u; uint32_t k, v, nv, w, z; 
    asg_arc_t *av = NULL;

    u = &(ug->u.a[uid]);
    for (k = 0; k < u->n; k++) ff[u->a[k]>>33] = s;

    v = uid<<1; 
    nv = asg_arc_n(ug->g, v);
    av = asg_arc_a(ug->g, v);
    for (k = 0; k < nv; k++) {
        w = av[k].v;
        if(av[k].del) continue;
        if(ug->g->seq[w>>1].del) continue;
        u = &(ug->u.a[w>>1]);
        for (z = 0; z < u->n; z++) ff[u->a[z]>>33] = s;
    }
        
    v = (uid<<1)+1; 
    nv = asg_arc_n(ug->g, v);
    av = asg_arc_a(ug->g, v);
    for (k = 0; k < nv; k++) {
        w = av[k].v;
        if(av[k].del) continue;
        if(ug->g->seq[w>>1].del) continue;
        u = &(ug->u.a[w>>1]);
        for (z = 0; z < u->n; z++) ff[u->a[z]>>33] = s;
    }
}

// Assembly:
pushq %rbx
movq 0x18(%rdi), %rax
movq 0x20(%rax), %r8
movl %esi, %eax
cmpl $0x0, (%r8,%rax,8)
js 0xc5bd1
movq 0x10(%rdi), %r8
leaq (%rax,%rax,4), %rax
cmpl $0x0, 0x10(%r8,%rax,8)
je 0xc5ab9
leaq (%r8,%rax,8), %rax
xorl %r8d, %r8d
movq 0x18(%rax), %r9
movq (%r9,%r8,8), %r9
shrq $0x21, %r9
movb %cl, (%rdx,%r9)
incq %r8
movl 0x10(%rax), %r9d
cmpq %r9, %r8
jb 0xc5a9d
addl %esi, %esi
movq 0x18(%rdi), %r8
movq 0x28(%r8), %rax
movq (%rax,%rsi,8), %r9
testl %r9d, %r9d
je 0xc5b45
movq %r9, %rax
shrq $0x20, %rax
leaq (%rax,%rax,2), %rax
shlq $0x3, %rax
addq 0x8(%r8), %rax
movl %r9d, %r8d
xorl %r9d, %r9d
leaq (%r9,%r9,2), %r10
cmpl $0x0, 0xc(%rax,%r10,8)
js 0xc5b3d
leaq (%rax,%r10,8), %r10
movl 0x8(%r10), %r10d
movq 0x18(%rdi), %r11
movq 0x20(%r11), %r11
shrl %r10d
cmpl $0x0, (%r11,%r10,8)
js 0xc5b3d
movq 0x10(%rdi), %r11
leaq (%r10,%r10,4), %r10
cmpl $0x0, 0x10(%r11,%r10,8)
je 0xc5b3d
leaq (%r11,%r10,8), %r10
xorl %r11d, %r11d
movq 0x18(%r10), %rbx
movq (%rbx,%r11,8), %rbx
shrq $0x21, %rbx
movb %cl, (%rdx,%rbx)
incq %r11
movl 0x10(%r10), %ebx
cmpq %rbx, %r11
jb 0xc5b22
incq %r9
cmpq %r8, %r9
jne 0xc5ae5
movq 0x18(%rdi), %r8
movq 0x28(%r8), %rax
movl %esi, %esi
movq 0x8(%rax,%rsi,8), %rsi
testl %esi, %esi
je 0xc5bd1
movq %rsi, %rax
shrq $0x20, %rax
leaq (%rax,%rax,2), %rax
shlq $0x3, %rax
addq 0x8(%r8), %rax
movl %esi, %esi
xorl %r8d, %r8d
leaq (%r8,%r8,2), %r9
cmpl $0x0, 0xc(%rax,%r9,8)
js 0xc5bc9
leaq (%rax,%r9,8), %r9
movl 0x8(%r9), %r9d
movq 0x18(%rdi), %r10
movq 0x20(%r10), %r10
shrl %r9d
cmpl $0x0, (%r10,%r9,8)
js 0xc5bc9
movq 0x10(%rdi), %r10
leaq (%r9,%r9,4), %r9
cmpl $0x0, 0x10(%r10,%r9,8)
je 0xc5bc9
leaq (%r10,%r9,8), %r9
xorl %r10d, %r10d
movq 0x18(%r9), %r11
movq (%r11,%r10,8), %r11
shrq $0x21, %r11
movb %cl, (%rdx,%r11)
incq %r10
movl 0x10(%r9), %r11d
cmpq %r11, %r10
jb 0xc5bad
incq %r8
cmpq %rsi, %r8
jne 0xc5b70
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: check_nc_status(asg_t*, ma_hit_t_alloc*, unsigned char*, unsigned int)
uint32_t check_nc_status(asg_t *sg, ma_hit_t_alloc *src, uint8_t *ff, uint32_t id)
{
    uint32_t i, tn; ma_hit_t *h;
    for (i = 0; i < src[id].length; i++) {
        h = &(src[id].buffer[i]); tn = Get_tn((*h));
        if(sg->seq[tn].del) continue;
        if(!ff[tn]) continue;
        if((Get_qs((*h)) == 0) && (Get_qe((*h)) == sg->seq[id].len)) return 1;
    }
    return 0;
}

// Assembly:
movl %ecx, %eax
leaq (%rax,%rax,2), %rcx
movl 0xc(%rsi,%rcx,8), %r8d
testq %r8, %r8
je 0xc5c30
leaq (%rsi,%rcx,8), %rcx
movq (%rcx), %rcx
movq 0x20(%rdi), %rsi
shlq $0x3, %r8
leaq (%r8,%r8,4), %rdi
xorl %r8d, %r8d
movl $0x7fffffff, %r9d       # imm = 0x7FFFFFFF
movl 0xc(%rcx,%r8), %r10d
cmpl $0x0, (%rsi,%r10,8)
js 0xc5c27
cmpb $0x0, (%rdx,%r10)
je 0xc5c27
cmpl $0x0, (%rcx,%r8)
jne 0xc5c27
movl (%rsi,%rax,8), %r10d
andl %r9d, %r10d
cmpl %r10d, 0x8(%rcx,%r8)
je 0xc5c33
addq $0x28, %r8
cmpq %r8, %rdi
jne 0xc5bff
xorl %eax, %eax
retq
movl $0x1, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: fill_cov_arr(ma_ug_t*, asg_t*, ma_hit_t_alloc*, unsigned char*, unsigned long, unsigned long*)
void fill_cov_arr(ma_ug_t *ug, asg_t *sg, ma_hit_t_alloc *src, uint8_t *ff, uint64_t uid, uint64_t *res)
{
    ma_hit_t *h; ma_utg_t *u;
    uint64_t C_bases, k, j, rid, tn;
    set_rset(ug, uid, ff, 1);

    u = &(ug->u.a[uid]);
    for (k = 0; k < u->n; k++) {
        C_bases = 0; rid = u->a[k]>>33;
        for (j = 0; j < src[rid].length; j++) {
            h = &(src[rid].buffer[j]);
            tn = Get_tn((*h));
            if((!sg->seq[tn].del) && (!ff[tn])) continue;
            if((sg->seq[tn].del) && (!check_nc_status(sg, src, ff, tn))) continue;
            C_bases += (Get_qe((*h)) - Get_qs((*h)));
        }
        res[k] = C_bases;
    }

    set_rset(ug, uid, ff, 0);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %r9, 0x30(%rsp)
movq %r8, %r14
movq %rcx, %r15
movq %rdx, %rbx
movq %rsi, 0x8(%rsp)
movq %rdi, %r12
movl %r14d, %esi
movq %rcx, %rdx
movl $0x1, %ecx
callq 0xc5a70
movq %r15, %rdx
movq %r12, 0x10(%rsp)
movq 0x10(%r12), %rax
movq %r14, 0x18(%rsp)
leaq (%r14,%r14,4), %rcx
movl 0x10(%rax,%rcx,8), %esi
movq %rsi, 0x28(%rsp)
testq %rsi, %rsi
je 0xc5f0d
leaq (%rax,%rcx,8), %rax
movq 0x18(%rax), %rax
movq %rax, 0x20(%rsp)
xorl %ecx, %ecx
movq 0x20(%rsp), %rax
movq %rcx, 0x38(%rsp)
movq (%rax,%rcx,8), %rax
shrq $0x21, %rax
leaq (%rax,%rax,2), %rcx
movl 0xc(%rbx,%rcx,8), %eax
testq %rax, %rax
je 0xc5eee
leaq (%rbx,%rcx,8), %rcx
movq (%rcx), %r13
movq 0x8(%rsp), %rcx
movq 0x20(%rcx), %rcx
movq %rcx, 0x40(%rsp)
shlq $0x3, %rax
leaq (%rax,%rax,4), %rbp
xorl %r12d, %r12d
xorl %r15d, %r15d
movl 0xc(%r13,%r12), %ecx
movq 0x40(%rsp), %rax
movl (%rax,%rcx,8), %eax
testl %eax, %eax
js 0xc5ebf
cmpb $0x0, (%rdx,%rcx)
je 0xc5ee3
testl %eax, %eax
jns 0xc5ed6
movq 0x8(%rsp), %rdi
movq %rbx, %rsi
movq %rdx, %r14
callq 0xc5bd3
movq %r14, %rdx
testl %eax, %eax
je 0xc5ee3
movl 0x8(%r13,%r12), %eax
subl (%r13,%r12), %eax
addq %rax, %r15
addq $0x28, %r12
cmpq %r12, %rbp
jne 0xc5ea4
jmp 0xc5ef1
xorl %r15d, %r15d
movq 0x30(%rsp), %rax
movq 0x38(%rsp), %rcx
movq %r15, (%rax,%rcx,8)
incq %rcx
cmpq 0x28(%rsp), %rcx
jne 0xc5e62
movq 0x10(%rsp), %rdi
movq 0x18(%rsp), %rsi
xorl %ecx, %ecx
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xc5a70
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: gen_ug_rid_cov_t_by_ovlp(kv_u_trans_t*, ug_rid_cov_t*)
void gen_ug_rid_cov_t_by_ovlp(kv_u_trans_t *ta, ug_rid_cov_t *cc)
{
    uint64_t z, k, id, n; u_trans_t *a; 
    for (z = 0; z < cc->ug->g->n_seq; z++) {
        id = z; a = u_trans_a(*ta, id); n = u_trans_n(*ta, id); 
        for (k = 0; k < n; k++) {
            append_cov_line_ug_rid_cov_t(id, cc->cov.a+cc->idx[id], &(a[k]), cc, ((uint64_t)-1), -1);
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq (%rsi), %rax
movq 0x18(%rax), %rax
testl $0x7fffffff, 0x14(%rax) # imm = 0x7FFFFFFF
je 0xc72ea
movq %rsi, %rbx
movq %rdi, %r14
xorl %r12d, %r12d
movl $0xffffffff, %r13d      # imm = 0xFFFFFFFF
movq 0x28(%r14), %rax
movq (%rax,%r12,8), %rax
movq %rax, %rbp
andq %r13, %rbp
je 0xc72d3
shrq $0x20, %rax
leaq (%rax,%rax,2), %r15
shlq $0x4, %r15
addq 0x10(%r14), %r15
movq 0x10(%rbx), %rax
movq (%rax,%r12,8), %rsi
shlq $0x3, %rsi
addq 0x28(%rbx), %rsi
movq %r15, %rdx
movq %rbx, %rcx
movq $-0x1, %r8
movsd 0x15e273(%rip), %xmm0   # 0x225538
callq 0xc6725
addq $0x30, %r15
decq %rbp
jne 0xc72a0
incq %r12
movq (%rbx), %rax
movq 0x18(%rax), %rax
movl 0x14(%rax), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
cmpq %rax, %r12
jb 0xc7280
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: worker_for_trans_sec_simple_cut(void*, long, int)
static void worker_for_trans_sec_simple_cut(void *data, long i, int tid) // callback for kt_for()
{
    u_trans_clean_t *s = (u_trans_clean_t*)data;
    kv_u_trans_t *ta = s->ta; u_trans_t *a, *za;
    uint32_t id = i, n, k, z, zn; 

    a = u_trans_a(*ta, id); n = u_trans_n(*ta, id);
    for (k = 0; k < n; k++) {
        if((!a[k].del)) continue;
        za = u_trans_a(*ta, a[k].tn); zn = u_trans_n(*ta, a[k].tn);
        for (z = 0; z < zn; z++) {
            if(za[z].tn == id) break;
        }
        assert(z < zn);
        if(za[z].del) { ///both a[k] and za[z] have been deleted
            if(a[k].qn < a[k].tn) a[k].occ = za[z].occ = ((uint32_t)-1);
            continue; 
        }
        ///a[k].del == 1 && za[z].del == 0
        if(za[z].qe-za[z].qs >= 3000000) {
            a[k].occ = za[z].occ = 0;
        } else {
            a[k].occ = za[z].occ = ((uint32_t)-1);
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq 0x18(%rdi), %rcx
movq 0x28(%rcx), %rax
movl %esi, %edx
movq (%rax,%rdx,8), %rdi
testl %edi, %edi
je 0xc7a1b
movq 0x10(%rcx), %rcx
movq %rdi, %rdx
shrq $0x20, %rdx
leaq (%rdx,%rdx,2), %rdx
shlq $0x4, %rdx
addq %rcx, %rdx
movl %edi, %edi
xorl %r8d, %r8d
movl $0xffffffff, %r9d       # imm = 0xFFFFFFFF
xorl %r10d, %r10d
leaq (%r10,%r10,2), %r11
shlq $0x4, %r11
cmpb $0x0, 0x28(%rdx,%r11)
jns 0xc7a13
addq %rdx, %r11
movl 0x14(%r11), %r14d
movq (%rax,%r14,8), %r15
testl %r15d, %r15d
je 0xc7a26
movq %r15, %rbx
shrq $0x20, %rbx
leaq (%rbx,%rbx,2), %rbx
shlq $0x4, %rbx
addq %rcx, %rbx
cmpl %esi, 0x14(%rbx)
je 0xc79e8
addq $0x30, %rbx
decl %r15d
jne 0xc79d8
jmp 0xc7a26
cmpb $0x0, 0x28(%rbx)
js 0xc7a05
movl 0x4(%rbx), %ebp
subl (%rbx), %ebp
cmpl $0x2dc6c0, %ebp         # imm = 0x2DC6C0
jb 0xc7a0b
movl %r8d, 0x18(%rbx)
movl %r8d, 0x18(%r11)
jmp 0xc7a13
cmpl %r14d, 0x8(%r11)
jae 0xc7a13
movl %r9d, 0x18(%rbx)
movl %r9d, 0x18(%r11)
incq %r10
cmpq %rdi, %r10
jne 0xc79a6
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x165573(%rip), %rdi    # 0x22cfa0
leaq 0x16226d(%rip), %rsi    # 0x229ca1
leaq 0x16556c(%rip), %rcx    # 0x22cfa7
movl $0x3ef4, %edx           # imm = 0x3EF4
callq 0x2110
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: copy_read_graph(asg_t*)
asg_t* copy_read_graph(asg_t *src)
{
    asg_t *dest = NULL;
    dest = asg_init();

    dest->r_seq = src->r_seq;
    dest->m_seq = dest->n_seq = src->n_seq;
    dest->seq = (asg_seq_t*)malloc(dest->n_seq * sizeof(asg_seq_t));
    memcpy(dest->seq, src->seq, sizeof(asg_seq_t)*dest->n_seq);

    dest->m_arc = dest->n_arc = src->n_arc;
    dest->arc = (asg_arc_t*)malloc(dest->n_arc*sizeof(asg_arc_t));
    memcpy(dest->arc, src->arc, sizeof(asg_arc_t)*dest->n_arc);

    dest->is_srt = src->is_srt;
    dest->is_symm = src->is_symm;
    dest->idx = NULL;
    // dest->idx = (uint64_t*)malloc(dest->n_seq*2*8);
    // memcpy(dest->idx, src->idx, dest->n_seq*2*8); 
    asg_cleanup(dest);

    if(src->seq_vis)
    {
        dest->seq_vis = (uint8_t*)malloc(dest->n_seq*2*sizeof(uint8_t));
        memcpy(dest->seq_vis, src->seq_vis, dest->n_seq*2*sizeof(uint8_t));
    }

    if(src->n_F_seq > 0 && src->F_seq)
    {
        dest->n_F_seq = src->n_F_seq;
        dest->F_seq = (ma_utg_t*)malloc(dest->n_F_seq*sizeof(ma_utg_t));
        memcpy(dest->F_seq, src->F_seq, dest->n_F_seq*sizeof(ma_utg_t));
    }
    return dest;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
movl $0x1, %edi
movl $0x48, %esi
callq 0x2120
movq %rax, %rbx
movl 0x18(%r14), %eax
movl %eax, 0x18(%rbx)
movl 0x14(%r14), %r12d
movl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movq %r12, %r15
andq %rax, %r15
movl $0x80000000, %ebp       # imm = 0x80000000
movl 0x14(%rbx), %eax
andl %ebp, %eax
orl %r15d, %eax
movl %eax, 0x14(%rbx)
movl %r15d, 0x10(%rbx)
shlq $0x3, %r15
movq %r15, %rdi
callq 0x2280
movq %rax, 0x20(%rbx)
movq 0x20(%r14), %rsi
movq %rax, %rdi
movq %r15, %rdx
callq 0x2160
movl 0x4(%r14), %r13d
movq %r13, %rax
movl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
andq %rcx, %rax
andl 0x4(%rbx), %ebp
orl %eax, %ebp
movl %ebp, 0x4(%rbx)
movl %eax, (%rbx)
shlq $0x3, %rax
leaq (%rax,%rax,2), %r15
movq %r15, %rdi
callq 0x2280
movq %rax, 0x8(%rbx)
movq 0x8(%r14), %rsi
movq %rax, %rdi
movq %r15, %rdx
callq 0x2160
movl %r13d, 0x4(%rbx)
movl %r12d, 0x14(%rbx)
movq $0x0, 0x28(%rbx)
movq %rbx, %rdi
callq 0xa02fa
movq 0x30(%r14), %r15
testq %r15, %r15
je 0xc8113
movl 0x14(%rbx), %r12d
addl %r12d, %r12d
movq %r12, %rdi
callq 0x2280
movq %rax, 0x30(%rbx)
movq %rax, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x2160
movl 0x38(%r14), %eax
testq %rax, %rax
je 0xc814a
movq 0x40(%r14), %r14
testq %r14, %r14
je 0xc814a
movl %eax, 0x38(%rbx)
shlq $0x3, %rax
leaq (%rax,%rax,4), %r15
movq %r15, %rdi
callq 0x2280
movq %rax, 0x40(%rbx)
movq %rax, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x2160
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: destory_hap_cov_t(hap_cov_t**)
void destory_hap_cov_t(hap_cov_t **x)
{
    if(*x)
    {
        free((*x)->cov);
        free((*x)->pos_idx);
        free((*x)->is_r_het);
        kv_destroy((*x)->u_buffer.a);
        kv_destroy((*x)->tailIndex.a);
        kv_destroy((*x)->prevIndex.a);
        if((*x)->t_ch) destory_trans_chain(&((*x)->t_ch));
        free((*x));
    }
}

// Assembly:
movq (%rdi), %rax
testq %rax, %rax
je 0xc89bc
pushq %rbx
movq %rdi, %rbx
movq 0x8(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x10(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0xa0(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x50(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x70(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x90(%rax), %rdi
callq 0x2220
movq (%rbx), %rdi
cmpq $0x0, 0xa8(%rdi)
je 0xc89b3
addq $0xa8, %rdi
callq 0xbe6d4
movq (%rbx), %rdi
popq %rbx
jmp 0x2220
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/Overlaps.cpp
// Function: dump_trans_ovlp(trans_chain*, char const*, ma_ug_t*)
uint64_t dump_trans_ovlp(trans_chain* t_ch, const char *fn, ma_ug_t *ug)
{
    char* gfa_name = NULL; MALLOC(gfa_name, strlen(fn)+50);
    sprintf(gfa_name, "%s.trans.bin", fn);
    FILE* fp = fopen(gfa_name, "w"); free(gfa_name);
    if (!fp) return 0;
    if(ug) write_dbug(ug, fp);

    fwrite(&t_ch->r_num, sizeof(t_ch->r_num), 1, fp);
    fwrite(t_ch->ir_het, sizeof(uint8_t), t_ch->r_num, fp);
    uint64_t i;
    fwrite(&t_ch->bed.n, sizeof(t_ch->bed.n), 1, fp);
    for (i = 0; i < t_ch->bed.n; i++) {
        fwrite(&t_ch->bed.a[i].n, sizeof(t_ch->bed.a[i].n), 1, fp);
        fwrite(t_ch->bed.a[i].a, sizeof(bed_interval), t_ch->bed.a[i].n, fp);
    }

    fwrite(&t_ch->k_trans.n, sizeof(t_ch->k_trans.n), 1, fp);
    fwrite(t_ch->k_trans.a, sizeof(u_trans_t), t_ch->k_trans.n, fp);

    fwrite(&t_ch->k_trans.idx.n, sizeof(t_ch->k_trans.idx.n), 1, fp);
    fwrite(t_ch->k_trans.idx.a, sizeof(uint64_t), t_ch->k_trans.idx.n, fp);

    fclose(fp);
    fprintf(stderr, "[M::%s] Dump trans overlaps\n", __func__);
    return 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x2090
leaq 0x32(%rax), %rdi
callq 0x2280
movq %rax, %r13
leaq 0x162338(%rip), %rsi    # 0x22ad22
xorl %r15d, %r15d
movq %rax, %rdi
movq %r12, %rdx
xorl %eax, %eax
callq 0x2050
leaq 0x1739fd(%rip), %rsi    # 0x23c3fe
movq %r13, %rdi
callq 0x2210
movq %rax, %r12
movq %r13, %rdi
callq 0x2220
testq %r12, %r12
jne 0xc8a26
movq %r15, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq %r14, %rdi
movq %r12, %rsi
movq %rbx, %rdx
callq 0x1090e
movl $0x1, %r15d
jmp 0xc8a19