LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/hic.cpp
// Function: prt_hits_noid(ha_ug_index*, ma_ug_t*, kvec_pe_hit*, _IO_FILE*)
void prt_hits_noid(ha_ug_index* idx, ma_ug_t* ug, kvec_pe_hit* hits, FILE *fn)
{
    uint64_t k, shif = 64 - idx->uID_bits;
    char dir[2] = {'+', '-'};
    for (k = 0; k < hits->a.n; ++k) { 
        fprintf(fn, "r-%lu-th\t%c\trs-utg%.6d%c\t%lu\t%c\tre-utg%.6d%c\t%lu\n", 
        hits->a.a[k].id,
        dir[hits->a.a[k].s>>63], (int)((hits->a.a[k].s<<1)>>shif)+1, 
        "lc"[ug->u.a[((hits->a.a[k].s<<1)>>shif)].circ], hits->a.a[k].s&idx->pos_mode,
        dir[hits->a.a[k].e>>63], (int)((hits->a.a[k].e<<1)>>shif)+1, 
        "lc"[ug->u.a[((hits->a.a[k].e<<1)>>shif)].circ], hits->a.a[k].e&idx->pos_mode);        
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, 0x20(%rsp)
movq %rdi, (%rsp)
cmpq $0x0, (%rdx)
je 0x15a9e7
movl $0x40, %ecx
movq (%rsp), %rax
subq 0x18(%rax), %rcx
movq %rcx, 0x10(%rsp)
movl $0x10, %ebp
xorl %r12d, %r12d
movq %rdx, 0x18(%rsp)
movq %rsi, 0x8(%rsp)
movq 0x10(%rdx), %r13
movq -0x10(%r13,%rbp), %r10
movq -0x8(%r13,%rbp), %r14
movq %r10, %rax
leaq (%r10,%r10), %rdi
movq 0x10(%rsp), %r11
movl %r11d, %ecx
shrq %cl, %rdi
movq 0x10(%rsi), %rdx
leaq (%rdi,%rdi,4), %rcx
movl (%rdx,%rcx,8), %r9d
movq (%rsp), %rcx
movq 0x30(%rcx), %r8
leaq (%r14,%r14), %rbx
movl %r11d, %ecx
shrq %cl, %rbx
andq %r8, %r10
leaq (%rbx,%rbx,4), %rcx
movl (%rdx,%rcx,8), %r15d
movq %r14, %r11
andq %r8, %r14
movq (%r13,%rbp), %rdx
shrq $0x3f, %rax
leaq 0xd46cf(%rip), %rsi     # 0x22f04c
movsbl (%rax,%rsi), %ecx
leal 0x1(%rdi), %r8d
shrl $0x1f, %r9d
leaq 0xcdc9b(%rip), %rax     # 0x22862b
movsbl (%r9,%rax), %r9d
shrq $0x3f, %r11
movsbl (%r11,%rsi), %r11d
incl %ebx
shrl $0x1f, %r15d
movsbl (%r15,%rax), %r15d
subq $0x8, %rsp
movq 0x28(%rsp), %rdi
leaq 0xd5c8f(%rip), %rsi     # 0x230648
xorl %eax, %eax
pushq %r14
pushq %r15
pushq %rbx
pushq %r11
pushq %r10
callq 0x22b0
movq 0x38(%rsp), %rsi
movq 0x48(%rsp), %rdx
addq $0x30, %rsp
incq %r12
addq $0x20, %rbp
cmpq (%rdx), %r12
jb 0x15a91e
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/hic.cpp
// Function: prt_utg_trans(kv_u_trans_t*, ma_ug_t*, _IO_FILE*)
void prt_utg_trans(kv_u_trans_t *ta, ma_ug_t* ug, FILE *fn)
{
    uint32_t i;
    u_trans_t *p = NULL;
    for (i = 0; i < ta->n; i++) {
        p = &(ta->a[i]);
        fprintf(fn, "utg%.6u%c\t%u\t%u\t%u\t%c\tutg%.6u%c\t%u\t%u\t%u\tw(%f)\tf(%u)\n", 
        p->qn+1, "lc"[ug->u.a[p->qn].circ], ug->u.a[p->qn].len, p->qs, p->qe, "+-"[p->rev],
        p->tn+1, "lc"[ug->u.a[p->tn].circ], ug->u.a[p->tn].len, p->ts, p->te, p->nw, p->f);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, 0x18(%rsp)
cmpq $0x0, (%rdi)
je 0x15ab00
movl $0x1, %ebp
xorl %ecx, %ecx
movq %rsi, 0x10(%rsp)
movq %rdi, 0x8(%rsp)
movq 0x10(%rdi), %rax
leaq (%rcx,%rcx,2), %r10
shlq $0x4, %r10
movl 0x8(%rax,%r10), %ecx
leal 0x1(%rcx), %edx
movq 0x10(%rsi), %rdi
leaq (%rcx,%rcx,4), %rcx
movl (%rdi,%rcx,8), %r8d
movl %r8d, %ecx
shrl $0x1f, %ecx
leaq 0xcdbda(%rip), %rsi     # 0x22862b
movsbl (%rcx,%rsi), %ecx
movl $0x7fffffff, %esi       # imm = 0x7FFFFFFF
andl %esi, %r8d
movl (%rax,%r10), %r9d
movl 0x4(%rax,%r10), %r11d
movq %r11, 0x20(%rsp)
movzbl 0x28(%rax,%r10), %r14d
btl $0x6, %r14d
leaq 0xcb746(%rip), %r11     # 0x2261c3
adcq $0x0, %r11
movsbl (%r11), %r11d
movl 0x14(%rax,%r10), %r13d
leal 0x1(%r13), %ebx
leaq (%r13,%r13,4), %r13
movl (%rdi,%r13,8), %r13d
movl 0xc(%rax,%r10), %r12d
movsd 0x20(%rax,%r10), %xmm0
movl 0x10(%rax,%r10), %r15d
movl %r13d, %eax
shrl $0x1f, %eax
leaq 0xcdb76(%rip), %rdi     # 0x22862b
movsbl (%rax,%rdi), %r10d
andl %esi, %r13d
andl $0x3f, %r14d
movq 0x18(%rsp), %rdi
leaq 0xcfffa(%rip), %rsi     # 0x22aac7
movb $0x1, %al
pushq %r14
pushq %r15
pushq %r12
pushq %r13
pushq %r10
pushq %rbx
pushq %r11
pushq 0x58(%rsp)
callq 0x22b0
movq 0x48(%rsp), %rdi
movq 0x50(%rsp), %rsi
addq $0x40, %rsp
movl %ebp, %ecx
incl %ebp
cmpq %rcx, (%rdi)
ja 0x15aa24
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/hic.cpp
// Function: prt_kv_u_trans(kv_u_trans_t*, hc_links*, signed char*, _IO_FILE*)
void prt_kv_u_trans(kv_u_trans_t *ta, hc_links* lk, int8_t *s, FILE *fn)
{
    uint32_t i;
    u_trans_t *p = NULL;
    hc_edge *e = NULL;

    for (i = 0; i < ta->n; i++) {
        p = &(ta->a[i]);
        e = get_hc_edge(lk, p->qn, p->tn, 0);
        fprintf(fn, "s-utg%.6ul\tS(%d)\td-utg%.6ul\tS(%d)\trev(%u)\td(%lld)\ttw(%f)\n", 
        p->qn+1, s[p->qn], p->tn+1, s[p->tn], p->rev, 
        (e == NULL || e->dis == (uint64_t)-1)? -1 : (long long)(e->dis>>3), p->nw);
    }
}

// Assembly:
cmpq $0x0, (%rdi)
je 0x15abff
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %r12
xorl %ebp, %ebp
leaq 0xd5841(%rip), %r13     # 0x23037a
movq 0x10(%r12), %rax
leaq (,%rbp,2), %rdx
addq %rbp, %rdx
shlq $0x4, %rdx
movl 0x8(%rax,%rdx), %ecx
movl 0x14(%rax,%rdx), %esi
cmpq %rcx, (%r15)
jbe 0x15ab88
movq 0x10(%r15), %rdi
leaq (%rcx,%rcx,2), %r9
shlq $0x4, %r9
movq (%rdi,%r9), %r8
testq %r8, %r8
je 0x15ab88
movq 0x10(%rdi,%r9), %rdi
cmpb $0x0, 0x18(%rdi)
js 0x15ab7f
cmpl %esi, 0x8(%rdi)
je 0x15ab8a
addq $0x28, %rdi
decq %r8
jne 0x15ab74
xorl %edi, %edi
testq %rdi, %rdi
je 0x15aba4
movq 0x10(%rdi), %rdi
movq %rdi, %r10
shrq $0x3, %r10
cmpq $-0x1, %rdi
cmoveq %rdi, %r10
jmp 0x15abab
movq $-0x1, %r10
addq %rdx, %rax
leal 0x1(%rcx), %edx
movsbl (%r14,%rcx), %ecx
leal 0x1(%rsi), %r8d
movsbl (%r14,%rsi), %r9d
movl 0x28(%rax), %r11d
shrl $0x6, %r11d
andl $0x1, %r11d
movsd 0x20(%rax), %xmm0
movq %rbx, %rdi
movq %r13, %rsi
movb $0x1, %al
pushq %r10
pushq %r11
callq 0x22b0
addq $0x10, %rsp
incl %ebp
cmpq %rbp, (%r12)
ja 0x15ab39
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/hic.cpp
// Function: load_psg_t(psg_t**, char const*)
int load_psg_t(psg_t **sg, const char *fn)
{
    uint64_t flag = 0;
    char *buf = (char*)calloc(strlen(fn) + 25, 1);
    sprintf(buf, "%s.hic.pst.bin", fn);
    FILE* fp = NULL; 
    fp = fopen(buf, "r"); 
    if(!fp) return 0;
    CALLOC(*sg, 1);
    flag += fread(&((*sg)->xs), sizeof((*sg)->xs), 1, fp);
    flag += fread(&((*sg)->sg.n), sizeof((*sg)->sg.n), 1, fp);
    (*sg)->sg.m = (*sg)->sg.n;
    MALLOC((*sg)->sg.a, (*sg)->sg.n);
    flag += fread((*sg)->sg.a, sizeof(mc_gg_status), (*sg)->sg.n, fp);

    fclose(fp);
    free(buf);
    return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %r15
movq %rdi, %r14
movq %rsi, %rdi
callq 0x2090
leaq 0x19(%rax), %rdi
movl $0x1, %esi
callq 0x2120
movq %rax, %rbx
leaq 0xd4b12(%rip), %rsi     # 0x2304bf
xorl %ebp, %ebp
movq %rax, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0x2050
leaq 0xd7be4(%rip), %rsi     # 0x2335a7
movq %rbx, %rdi
callq 0x2210
testq %rax, %rax
je 0x15ba5e
movq %rax, %r15
movl $0x1, %edi
movl $0x20, %esi
callq 0x2120
movq %rax, (%r14)
leaq 0x18(%rax), %rdi
movl $0x8, %esi
movl $0x1, %edx
movq %r15, %rcx
callq 0x22f0
movq (%r14), %rdi
addq $0x8, %rdi
movl $0x8, %esi
movl $0x1, %edx
movq %r15, %rcx
callq 0x22f0
movq (%r14), %r12
movq 0x8(%r12), %rdi
movq %rdi, 0x10(%r12)
shlq $0x5, %rdi
callq 0x2280
movq %rax, (%r12)
movq (%r14), %rax
movq (%rax), %rdi
movq 0x8(%rax), %rdx
movl $0x20, %esi
movq %r15, %rcx
callq 0x22f0
movq %r15, %rdi
callq 0x2190
movq %rbx, %rdi
callq 0x2220
movl $0x1, %ebp
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/hic.cpp
// Function: write_psg_t(psg_t*, char const*)
void write_psg_t(psg_t *sg, const char *fn)
{
    char *buf = (char*)calloc(strlen(fn) + 25, 1);
    sprintf(buf, "%s.hic.pst.bin", fn);
    FILE* fp = fopen(buf, "w");

    fwrite(&(sg->xs), sizeof(sg->xs), 1, fp);
    fwrite(&(sg->sg.n), sizeof(sg->sg.n), 1, fp);
    fwrite(sg->sg.a, sizeof(mc_gg_status), sg->sg.n, fp);

    fclose(fp);
    free(buf);
}

// Assembly:
pushq %r15
pushq %r14
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 0xd4a2b(%rip), %rsi     # 0x2304bf
movq %rax, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0x2050
leaq 0xe0956(%rip), %rsi     # 0x23c3fe
movq %r14, %rdi
callq 0x2210
movq %rax, %r15
leaq 0x18(%rbx), %rdi
movl $0x8, %esi
movl $0x1, %edx
movq %rax, %rcx
callq 0x2410
leaq 0x8(%rbx), %rdi
movl $0x8, %esi
movl $0x1, %edx
movq %r15, %rcx
callq 0x2410
movq (%rbx), %rdi
movq 0x8(%rbx), %rdx
movl $0x20, %esi
movq %r15, %rcx
callq 0x2410
movq %r15, %rdi
callq 0x2190
movq %r14, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x2220
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/hic.cpp
// Function: init_psg_t(unsigned long, ma_ug_t*, asg_t*, ug_opt_t*)
psg_t* init_psg_t(uint64_t seed, ma_ug_t* ug, asg_t* rg, ug_opt_t *opt)
{
    psg_t *s = NULL; CALLOC(s, 1);
    s->xs = seed;
    
    kv_gg_status *sa = init_mc_gg_status(ug, rg, opt->coverage_cut, opt->sources, opt->ruIndex, 
    asm_opt.hom_global_coverage_set?asm_opt.hom_global_coverage:((double)asm_opt.hom_global_coverage)/((double)HOM_PEAK_RATE), 
    asm_opt.polyploidy);

    s->sg = *sa;
    free(sa);
    return s;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rcx, %r12
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %r13
movl $0x1, %edi
movl $0x20, %esi
callq 0x2120
movq %rax, %rbx
movq %r13, 0x18(%rax)
movq (%r12), %rdx
movq 0x8(%r12), %rcx
movq 0x30(%r12), %r8
leaq 0x12ec0c(%rip), %rax    # 0x28a758
cmpl $0x0, 0x148(%rax)
cvtsi2sdl 0x144(%rax), %xmm0
jne 0x15bb65
divsd 0xce003(%rip), %xmm0    # 0x229b68
cvttsd2si %xmm0, %rsi
movq %rsi, %rdi
subsd 0xc96f3(%rip), %xmm0    # 0x225268
cvttsd2si %xmm0, %r9
sarq $0x3f, %rdi
andq %rdi, %r9
orq %rsi, %r9
movzwl 0x1bc(%rax), %eax
movl %eax, (%rsp)
movq %r15, %rdi
movq %r14, %rsi
callq 0x1f135
movups (%rax), %xmm0
movups %xmm0, (%rbx)
movq 0x10(%rax), %rcx
movq %rcx, 0x10(%rbx)
movq %rax, %rdi
callq 0x2220
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/hic.cpp
// Function: gen_mmhap_bub(ma_ug_t*, unsigned char*, kv_u_trans_t*, mmhap_t*)
bubble_type *gen_mmhap_bub(ma_ug_t* ug, uint8_t *r_het_flag, kv_u_trans_t *ref, mmhap_t *hh)
{
    uint64_t k;
    bubble_type *p; CALLOC(p, 1); p->n_round = asm_opt.n_weight; p->round_id = 0;
    identify_bubbles(ug, p, r_het_flag, ref);
    for (k = 0; k < ug->g->n_seq; k++) {
        if(IF_BUB(k, (*p))) continue;
        if(IF_HOM(k, (*p))) {
            if(hh->h.a[k].n < hh->h.a[k].m) p->index[k] = p->num.n;
        } else if(IF_HET(k, (*p))) {
            if(hh->h.a[k].n >= hh->h.a[k].m) p->index[k] = (uint32_t)-1;
        }
    }
    return p;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %r13
movl $0x1, %ebp
movl $0x1, %edi
movl $0x110, %esi            # imm = 0x110
callq 0x2120
movq %rax, %r14
leaq 0x12e8e8(%rip), %rax    # 0x28a758
movl 0x1e0(%rax), %eax
movl %eax, 0xc(%r14)
movl $0x0, 0x8(%r14)
movq %r13, %rdi
movq %r14, %rsi
movq %r12, %rdx
movq %r15, %rcx
callq 0x138ab3
movq 0x18(%r13), %rax
testl $0x7fffffff, 0x14(%rax) # imm = 0x7FFFFFFF
je 0x15befc
movq (%r14), %rcx
movq 0x80(%r14), %rdx
incq %rdx
xorl %esi, %esi
movl (%rcx,%rsi,4), %edi
cmpq %rdi, %rdx
ja 0x15bee7
jae 0x15bece
movq 0x10(%rbx), %rdi
movl -0x4(%rdi,%rbp,4), %r8d
cmpl (%rdi,%rbp,4), %r8d
jae 0x15bee7
movl 0x30(%r14), %edi
jmp 0x15bee4
jne 0x15bee7
movq 0x10(%rbx), %r8
movl -0x4(%r8,%rbp,4), %r9d
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
cmpl (%r8,%rbp,4), %r9d
jb 0x15bee7
movl %edi, (%rcx,%rsi,4)
incq %rsi
movl 0x14(%rax), %edi
andl $0x7fffffff, %edi       # imm = 0x7FFFFFFF
addq $0x3, %rbp
cmpq %rdi, %rsi
jb 0x15beaf
movq %r14, %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/hic.cpp
// Function: exchange_kv_u_trans_t(kv_u_trans_t*, kv_u_trans_t*)
void exchange_kv_u_trans_t(kv_u_trans_t *a, kv_u_trans_t *b)
{
    uint64_t k, *ua; u_trans_t *u;
    k = a->n; a->n = b->n; b->n = k;
    k = a->m; a->m = b->m; b->m = k;
    u = a->a; a->a = b->a; b->a = u;

    k = a->idx.n; a->idx.n = b->idx.n; b->idx.n = k;
    k = a->idx.m; a->idx.m = b->idx.m; b->idx.m = k;
    ua = a->idx.a; a->idx.a = b->idx.a; b->idx.a = ua;
}

// Assembly:
movq (%rdi), %rax
movq (%rsi), %rcx
movq %rcx, (%rdi)
movq %rax, (%rsi)
movq 0x8(%rdi), %rax
movq 0x8(%rsi), %rcx
movq %rcx, 0x8(%rdi)
movq %rax, 0x8(%rsi)
movq 0x10(%rdi), %rax
movq 0x10(%rsi), %rcx
movq %rcx, 0x10(%rdi)
movq %rax, 0x10(%rsi)
movq 0x18(%rdi), %rax
movq 0x18(%rsi), %rcx
movq %rcx, 0x18(%rdi)
movq %rax, 0x18(%rsi)
movq 0x20(%rdi), %rax
movq 0x20(%rsi), %rcx
movq %rcx, 0x20(%rdi)
movq %rax, 0x20(%rsi)
movq 0x28(%rdi), %rax
movq 0x28(%rsi), %rcx
movq %rcx, 0x28(%rdi)
movq %rax, 0x28(%rsi)
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/hic.cpp
// Function: cal_ave_ovlp(u_trans_t*, unsigned long, double)
uint64_t cal_ave_ovlp(u_trans_t *a, uint64_t an, double top)
{
    if(!an) return 0;
    uint64_t k, len, cut, occ, tot;
    for (k = len = 0; k < an; k++) {
        len += a[k].qe - a[k].qs;
    }
    cut = len - (len*top);
    for (k = occ = tot = 0; k < an; k++) {
        if(a[k].qe - a[k].qs < cut) continue;
        occ++; tot += a[k].qe - a[k].qs;
    }
    if(!occ) {
        occ = an; tot = len;
    }
    return tot/occ;
}

// Assembly:
testq %rsi, %rsi
je 0x15c019
leaq 0x4(%rdi), %rax
xorl %ecx, %ecx
movq %rsi, %rdx
movl (%rax), %r8d
subl -0x4(%rax), %r8d
addq %r8, %rcx
addq $0x30, %rax
decq %rdx
jne 0x15bf7d
movq %rcx, %xmm1
punpckldq 0xc92a3(%rip), %xmm1 # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1]
subpd 0xc92ab(%rip), %xmm1    # 0x225250
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
mulsd %xmm2, %xmm0
subsd %xmm0, %xmm2
cvttsd2si %xmm2, %rax
movq %rax, %r8
subsd 0xc929f(%rip), %xmm2    # 0x225268
cvttsd2si %xmm2, %rdx
sarq $0x3f, %r8
andq %r8, %rdx
orq %rax, %rdx
addq $0x4, %rdi
xorl %r8d, %r8d
movq %rsi, %r10
xorl %eax, %eax
xorl %r9d, %r9d
movl (%rdi), %r11d
subl -0x4(%rdi), %r11d
cmpq %rdx, %r11
sbbq $-0x1, %r9
cmpq %rdx, %r11
cmovbq %r8, %r11
addq %r11, %rax
addq $0x30, %rdi
decq %r10
jne 0x15bfe7
testq %r9, %r9
cmovneq %r9, %rsi
cmoveq %rcx, %rax
xorl %edx, %edx
divq %rsi
retq
xorl %eax, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/hic.cpp
// Function: hic_analysis(ma_ug_t*, asg_t*, trans_chain*, ug_opt_t*, mmhap_t**, kvec_pe_hit**)
void hic_analysis(ma_ug_t *ug, asg_t* read_g, trans_chain* t_ch, ug_opt_t *opt, mmhap_t **rh, kvec_pe_hit **rhits)
{
    ug_index = NULL;
    int exist = (asm_opt.load_index_from_disk? 
                    load_hc_pt_index(&ug_index, ug, asm_opt.output_file_name) : 0);
    if(exist == 0) ug_index = build_unitig_index(ug, asm_opt.hic_mer_length, asm_opt.hap_occ, 0, asm_opt.thread_num);
    if(exist == 0) write_hc_pt_index(ug_index, asm_opt.output_file_name);
    ug_index->ug = ug;
    ug_index->read_g = read_g;
    ug_index->t_ch = t_ch;
    ///test_unitig_index(ug_index, ug);
    if(!rh) hic_short_align(asm_opt.hic_reads[0], asm_opt.hic_reads[1], ug_index, opt, rhits);
    else hic_short_align_mmhap(asm_opt.hic_reads[0], asm_opt.hic_reads[1], ug_index, opt, rhits, rh);
    // else hic_short_align_poy(asm_opt.hic_reads[0], asm_opt.hic_reads[1], ug_index, opt);
    
    
    destory_hc_pt_index(ug_index);free(ug_index);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r9, (%rsp)
movq %r8, %rbx
movq %rcx, %r15
movq %rdx, %r12
movq %rsi, %r13
movq %rdi, %rbp
movq $0x0, 0x12e963(%rip) # 0x28b530
leaq 0x12db84(%rip), %r14    # 0x28a758
cmpl $0x0, 0xf0(%r14)
je 0x15cc4c
movq 0x10(%r14), %rdx
leaq 0x12e947(%rip), %rdi    # 0x28b530
movq %rbp, %rsi
callq 0x134a44
testl %eax, %eax
je 0x15cc4c
movq 0x12e934(%rip), %rax    # 0x28b530
movq %rbp, (%rax)
movq 0x12e92a(%rip), %rdx    # 0x28b530
movq %r13, 0x8(%rdx)
movq %r12, 0x10(%rdx)
movq 0x50(%r14), %rdi
movq 0x58(%r14), %rsi
testq %rbx, %rbx
je 0x15cc56
movq %r15, %rcx
movq %rbx, %r9
callq 0x15c84c
movq 0x12e903(%rip), %rdi    # 0x28b530
callq 0x134dea
movq 0x12e8f7(%rip), %rdi    # 0x28b530
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x2220
movq %rbp, %rdi
callq 0x1dbb0
jmp 0x15cbf5
movq (%rsp), %r8
callq 0x1b9d3
jmp 0x15cc26
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/hic.cpp
// Function: ug_occ_hap_w(unsigned long, unsigned long, ma_utg_t*)
uint64_t ug_occ_hap_w(uint64_t is, uint64_t ie, ma_utg_t *u)
{
    uint64_t l, i, us, ue, occ;
    for (i = l = occ = 0; i < u->n; i++) {
        us = l; ue = l + Get_READ_LENGTH(R_INF, (u->a[i]>>33));
        if(is <= us && ie >= ue) {
            if((R_INF.trio_flag[u->a[i]>>33] == FATHER) || (R_INF.trio_flag[u->a[i]>>33] == MOTHER)) {
                occ++;
            }
        }
        if(us >= ie) break;
        l += (uint32_t)u->a[i];
    }
    return occ;
}

// Assembly:
movl 0x10(%rdx), %ecx
testq %rcx, %rcx
je 0x15ccce
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
movq 0x18(%rdx), %rdx
leaq 0x12e5b6(%rip), %rax    # 0x28b230
movq 0x18(%rax), %r8
movq 0x28(%rax), %r9
xorl %eax, %eax
xorl %r10d, %r10d
xorl %r11d, %r11d
movq (%rdx,%r11,8), %rbx
cmpq %rdi, %r10
jb 0x15ccb5
movq %rbx, %r14
shrq $0x21, %r14
movq (%r8,%r14,8), %r15
addq %r10, %r15
cmpq %rsi, %r15
ja 0x15ccb5
movb (%r9,%r14), %bpl
decb %bpl
cmpb $0x2, %bpl
adcq $0x0, %rax
cmpq %rsi, %r10
jae 0x15ccc7
movl %ebx, %ebx
addq %rbx, %r10
incq %r11
cmpq %r11, %rcx
jne 0x15cc8a
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
xorl %eax, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/hic.cpp
// Function: set_bench_idx(ma_ug_t*, asg_t*, unsigned long, unsigned long, unsigned long, unsigned long)
uint64_t* set_bench_idx(ma_ug_t *ug, asg_t* read_g, uint64_t uID_start, uint64_t uID_end, uint64_t uID_bits, uint64_t r_n)
{
    uint64_t *idx = (uint64_t*)malloc(sizeof(uint64_t)*r_n), i, k;
    memset(idx, -1, sizeof(uint64_t)*r_n);
    uint64_t rId, ori, start, l;
    ma_utg_t *u = NULL;
    for (i = uID_start; i < uID_end; i++)
    {
        u = &(ug->u.a[i]);
        if(u->n == 0) continue;
        for (k = l = 0; k < u->n; k++)
        {
            rId = u->a[k]>>33;
            ori = u->a[k]>>32&1;
            start = l;
			l += (uint32_t)u->a[k];
            if(idx[rId] != (uint64_t)-1)
            {
                idx[rId] = (uint64_t)-1;
            }
            else
            {
                idx[rId] = (ori<<63) + ((i<<(64-uID_bits))>>1) + start;
                if(ori) idx[rId] = idx[rId] + read_g->seq[rId].len - 1;
            }
        }
    }

    return idx;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r8, (%rsp)
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbp
leaq (,%r9,8), %r13
movq %r13, %rdi
callq 0x2280
movq %rax, %r12
movq %rax, %rdi
movl $0xff, %esi
movq %r13, %rdx
callq 0x20e0
cmpq %rbx, %r14
jae 0x15e0bf
movq 0x10(%rbp), %rax
movl $0x40, %ecx
subq (%rsp), %rcx
leaq (%r14,%r14,4), %rdi
movl 0x10(%rax,%rdi,8), %edx
testq %rdx, %rdx
je 0x15e0b3
movq %r14, %rsi
shlq %cl, %rsi
leaq (%rax,%rdi,8), %rdi
movq 0x18(%rdi), %rdi
xorl %r8d, %r8d
xorl %r9d, %r9d
movq (%rdi,%r9,8), %r10
movq %r10, %r11
shrq $0x21, %r11
movq $-0x1, %r13
cmpq $-0x1, (%r12,%r11,8)
jne 0x15e0a1
movq %r10, %r13
shrq $0x20, %r13
shldq $0x3f, %rsi, %r13
addq %r8, %r13
movq %r13, (%r12,%r11,8)
btq $0x20, %r10
jae 0x15e0a5
movq 0x20(%r15), %rbp
movl (%rbp,%r11,8), %ebp
andl $0x7fffffff, %ebp       # imm = 0x7FFFFFFF
addq %rbp, %r13
decq %r13
movq %r13, (%r12,%r11,8)
movl %r10d, %r10d
addq %r10, %r8
incq %r9
cmpq %r9, %rdx
jne 0x15e059
incq %r14
cmpq %rbx, %r14
jne 0x15e038
movq %r12, %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/hic.cpp
// Function: hap_ID(bench_idx*, unsigned long, unsigned long*, unsigned long*)
void hap_ID(bench_idx* idx, uint64_t ID, uint64_t* hapID, uint64_t* uID)
{
    uint64_t i;
    (*hapID) = (*uID) = (uint64_t)-1;
    for (i = 0; i < idx->ug_idx.n; i++)
    {
        if(ID >= idx->ug_idx.a[i].uID_start && ID < idx->ug_idx.a[i].uID_end)
        {
            (*hapID) = i;
            (*uID) = ID - idx->ug_idx.a[i].uID_start;
            return;
        }
    }
    return;
}

// Assembly:
movq $-0x1, %rax
movq %rax, (%rcx)
movq %rax, (%rdx)
movq (%rdi), %rax
testq %rax, %rax
je 0x15e32b
movq 0x10(%rdi), %rdi
xorl %r8d, %r8d
cmpq %rsi, (%rdi)
ja 0x15e31f
cmpq %rsi, 0x8(%rdi)
ja 0x15e32c
incq %r8
addq $0x28, %rdi
cmpq %r8, %rax
jne 0x15e314
retq
movq %r8, (%rdx)
subq (%rdi), %rsi
movq %rsi, (%rcx)
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/hic.cpp
// Function: print_bench_idx(bench_idx*, ma_ug_t*)
void print_bench_idx(bench_idx* idx, ma_ug_t *ug)
{
    uint64_t i, k, s_uID, s_hapID, d_uID, d_hapID;
    long long x[2] = {1, -1};
    for (i = 0; i < idx->link.a.n; i++)
    {
        for (k = 0; k < idx->link.a.a[i].e.n; k++)
        {
            if(idx->link.a.a[i].e.a[k].del) continue;
            hap_ID(idx, i, &s_hapID, &s_uID);
            hap_ID(idx, idx->link.a.a[i].e.a[k].uID, &d_hapID, &d_uID);
            fprintf(stderr, "s-hap%lu-utg%.6d\td-hap%lu-utg%.6d\t%c\t%lld\n", 
            s_hapID, (int)(s_uID+1), d_hapID, (int)(d_uID+1), 
            "+-"[!!(idx->link.a.a[i].e.a[k].dis&(uint64_t)2)], 
            ((long long)(idx->link.a.a[i].e.a[k].dis>>2))*x[idx->link.a.a[i].e.a[k].dis&(uint64_t)1]);
        }
    }
    
    
}

// Assembly:
cmpq $0x0, 0x28(%rdi)
je 0x15e4bd
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x12bc8a(%rip), %r12    # 0x289fe0
leaq 0xc7e66(%rip), %r14     # 0x2261c3
xorl %ebp, %ebp
movq 0x38(%rbx), %rdi
leaq (,%rbp,2), %r15
addq %rbp, %r15
shlq $0x4, %r15
cmpq $0x0, (%rdi,%r15)
je 0x15e4a2
xorl %r13d, %r13d
movq 0x10(%rdi,%r15), %rcx
leaq (,%r13,4), %rax
addq %r13, %rax
cmpb $0x0, 0x18(%rcx,%rax,8)
jns 0x15e3a9
incq %r13
movq 0x38(%rbx), %rdi
cmpq (%rdi,%r15), %r13
jb 0x15e380
jmp 0x15e4a2
movq (%rbx), %rsi
xorl %r9d, %r9d
movl $0x0, %ecx
movq $-0x1, %rdx
testq %rsi, %rsi
je 0x15e3f6
movq 0x10(%rbx), %rcx
addq $0x8, %rcx
xorl %edx, %edx
movq -0x8(%rcx), %r8
cmpq %r8, %rbp
jb 0x15e3d8
cmpq %rbp, (%rcx)
ja 0x15e3ef
incq %rdx
addq $0x28, %rcx
cmpq %rdx, %rsi
jne 0x15e3ca
xorl %ecx, %ecx
movq $-0x1, %rdx
jmp 0x15e3f6
movl %ebp, %ecx
subl %r8d, %ecx
incl %ecx
movq 0x10(%rdi,%r15), %r10
testq %rsi, %rsi
jne 0x15e409
movq $-0x1, %r8
jmp 0x15e459
movq %r14, %r9
movq %r12, %r14
movl 0x8(%r10,%rax,8), %edi
movq 0x10(%rbx), %r11
addq $0x8, %r11
xorl %r8d, %r8d
movq -0x8(%r11), %r12
cmpq %rdi, %r12
ja 0x15e42d
cmpq %rdi, (%r11)
ja 0x15e44b
incq %r8
addq $0x28, %r11
cmpq %r8, %rsi
jne 0x15e41f
movq $-0x1, %r8
movq %r14, %r12
movq %r9, %r14
xorl %r9d, %r9d
jmp 0x15e459
subl %r12d, %edi
incl %edi
movq %r14, %r12
movq %r9, %r14
movl %edi, %r9d
movq (%r12), %rdi
movq 0x10(%r10,%rax,8), %rax
btl $0x1, %eax
movq %r14, %rsi
adcq $0x0, %rsi
movsbl (%rsi), %r10d
movq %rax, %r11
shrq $0x2, %r11
andl $0x1, %eax
leaq 0xd0b4e(%rip), %rsi     # 0x22efd0
imulq (%rsi,%rax,8), %r11
leaq 0xd253d(%rip), %rsi     # 0x2309cb
xorl %eax, %eax
pushq %r11
pushq %r10
callq 0x22b0
addq $0x10, %rsp
jmp 0x15e397
incq %rbp
cmpq 0x28(%rbx), %rbp
jb 0x15e35f
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/hic.cpp
// Function: init_bench_idx(bench_idx*, asg_t*, ma_ug_t*)
void init_bench_idx(bench_idx* idx, asg_t* read_g, ma_ug_t *ug)
{
    uint64_t i, occ;
    kv_init(idx->ug_idx);
    kv_init(idx->regions);
    kv_malloc(idx->ug_idx, ug->occ.n); idx->ug_idx.n = ug->occ.n;
    for (idx->uID_bits = 1; (uint64_t)(1<<idx->uID_bits)<(uint64_t)ug->u.n; idx->uID_bits++);
    idx->pos_mode = ((uint64_t)-1)>>(idx->uID_bits+1);
    for (i = occ = 0; i < ug->occ.n; i++)
    {
        idx->ug_idx.a[i].uID_start = occ;
        occ += ug->occ.a[i];
        idx->ug_idx.a[i].uID_end = occ;
        idx->ug_idx.a[i].u_n = ug->occ.a[i];

        idx->ug_idx.a[i].r_n = read_g->n_seq;
        idx->ug_idx.a[i].r_idx 
            = set_bench_idx(ug, read_g, idx->ug_idx.a[i].uID_start, idx->ug_idx.a[i].uID_end, 
                                                idx->uID_bits, idx->ug_idx.a[i].r_n);
    }

    init_hc_links(&(idx->link), ug->u.n, NULL);

    for (i = 0; i < idx->ug_idx.n; i++)
    {
        get_r_utg_bench(i, idx, ug);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
xorl %eax, %eax
movq %rax, 0x10(%rdi)
movups %xmm0, 0x58(%rdi)
movq %rax, 0x68(%rdi)
movq 0x20(%rdx), %r12
movq %r12, 0x8(%rdi)
leaq (,%r12,8), %rax
leaq (%rax,%rax,4), %rdi
callq 0x2280
movq %rax, 0x10(%r14)
movq %r12, (%r14)
movq (%rbx), %rax
movl $0x1, %ecx
movl $0x1, %edx
shll %cl, %edx
movslq %edx, %rdx
incq %rcx
cmpq %rdx, %rax
ja 0x15e7c5
leaq -0x1(%rcx), %rax
movq $-0x1, %rdx
shrq %cl, %rdx
movq %rax, 0x18(%r14)
movq %rdx, 0x20(%r14)
cmpq $0x0, 0x20(%rbx)
je 0x15e857
xorl %r13d, %r13d
xorl %edx, %edx
xorl %ebp, %ebp
movq 0x10(%r14), %rax
movq %rdx, (%rax,%r13)
movq 0x30(%rbx), %rcx
movq (%rcx,%rbp,8), %r12
addq %rdx, %r12
movq %r12, 0x8(%rax,%r13)
movq (%rcx,%rbp,8), %rcx
movq %rcx, 0x10(%rax,%r13)
movl 0x14(%r15), %r9d
andl $0x7fffffff, %r9d       # imm = 0x7FFFFFFF
movq %r9, 0x18(%rax,%r13)
movq 0x18(%r14), %r8
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rcx
callq 0x15dfe4
movq 0x10(%r14), %rcx
movq %rax, 0x20(%rcx,%r13)
incq %rbp
addq $0x28, %r13
movq %r12, %rdx
cmpq 0x20(%rbx), %rbp
jb 0x15e7fb
leaq 0x28(%r14), %rdi
movq (%rbx), %rsi
xorl %edx, %edx
callq 0xbe7d2
cmpq $0x0, (%r14)
je 0x15e884
xorl %r15d, %r15d
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x15e0d1
incq %r15
cmpq (%r14), %r15
jb 0x15e86e
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/hic.cpp
// Function: destory_bench_idx(bench_idx*)
void destory_bench_idx(bench_idx* idx)
{
    uint64_t i;
    for (i = 0; i < idx->ug_idx.n; i++)
    {
        free(idx->ug_idx.a[i].r_idx);
    }
    kv_destroy(idx->ug_idx);
    kv_destroy(idx->regions);
    destory_hc_links(&(idx->link));
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
cmpq $0x0, (%rdi)
je 0x15eb42
movl $0x20, %r14d
xorl %r15d, %r15d
movq 0x10(%rbx), %rax
movq (%rax,%r14), %rdi
callq 0x2220
incq %r15
addq $0x28, %r14
cmpq (%rbx), %r15
jb 0x15eb29
movq 0x10(%rbx), %rdi
callq 0x2220
movq 0x68(%rbx), %rdi
callq 0x2220
addq $0x28, %rbx
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0xbe8f4
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/rcut.cpp
// Function: mc_opt_init(mc_opt_t*, int, double, unsigned long)
void mc_opt_init(mc_opt_t *opt, int32_t n_perturb, double f_perturb, uint64_t seed)
{
	memset(opt, 0, sizeof(mc_opt_t));
	opt->n_perturb = n_perturb;
	opt->f_perturb = f_perturb;
	opt->max_iter = 1000;
	opt->seed = seed;
	opt->n_s_perturb = n_perturb;
	opt->n_b_perturb = n_perturb*0.5;
}

// Assembly:
xorps %xmm1, %xmm1
movups %xmm1, (%rdi)
movups %xmm1, 0x10(%rdi)
movl %esi, 0x4(%rdi)
movsd %xmm0, 0x10(%rdi)
movl $0x3e8, (%rdi)          # imm = 0x3E8
movq %rdx, 0x18(%rdi)
xorps %xmm0, %xmm0
cvtsi2sd %esi, %xmm0
mulsd 0xc4d0f(%rip), %xmm0    # 0x2254f0
movl %esi, 0xc(%rdi)
cvttsd2si %xmm0, %eax
movl %eax, 0x8(%rdi)
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/rcut.cpp
// Function: mc_merge_dup(mc_g_t*)
void mc_merge_dup(mc_g_t *mg) // MUST BE sorted
{
	uint32_t i, j, k, st;
	w_t w;
	for (st = 0, i = 1, k = 0; i <= mg->e->ma.n; ++i) {
		if (i == mg->e->ma.n || mg->e->ma.a[i].x != mg->e->ma.a[st].x) {
			if (i - st > 1) {
				for (j = st, w = 0; j < i; ++j) {
					w += mg->e->ma.a[j].w;
				}
				mg->e->ma.a[k] = mg->e->ma.a[st];
				mg->e->ma.a[k++].w = w;
			} else mg->e->ma.a[k++] = mg->e->ma.a[st];
			st = i;
		}
	}
	mg->e->ma.n = k;
}

// Assembly:
movq 0x28(%rdi), %rsi
movq 0x18(%rsi), %r8
xorl %edx, %edx
testq %r8, %r8
je 0x1608c8
movl $0x1, %eax
movl $0x1, %r9d
xorl %ecx, %ecx
cmpq %r9, %r8
je 0x16082e
movq 0x28(%rsi), %r8
shlq $0x4, %r9
movq (%r8,%r9), %r9
movl %edx, %r10d
shlq $0x4, %r10
cmpq (%r8,%r10), %r9
je 0x1608b0
movl %eax, %r9d
subl %edx, %r9d
movl %ecx, %r8d
cmpl $0x2, %r9d
jb 0x160893
xorpd %xmm0, %xmm0
cmpl %edx, %eax
jbe 0x16086b
movl %eax, %r9d
movq 0x28(%rsi), %r10
movl %edx, %r11d
subq %r11, %r9
shlq $0x4, %r11
addq %r11, %r10
addq $0x8, %r10
addsd (%r10), %xmm0
addq $0x10, %r10
decq %r9
jne 0x16085d
movq 0x28(%rsi), %rsi
movl %edx, %edx
shlq $0x4, %rdx
shlq $0x4, %r8
movups (%rsi,%rdx), %xmm1
movups %xmm1, (%rsi,%r8)
movq 0x28(%rdi), %rdx
movq 0x28(%rdx), %rdx
movsd %xmm0, 0x8(%rdx,%r8)
jmp 0x1608ac
movq 0x28(%rsi), %rsi
movl %edx, %edx
shlq $0x4, %rdx
shlq $0x4, %r8
movupd (%rsi,%rdx), %xmm0
movupd %xmm0, (%rsi,%r8)
incl %ecx
movl %eax, %edx
incl %eax
movq 0x28(%rdi), %rsi
movq 0x18(%rsi), %r8
movq %rax, %r9
cmpq %rax, %r8
jae 0x16080c
movl %ecx, %edx
movq %rdx, 0x18(%rsi)
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/rcut.cpp
// Function: mb_merge_dup(mb_g_t*)
void mb_merge_dup(mb_g_t *mbg) // MUST BE sorted
{
	uint32_t i, j, k, st;
	t_w_t w[4];
	for (st = 0, i = 1, k = 0; i <= mbg->e->ma.n; ++i) {
		if (i == mbg->e->ma.n || mbg->e->ma.a[i].x != mbg->e->ma.a[st].x) {
			if (i - st > 1) {
				w[0] = w[1] = w[2] = w[3] = 0;
				for (j = st; j < i; ++j) {
					w[0] += mbg->e->ma.a[j].w[0];
					w[1] += mbg->e->ma.a[j].w[1];
					w[2] += mbg->e->ma.a[j].w[2];
					w[3] += mbg->e->ma.a[j].w[3];
				}
				mbg->e->ma.a[k] = mbg->e->ma.a[st];
				mbg->e->ma.a[k].w[0] = w[0];
				mbg->e->ma.a[k].w[1] = w[1];
				mbg->e->ma.a[k].w[2] = w[2];
				mbg->e->ma.a[k].w[3] = w[3];
				k++;
			} else mbg->e->ma.a[k++] = mbg->e->ma.a[st];
			st = i;
		}
	}
	mbg->e->ma.n = k;
}

// Assembly:
pushq %rbx
movq 0x8(%rdi), %rsi
movq 0x18(%rsi), %r8
xorl %edx, %edx
testq %r8, %r8
je 0x160a12
movl $0x1, %eax
movl $0x1, %r9d
xorl %ecx, %ecx
cmpq %r9, %r8
je 0x160910
movq 0x28(%rsi), %r8
leaq (%r9,%r9,4), %r9
movq (%r8,%r9,8), %r9
movl %edx, %r10d
leaq (%r10,%r10,4), %r10
cmpq (%r8,%r10,8), %r9
je 0x1609fa
movl %eax, %r9d
subl %edx, %r9d
movl %ecx, %r8d
cmpl $0x2, %r9d
jb 0x1609c6
xorpd %xmm0, %xmm0
xorpd %xmm2, %xmm2
xorpd %xmm3, %xmm3
xorpd %xmm1, %xmm1
cmpl %edx, %eax
jbe 0x160970
movl %eax, %r9d
movq 0x28(%rsi), %r10
movl %edx, %r11d
leaq (%r11,%r11,4), %rbx
leaq (%r10,%rbx,8), %r10
addq $0x20, %r10
subq %r11, %r9
addsd -0x18(%r10), %xmm1
addsd -0x10(%r10), %xmm3
addsd -0x8(%r10), %xmm2
addsd (%r10), %xmm0
addq $0x28, %r10
decq %r9
jne 0x160950
movq 0x28(%rsi), %rsi
movl %edx, %edx
leaq (%rdx,%rdx,4), %rdx
shlq $0x3, %r8
leaq (%r8,%r8,4), %r8
movq 0x20(%rsi,%rdx,8), %r9
movq %r9, 0x20(%rsi,%r8)
movups (%rsi,%rdx,8), %xmm4
movups 0x10(%rsi,%rdx,8), %xmm5
movups %xmm5, 0x10(%rsi,%r8)
movups %xmm4, (%rsi,%r8)
movq 0x8(%rdi), %rdx
movq 0x28(%rdx), %rdx
movsd %xmm1, 0x8(%rdx,%r8)
movsd %xmm3, 0x10(%rdx,%r8)
movsd %xmm2, 0x18(%rdx,%r8)
movsd %xmm0, 0x20(%rdx,%r8)
jmp 0x1609f6
movq 0x28(%rsi), %rsi
movl %edx, %edx
leaq (%rdx,%rdx,4), %rdx
leaq (%r8,%r8,4), %r8
movq 0x20(%rsi,%rdx,8), %r9
movq %r9, 0x20(%rsi,%r8,8)
movupd (%rsi,%rdx,8), %xmm0
movupd 0x10(%rsi,%rdx,8), %xmm1
movupd %xmm1, 0x10(%rsi,%r8,8)
movupd %xmm0, (%rsi,%r8,8)
incl %ecx
movl %eax, %edx
incl %eax
movq 0x8(%rdi), %rsi
movq 0x18(%rsi), %r8
movq %rax, %r9
cmpq %rax, %r8
jae 0x1608ee
movl %ecx, %edx
movq %rdx, 0x18(%rsi)
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/rcut.cpp
// Function: init_mc_g_t(ma_ug_t*, asg_t*, signed char*, unsigned int)
mc_g_t *init_mc_g_t(ma_ug_t *ug, asg_t *read_g, int8_t *s, uint32_t renew_s)
{
	mc_g_t *p = NULL; CALLOC(p, 1);
	p->ug = ug;
	p->rg = read_g;
	kv_init(p->s);
	if(s)
	{
		p->s.a = s;
		p->s.n = ug->g->n_seq;
		p->s.m = 0;
		if(renew_s) memset(p->s.a, 0, p->s.n);
	}
	else
	{
		CALLOC(p->s.a, ug->g->n_seq);
		p->s.n = p->s.m = ug->g->n_seq;
	} 
	return p;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %ecx, %ebp
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
movl $0x1, %edi
movl $0x30, %esi
callq 0x2120
movq %rax, %rbx
movq %r15, 0x18(%rax)
movq %r12, 0x20(%rax)
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movq $0x0, 0x10(%rax)
testq %r14, %r14
je 0x160a84
movq %r14, 0x10(%rbx)
movq 0x18(%r15), %rax
movl 0x14(%rax), %edx
andl $0x7fffffff, %edx       # imm = 0x7FFFFFFF
movq %rdx, (%rbx)
movq $0x0, 0x8(%rbx)
testl %ebp, %ebp
je 0x160aab
movq %r14, %rdi
xorl %esi, %esi
callq 0x20e0
jmp 0x160aab
movq 0x18(%r15), %rax
movl 0x14(%rax), %r14d
andl $0x7fffffff, %r14d      # imm = 0x7FFFFFFF
movl $0x1, %esi
movq %r14, %rdi
callq 0x2120
movq %rax, 0x10(%rbx)
movq %r14, 0x8(%rbx)
movq %r14, (%rbx)
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/rcut.cpp
// Function: update_mb_nodes_t(kv_u_trans_t*, mc_match_t*, unsigned int)
mb_nodes_t *update_mb_nodes_t(kv_u_trans_t *ref, mc_match_t* ma, uint32_t occ)
{
	uint32_t i, st;
	uint64_t *cc = NULL;
	mb_nodes_t *x = NULL; CALLOC(x, 1);
	x->bid.n = x->u.n = x->idx.n = 0;
	kv_resize(uint32_t, x->idx, occ);
	x->idx.n = occ;
	memset(x->idx.a, -1, sizeof(uint32_t)*x->idx.n);
	kvec_t_u32_warp stack; kv_init(stack.a);
	uint32_t *flag = NULL; MALLOC(flag, occ);

	cc = mb_nodes_core(ref, ma, occ, flag, &stack);

	for (st = 0, i = 1; i <= occ; ++i) {
        if (i == occ || cc[st]>>32 != cc[i]>>32) {
			assgin_mb_node(x, ref, ma, flag, &stack, cc, st, i - st);
            st = i;
        }
	}
	
	free(cc); free(flag);
	kv_destroy(stack.a);

	/*******************************for debug************************************/
	// debug_mb_nodes(x, ref, ma);
	/*******************************for debug************************************/
	return x;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %edx, %ebp
movq %rsi, 0x8(%rsp)
movq %rdi, %r15
movl $0x1, %edi
movl $0x48, %esi
callq 0x2120
movq %rax, %rbx
xorl %eax, %eax
movq %rax, 0x18(%rbx)
movq %rax, 0x30(%rbx)
movq %rax, (%rbx)
movl %ebp, %r12d
cmpq %r12, 0x20(%rbx)
jae 0x16186a
leaq -0x1(%r12), %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 0x4(,%rcx,4), %rsi
callq 0x2370
movq %rax, 0x28(%rbx)
movq %r12, 0x18(%rbx)
movq 0x28(%rbx), %rdi
shlq $0x2, %r12
movl $0xff, %esi
movq %r12, %rdx
callq 0x20e0
movq %r12, %rdi
callq 0x2280
movq %rax, %r12
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %r8
movaps %xmm0, (%r8)
movq $0x0, 0x10(%r8)
movq %r15, %rdi
movq 0x8(%rsp), %rsi
movl %ebp, %edx
movq %rax, %rcx
callq 0x160d71
movq %rax, %r13
testl %ebp, %ebp
je 0x161910
movl $0x1, %r14d
xorl %eax, %eax
cmpl %r14d, %ebp
je 0x1618dd
movl %eax, %ecx
movl %r14d, %edx
movq (%r13,%rdx,8), %rdx
xorq (%r13,%rcx,8), %rdx
shrq $0x20, %rdx
je 0x161908
movl %r14d, %r10d
subl %eax, %r10d
movq %rbx, %rdi
movq %r15, %rsi
movq 0x8(%rsp), %rdx
movq %r12, %rcx
leaq 0x10(%rsp), %r8
movq %r13, %r9
pushq %r10
pushq %rax
callq 0x160fd7
addq $0x10, %rsp
movl %r14d, %eax
incl %r14d
cmpl %ebp, %r14d
jbe 0x1618c3
movq %r13, %rdi
callq 0x2220
movq %r12, %rdi
callq 0x2220
movq 0x20(%rsp), %rdi
callq 0x2220
movq %rbx, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/rcut.cpp
// Function: mb_edges_idx(mb_match_t*)
static void mb_edges_idx(mb_match_t *ma)
{
	uint32_t st, i;
	kv_resize(uint64_t, ma->idx, ma->n_seq);
	ma->idx.n = ma->n_seq;
	memset(ma->idx.a, 0, ma->idx.n*sizeof(uint64_t));
	for (st = 0, i = 1; i <= ma->ma.n; ++i)
		if (i == ma->ma.n || (ma->ma.a[i].x>>32) != (ma->ma.a[st].x>>32))
			ma->idx.a[ma->ma.a[st].x>>32] = (uint64_t)st << 32 | (i - st), st = i;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl 0x38(%rdi), %eax
cmpq %rax, 0x8(%rdi)
jae 0x161d36
decq %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, 0x8(%rbx)
movq 0x10(%rbx), %rdi
leaq 0x8(,%rcx,8), %rsi
callq 0x2370
movq %rax, 0x10(%rbx)
movl 0x38(%rbx), %edx
movq %rdx, (%rbx)
movq 0x10(%rbx), %rdi
shlq $0x3, %rdx
xorl %ebp, %ebp
xorl %esi, %esi
callq 0x20e0
movq 0x18(%rbx), %rcx
testq %rcx, %rcx
je 0x161db0
movl $0x1, %eax
movl $0x1, %esi
movl %ebp, %edx
cmpq %rsi, %rcx
je 0x161d81
movq 0x28(%rbx), %rcx
leaq (%rsi,%rsi,4), %rsi
leaq (%rdx,%rdx,4), %rdi
movq (%rcx,%rdi,8), %rdi
xorq (%rcx,%rsi,8), %rdi
shrq $0x20, %rdi
je 0x161da2
leaq (%rdx,%rdx,4), %rcx
shlq $0x20, %rdx
movl %eax, %esi
subl %ebp, %esi
orq %rdx, %rsi
movq 0x10(%rbx), %rdx
movq 0x28(%rbx), %rdi
movl 0x4(%rdi,%rcx,8), %ecx
movq %rsi, (%rdx,%rcx,8)
movl %eax, %ebp
incl %eax
movq 0x18(%rbx), %rcx
movq %rax, %rsi
cmpq %rax, %rcx
jae 0x161d60
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/rcut.cpp
// Function: mb_edges_symm(mb_match_t*)
uint32_t mb_edges_symm(mb_match_t *ma)
{
	uint8_t *del = NULL;
	uint32_t i, k, n = 0;
	mb_edge_t *t = NULL, *m = NULL;
	CALLOC(del, ma->ma.n);

	for (i = 0; i < ma->ma.n; ++i) {
		m = &ma->ma.a[i];
		if (ma_x(*m) == ma_y(*m))
		{
			del[i] = 1, ++n;///self overlap
			continue;
		}
		t = get_mb_edge(ma, ma_y(*m), ma_x(*m));
		if(!t)
		{
			del[i] = 1, ++n;///self overlap
			continue;
		} 
		normalize_mb_edge(m, t);
	}

	if (n > 0) {
		for (i = k = 0; i < ma->ma.n; ++i)
			if (!del[i]) ma->ma.a[k++] = ma->ma.a[i];
		ma->ma.n = k;
		mb_edges_idx(ma);
	}

	free(del);
	return n;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x18(%rdi), %r15
movl $0x1, %esi
movq %r15, %rdi
callq 0x2120
movq %rax, %r14
testq %r15, %r15
je 0x161ed8
movq 0x28(%rbx), %rax
xorl %ecx, %ecx
xorl %ebp, %ebp
leaq (%rcx,%rcx,4), %rdi
movq (%rax,%rdi,8), %rdx
movq %rdx, %r8
shrq $0x20, %r8
movl %edx, %esi
cmpq %rsi, %r8
je 0x161e82
movq 0x10(%rbx), %rsi
movl %edx, %r9d
movq (%rsi,%r9,8), %r9
testl %r9d, %r9d
je 0x161e30
movq %r9, %rsi
shrq $0x20, %rsi
leaq (%rsi,%rsi,4), %rsi
leaq (%rax,%rsi,8), %rsi
movl %r9d, %r9d
cmpl %r8d, (%rsi)
je 0x161e32
addq $0x28, %rsi
decq %r9
jne 0x161e22
xorl %esi, %esi
testq %rsi, %rsi
je 0x161e82
leaq (%rax,%rdi,8), %rdi
cmpq %rsi, %rdi
jae 0x161e99
movq (%rsi), %rdx
movq %rdx, %r8
shlq $0x20, %r8
movq %r8, (%rdi)
movq (%rsi), %r8
shrdq $0x20, %rdx, %r8
movq %r8, (%rdi)
movsd 0x8(%rsi), %xmm0
movsd %xmm0, 0x8(%rdi)
movsd 0x20(%rsi), %xmm0
movsd %xmm0, 0x20(%rdi)
movsd 0x18(%rsi), %xmm0
movsd %xmm0, 0x10(%rdi)
movsd 0x10(%rsi), %xmm0
movsd %xmm0, 0x18(%rdi)
jmp 0x161e89
movb $0x1, (%r14,%rcx)
incl %ebp
incq %rcx
movl %ecx, %edx
cmpq %rdx, %r15
ja 0x161de6
jmp 0x161eda
movq %rdx, %r8
shlq $0x20, %r8
movq %r8, (%rsi)
movq (%rdi), %r8
shrdq $0x20, %rdx, %r8
movq %r8, (%rsi)
movsd 0x8(%rdi), %xmm0
movsd %xmm0, 0x8(%rsi)
movsd 0x20(%rdi), %xmm0
movsd %xmm0, 0x20(%rsi)
movsd 0x18(%rdi), %xmm0
movsd %xmm0, 0x10(%rsi)
movsd 0x10(%rdi), %xmm0
movsd %xmm0, 0x18(%rsi)
jmp 0x161e89
xorl %ebp, %ebp
testl %ebp, %ebp
je 0x161f39
xorl %eax, %eax
cmpq $0x0, 0x18(%rbx)
je 0x161f2d
movl $0x1, %ecx
xorl %edx, %edx
cmpb $0x0, (%r14,%rdx)
jne 0x161f21
movq 0x28(%rbx), %rsi
leaq (%rdx,%rdx,4), %rdx
movl %eax, %edi
incl %eax
leaq (%rdi,%rdi,4), %rdi
movq 0x20(%rsi,%rdx,8), %r8
movq %r8, 0x20(%rsi,%rdi,8)
movups (%rsi,%rdx,8), %xmm0
movups 0x10(%rsi,%rdx,8), %xmm1
movups %xmm1, 0x10(%rsi,%rdi,8)
movups %xmm0, (%rsi,%rdi,8)
movl %ecx, %edx
incl %ecx
cmpq %rdx, 0x18(%rbx)
ja 0x161eee
movl %eax, %eax
movq %rax, 0x18(%rbx)
movq %rbx, %rdi
callq 0x161cd6
movq %r14, %rdi
callq 0x2220
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/rcut.cpp
// Function: destory_mc_g_t(mc_g_t**)
void destory_mc_g_t(mc_g_t **p)
{
	if(!p || !(*p)) return;
	if((*p)->s.m == 0) (*p)->s.a = NULL;
	kv_destroy((*p)->s);
	if((*p)->e)
	{
		kv_destroy((*p)->e->idx);
		kv_destroy((*p)->e->ma);
		free((*p)->e->cc);
		free((*p)->e);
	}
	free((*p));
}

// Assembly:
pushq %rbx
testq %rdi, %rdi
je 0x161fc4
movq %rdi, %rbx
movq (%rdi), %rax
testq %rax, %rax
je 0x161fc4
cmpq $0x0, 0x8(%rax)
jne 0x161f6e
movq $0x0, 0x10(%rax)
movq (%rbx), %rax
movq 0x10(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x28(%rax), %rax
testq %rax, %rax
je 0x161fbb
movq 0x10(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x28(%rax), %rax
movq 0x28(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x28(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x28(%rax), %rdi
callq 0x2220
movq (%rbx), %rdi
popq %rbx
jmp 0x2220
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/rcut.cpp
// Function: destory_mb_g_t(mb_g_t**)
void destory_mb_g_t(mb_g_t **p)
{
	if(!p || !(*p)) return;
	kv_destroy((*p)->e->idx);
	kv_destroy((*p)->e->ma);
	free((*p)->e->cc);
	free((*p)->e);

	kv_destroy((*p)->u->bid);
	kv_destroy((*p)->u->idx);
	kv_destroy((*p)->u->u);
	free((*p)->u);

	free((*p));
}

// Assembly:
pushq %rbx
testq %rdi, %rdi
je 0x162055
movq %rdi, %rbx
movq (%rdi), %rax
testq %rax, %rax
je 0x162055
movq 0x8(%rax), %rax
movq 0x10(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x8(%rax), %rax
movq 0x28(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x8(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x8(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq (%rax), %rax
movq 0x10(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq (%rax), %rax
movq 0x28(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq (%rax), %rax
movq 0x40(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq (%rax), %rdi
callq 0x2220
movq (%rbx), %rdi
popq %rbx
jmp 0x2220
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/rcut.cpp
// Function: mc_edges_symm(mc_match_t*)
uint32_t mc_edges_symm(mc_match_t *ma)
{
	uint8_t *del = NULL;
	uint32_t i, k, n = 0;
	mc_edge_t *t = NULL, *m = NULL;
	CALLOC(del, ma->ma.n);

	for (i = 0; i < ma->ma.n; ++i) {
		m = &ma->ma.a[i];
		if (ma_x(*m) == ma_y(*m))
		{
			del[i] = 1, ++n;///self overlap
			continue;
		}
		t = get_mc_edge(ma, ma_y(*m), ma_x(*m));
		if(!t)
		{
			del[i] = 1, ++n;///self overlap
			continue;
		} 
		normalize_mc_edge(m, t);
	}

	if (n > 0) {
		for (i = k = 0; i < ma->ma.n; ++i)
			if (!del[i]) ma->ma.a[k++] = ma->ma.a[i];
		ma->ma.n = k;
		mc_edges_idx(ma);
	}

	free(del);
	return n;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x18(%rdi), %r15
movl $0x1, %esi
movq %r15, %rdi
callq 0x2120
movq %rax, %r14
testq %r15, %r15
je 0x16213a
movq 0x28(%rbx), %rax
xorl %ecx, %ecx
xorl %ebp, %ebp
movq %rcx, %rdx
shlq $0x4, %rdx
movq (%rax,%rdx), %rsi
movq %rsi, %r8
shrq $0x20, %r8
movl %esi, %edi
cmpq %rdi, %r8
je 0x162107
movq 0x10(%rbx), %rdi
movl %esi, %r9d
movq (%rdi,%r9,8), %r9
testl %r9d, %r9d
je 0x1620ce
movq %r9, %rdi
shrq $0x1c, %rdi
andq $-0x10, %rdi
addq %rax, %rdi
movl %r9d, %r9d
cmpl %r8d, (%rdi)
je 0x1620d0
addq $0x10, %rdi
decq %r9
jne 0x1620c0
xorl %edi, %edi
testq %rdi, %rdi
je 0x162107
addq %rax, %rdx
movsd 0x8(%rdx), %xmm0
movsd 0x8(%rdi), %xmm1
ucomisd %xmm1, %xmm0
jae 0x16211e
movq (%rdi), %rsi
movq %rsi, %r8
shlq $0x20, %r8
movq %r8, (%rdx)
movq (%rdi), %rdi
shrdq $0x20, %rsi, %rdi
movq %rdi, (%rdx)
movsd %xmm1, 0x8(%rdx)
jmp 0x16210e
movb $0x1, (%r14,%rcx)
incl %ebp
incq %rcx
movl %ecx, %edx
cmpq %rdx, %r15
ja 0x162086
jmp 0x16213c
movq %rsi, %r8
shlq $0x20, %r8
movq %r8, (%rdi)
movq (%rdx), %rdx
shrdq $0x20, %rsi, %rdx
movq %rdx, (%rdi)
movsd %xmm0, 0x8(%rdi)
jmp 0x16210e
xorl %ebp, %ebp
testl %ebp, %ebp
je 0x162189
xorl %eax, %eax
cmpq $0x0, 0x18(%rbx)
je 0x16217d
movl $0x1, %ecx
xorl %edx, %edx
cmpb $0x0, (%r14,%rdx)
jne 0x162171
movq 0x28(%rbx), %rsi
shlq $0x4, %rdx
movl %eax, %edi
incl %eax
shlq $0x4, %rdi
movupd (%rsi,%rdx), %xmm0
movupd %xmm0, (%rsi,%rdi)
movl %ecx, %edx
incl %ecx
cmpq %rdx, 0x18(%rbx)
ja 0x162150
movl %eax, %eax
movq %rax, 0x18(%rbx)
movq %rbx, %rdi
callq 0x16219e
movq %r14, %rdi
callq 0x2220
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/rcut.cpp
// Function: get_w_scale(kv_u_trans_t*)
double get_w_scale(kv_u_trans_t *ta)
{
	uint32_t i, max_w_i, min_w_i;
	double max_w = 0, min_w = 0, w;
	max_w_i = min_w_i = (uint32_t)-1;
	for (i = 0; i < ta->n; ++i)
	{
		if(ta->a[i].del) continue;
		if(ta->a[i].nw == 0) continue;
		w = (ta->a[i].nw >= 0? ta->a[i].nw:-ta->a[i].nw);
		if(max_w_i == (uint32_t)-1 || max_w < w) max_w = w, max_w_i = i;
		if(min_w_i == (uint32_t)-1 || min_w > w) min_w = w, min_w_i = i;
	}

	if(max_w_i == (uint32_t)-1 || min_w_i == (uint32_t)-1) return 1;
	if(min_w > 1.1) return 1;
	double sc_max = (double)(1<<30), sc_min = 1.1;

	return MIN(sc_max/max_w, sc_min/min_w) + sc_min;
}

// Assembly:
movq (%rdi), %rax
testq %rax, %rax
je 0x16234c
movq 0x10(%rdi), %rcx
addq $0x28, %rcx
xorpd %xmm0, %xmm0
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
movl $0x1, %esi
movapd 0xccd11(%rip), %xmm3    # 0x22efc0
xorpd %xmm1, %xmm1
xorpd %xmm2, %xmm2
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
cmpb $0x0, (%rcx)
js 0x16232e
movsd -0x8(%rcx), %xmm5
ucomisd %xmm0, %xmm5
jne 0x1622ce
jnp 0x16232e
movapd %xmm5, %xmm6
xorpd %xmm3, %xmm6
movapd %xmm6, %xmm4
cmpnlesd %xmm5, %xmm4
andpd %xmm4, %xmm6
andnpd %xmm5, %xmm4
orpd %xmm6, %xmm4
cmpl $-0x1, %edx
sete %r9b
ucomisd %xmm2, %xmm4
seta %r10b
leal -0x1(%rsi), %r8d
orb %r9b, %r10b
movapd %xmm4, %xmm5
testb %r10b, %r10b
jne 0x16230e
movapd %xmm2, %xmm5
cmovnel %r8d, %edx
cmpl $-0x1, %edi
je 0x162323
ucomisd %xmm4, %xmm1
ja 0x162323
movapd %xmm5, %xmm2
jmp 0x16232e
movl %r8d, %edi
movapd %xmm5, %xmm2
movapd %xmm4, %xmm1
movl %esi, %r8d
addq $0x30, %rcx
incl %esi
cmpq %r8, %rax
ja 0x1622bc
cmpl $-0x1, %edx
sete %cl
cmpl $-0x1, %edi
sete %al
orb %cl, %al
jmp 0x162356
movb $0x1, %al
xorpd %xmm2, %xmm2
xorpd %xmm1, %xmm1
movsd 0xc2f12(%rip), %xmm0    # 0x225270
testb %al, %al
jne 0x1623a1
ucomisd 0xc7806(%rip), %xmm1    # 0x229b70
ja 0x1623a1
movsd 0xce6d4(%rip), %xmm3    # 0x230a48
divsd %xmm2, %xmm3
movsd 0xc77f0(%rip), %xmm2    # 0x229b70
movapd %xmm2, %xmm4
divsd %xmm1, %xmm4
movapd %xmm3, %xmm0
cmplesd %xmm4, %xmm0
andpd %xmm0, %xmm3
andnpd %xmm4, %xmm0
orpd %xmm3, %xmm0
addsd %xmm2, %xmm0
retq
// File: /workspace/github_cpp_makefile_star2_O1/chhylp123[P]hifiasm/rcut.cpp
// Function: destroy_mc_bp_t(mc_bp_t**)
void destroy_mc_bp_t(mc_bp_t **bp)
{
	uint32_t i;
	for (i = 0; i < (*bp)->n_thread; i++)
	{
		free((*bp)->vis[i].a);
	}
	free((*bp)->idx);
	free((*bp)->res);
	free((*bp)->lock);
	free((*bp));
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %rax
cmpq $0x0, 0x20(%rax)
je 0x162f6c
movl $0x1, %ebp
xorl %ecx, %ecx
movq 0x48(%rax), %rax
leaq (%rcx,%rcx,2), %rcx
movq 0x10(%rax,%rcx,8), %rdi
callq 0x2220
movl %ebp, %ecx
movq (%rbx), %rax
incl %ebp
cmpq %rcx, 0x20(%rax)
ja 0x162f4d
movq 0x8(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x28(%rax), %rdi
callq 0x2220
movq (%rbx), %rax
movq 0x30(%rax), %rdi
callq 0x2220
movq (%rbx), %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x2220