LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: chhylp123[P]hifiasm/hic.cpp
// Function: destory_G_partition(G_partition*)
void destory_G_partition(G_partition* x)
{
    uint64_t i;
    for (i = 0; i < x->n; i++)
    {
        kv_destroy(x->a[i].a);
    }
    kv_destroy(*x);
    free(x->index);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq $0x0, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq -0x8(%rbp), %rcx
cmpq (%rcx), %rax
jae 0x1d9b88
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x48, -0x10(%rbp), %rcx
addq %rcx, %rax
movq 0x10(%rax), %rdi
callq 0x2210
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x1d9b54
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x2210
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x2210
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: get_hc_weight(unsigned int, unsigned int, unsigned int, bub_p_t_warp*, min_cut_t*)
double get_hc_weight(uint32_t query, uint32_t v0, uint32_t root, bub_p_t_warp *b, min_cut_t* x)
{
    if(v0 == root) return 0;
    uint32_t v, u;
    hc_edge *p = NULL;
    double weight = 0;
    v = v0;
    do {
		u = b->a[v].p; // u->v
        p = get_rGraph_edge(x, query>>1, v>>1);
        if(p) weight += p->weight;
		v = u;
	} while (v != root);

    return weight;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movl %edi, -0xc(%rbp)
movl %esi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movl -0x10(%rbp), %eax
cmpl -0x14(%rbp), %eax
jne 0x1d9bdb
xorps %xmm0, %xmm0
movsd %xmm0, -0x8(%rbp)
jmp 0x1d9c57
movq $0x0, -0x38(%rbp)
xorps %xmm0, %xmm0
movsd %xmm0, -0x40(%rbp)
movl -0x10(%rbp), %eax
movl %eax, -0x2c(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x38, %rcx, %rcx
addq %rcx, %rax
movl (%rax), %eax
movl %eax, -0x30(%rbp)
movq -0x28(%rbp), %rdi
movl -0xc(%rbp), %eax
shrl %eax
movl %eax, %eax
movl %eax, %esi
movl -0x2c(%rbp), %eax
shrl %eax
movl %eax, %eax
movl %eax, %edx
callq 0x1d61d0
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
je 0x1d9c3f
movq -0x38(%rbp), %rax
movsd (%rax), %xmm0
addsd -0x40(%rbp), %xmm0
movsd %xmm0, -0x40(%rbp)
movl -0x30(%rbp), %eax
movl %eax, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
cmpl -0x14(%rbp), %eax
jne 0x1d9bf1
movsd -0x40(%rbp), %xmm0
movsd %xmm0, -0x8(%rbp)
movsd -0x8(%rbp), %xmm0
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: set_path(bub_p_t_warp*, unsigned int, unsigned char*, unsigned char)
void set_path(bub_p_t_warp *b, uint32_t root, uint8_t* flag, uint8_t label)
{
    uint32_t v, u;
    ///v is the sink of this bubble
	v = b->S.a[0];
    do {
		u = b->a[v].p; // u->v
        flag[v>>1] |= label;
		v = u;
	} while (v != root);
    flag[b->S.a[0]>>1] = 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movb %cl, %al
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movb %al, -0x19(%rbp)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movl (%rax), %eax
movl %eax, -0x20(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movl -0x20(%rbp), %ecx
imulq $0x38, %rcx, %rcx
addq %rcx, %rax
movl (%rax), %eax
movl %eax, -0x24(%rbp)
movzbl -0x19(%rbp), %esi
movq -0x18(%rbp), %rax
movl -0x20(%rbp), %ecx
shrl %ecx
movl %ecx, %ecx
movzbl (%rax,%rcx), %edx
orl %esi, %edx
movb %dl, (%rax,%rcx)
movl -0x24(%rbp), %eax
movl %eax, -0x20(%rbp)
movl -0x20(%rbp), %eax
cmpl -0xc(%rbp), %eax
jne 0x1d9c91
movq -0x18(%rbp), %rax
movq -0x8(%rbp), %rcx
movq 0x18(%rcx), %rcx
movl (%rcx), %ecx
shrl %ecx
movl %ecx, %ecx
movb $0x0, (%rax,%rcx)
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: get_co_weight(unsigned int*, unsigned int, unsigned int*, unsigned int, min_cut_t*)
double get_co_weight(uint32_t *query, uint32_t query_n, uint32_t *target, uint32_t target_n, min_cut_t* m)
{
    double weight = 0;
    hc_edge *p = NULL;
    uint32_t i, k;
    for (i = 0; i < query_n; i++)
    {
        for (k = 0; k < target_n; k++)
        {
            p = get_rGraph_edge(m, query[i], target[k]);
            if(p) weight += p->weight;
        }
    }

    return weight;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movq %r8, -0x28(%rbp)
xorps %xmm0, %xmm0
movsd %xmm0, -0x30(%rbp)
movq $0x0, -0x38(%rbp)
movl $0x0, -0x3c(%rbp)
movl -0x3c(%rbp), %eax
cmpl -0xc(%rbp), %eax
jae 0x1da9d0
movl $0x0, -0x40(%rbp)
movl -0x40(%rbp), %eax
cmpl -0x1c(%rbp), %eax
jae 0x1da9c3
movq -0x28(%rbp), %rdi
movq -0x8(%rbp), %rax
movl -0x3c(%rbp), %ecx
movl (%rax,%rcx,4), %eax
movl %eax, %esi
movq -0x18(%rbp), %rax
movl -0x40(%rbp), %ecx
movl (%rax,%rcx,4), %eax
movl %eax, %edx
callq 0x1d61d0
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
je 0x1da9b6
movq -0x38(%rbp), %rax
movsd (%rax), %xmm0
addsd -0x30(%rbp), %xmm0
movsd %xmm0, -0x30(%rbp)
jmp 0x1da9b8
movl -0x40(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x40(%rbp)
jmp 0x1da970
jmp 0x1da9c5
movl -0x3c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x3c(%rbp)
jmp 0x1da961
movsd -0x30(%rbp), %xmm0
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: clean_bubbles(hc_links*, bubble_type*, min_cut_t*, ma_ug_t const*)
G_partition* clean_bubbles(hc_links* link, bubble_type* bub, min_cut_t* m, const ma_ug_t *ug)
{
    double index_time = yak_realtime();
    uint64_t i;
    bub_p_t_warp b; 
    memset(&b, 0, sizeof(bub_p_t_warp));
    CALLOC(b.a, ug->g->n_seq*2); 
    uint8_t* flag = NULL;
    CALLOC(flag, ug->g->n_seq);
    G_partition* x; CALLOC(x, 1);
    init_G_partition(x, ug->g->n_seq);

    for (i = 0; i < bub->f_bub; i++)
    {
        phase_bubble(i, &b, bub, flag, ug, m, link, x);
    }

    free(b.a); free(b.S.a); free(b.T.a); free(b.b.a); free(b.e.a);
    free(flag);
    fprintf(stderr, "[M::%s::%.3f]\n", __func__, yak_realtime()-index_time);
    ///print_phased_bubble(x, bub, ug->g->n_seq);

    return x;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xd0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
callq 0x1b7ca0
movsd %xmm0, -0x28(%rbp)
leaq -0xa0(%rbp), %rdi
xorl %esi, %esi
movl $0x70, %edx
callq 0x2100
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rax
movl 0x14(%rax), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
shll %eax
movslq %eax, %rdi
movl $0x38, %esi
callq 0x2140
movq %rax, -0xa0(%rbp)
movq $0x0, -0xa8(%rbp)
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rax
movl 0x14(%rax), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movl %eax, %eax
movl %eax, %edi
movl $0x1, %esi
callq 0x2140
movq %rax, -0xa8(%rbp)
movl $0x1, %edi
movl $0x20, %esi
callq 0x2140
movq %rax, -0xb0(%rbp)
movq -0xb0(%rbp), %rdi
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rax
movl 0x14(%rax), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movl %eax, %eax
movl %eax, %esi
callq 0x1d9a60
movq $0x0, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq -0x10(%rbp), %rcx
cmpq 0x80(%rcx), %rax
jae 0x1db6a2
movq -0x30(%rbp), %rdi
movq -0x10(%rbp), %rdx
movq -0xa8(%rbp), %rcx
movq -0x20(%rbp), %r8
movq -0x18(%rbp), %r9
movq -0x8(%rbp), %r10
movq -0xb0(%rbp), %rax
leaq -0xa0(%rbp), %rsi
movq %r10, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x1da9e0
movq -0x30(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
jmp 0x1db64c
movq -0xa0(%rbp), %rdi
callq 0x2210
movq -0x88(%rbp), %rdi
callq 0x2210
movq -0x70(%rbp), %rdi
callq 0x2210
movq -0x58(%rbp), %rdi
callq 0x2210
movq -0x40(%rbp), %rdi
callq 0x2210
movq -0xa8(%rbp), %rdi
callq 0x2210
movq 0x1e88f8(%rip), %rax    # 0x3c3fe0
movq (%rax), %rax
movq %rax, -0xb8(%rbp)
callq 0x1b7ca0
movq -0xb8(%rbp), %rdi
subsd -0x28(%rbp), %xmm0
leaq 0x1b10fe(%rip), %rsi    # 0x38c808
leaq 0x1b1106(%rip), %rdx    # 0x38c817
movb $0x1, %al
callq 0x22a0
movq -0xb0(%rbp), %rax
addq $0xd0, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: connect_bub_occ(bubble_type*, unsigned int, unsigned int)
uint32_t connect_bub_occ(bubble_type* bub, uint32_t root_id, uint32_t check_het)
{
    uint64_t id0, id1, occ = 2;  
    get_bub_id(bub, root_id, &id0, &id1, check_het);
    if(id0 == (uint64_t)-1) occ--;
    if(id1 == (uint64_t)-1) occ--;
    return occ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movq $0x2, -0x28(%rbp)
movq -0x8(%rbp), %rdi
movl -0xc(%rbp), %esi
movl -0x10(%rbp), %r8d
leaq -0x18(%rbp), %rdx
leaq -0x20(%rbp), %rcx
callq 0x1dc360
cmpq $-0x1, -0x18(%rbp)
jne 0x1dc605
movq -0x28(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x28(%rbp)
cmpq $-0x1, -0x20(%rbp)
jne 0x1dc618
movq -0x28(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: cmp_chain_weight(void const*, void const*)
int cmp_chain_weight(const void * a, const void * b)
{
    if((*(chain_w_type*)a).del != (*(chain_w_type*)b).del)
    {
        return (*(chain_w_type*)a).del > (*(chain_w_type*)b).del? 1 : -1;
    }
    else
    {
        long long a_occ = (*(chain_w_type*)a).g_occ - (*(chain_w_type*)a).b_occ;
        long long b_occ = (*(chain_w_type*)b).g_occ - (*(chain_w_type*)b).b_occ;
        if(a_occ != b_occ)
        {
            return a_occ > b_occ? -1 : 1;
        }
        else
        {
            return 0;
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movzbl 0x18(%rax), %eax
movq -0x18(%rbp), %rcx
movzbl 0x18(%rcx), %ecx
cmpl %ecx, %eax
je 0x1dfac4
movq -0x10(%rbp), %rax
movzbl 0x18(%rax), %edx
movq -0x18(%rbp), %rax
movzbl 0x18(%rax), %esi
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movl $0x1, %ecx
cmpl %esi, %edx
cmovgl %ecx, %eax
movl %eax, -0x4(%rbp)
jmp 0x1dfb18
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq -0x10(%rbp), %rcx
subq 0x8(%rcx), %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq -0x18(%rbp), %rcx
subq 0x8(%rcx), %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
cmpq -0x28(%rbp), %rax
je 0x1dfb11
movq -0x20(%rbp), %rdx
movq -0x28(%rbp), %rsi
movl $0x1, %eax
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
cmpq %rsi, %rdx
cmovgl %ecx, %eax
movl %eax, -0x4(%rbp)
jmp 0x1dfb18
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopl (%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: get_btg_occ(bubble_type*, unsigned int)
uint32_t get_btg_occ(bubble_type* bub, uint32_t v)
{
    ma_ug_t *bub_ug = bub->b_ug;
    ma_utg_t *u = NULL;
    uint32_t k_i, k_j, *a = NULL, n, tan_occ = 0;

    u = &(bub_ug->u.a[v]);
    for (k_i = 0; k_i < u->n; k_i++)
    {
        get_bubbles(bub, u->a[k_i]>>33, NULL, NULL, &a, &n, NULL);
        for (k_j = 0; k_j < n; k_j++)
        {
            tan_occ += bub->ug->u.a[a[k_j]>>1].n;
        }
    }
    return tan_occ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rax
movq 0xc0(%rax), %rax
movq %rax, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
movq $0x0, -0x30(%rbp)
movl $0x0, -0x38(%rbp)
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0xc(%rbp), %ecx
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
movq -0x20(%rbp), %rcx
cmpl 0x10(%rcx), %eax
jae 0x1e08e9
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rax
movl -0x24(%rbp), %ecx
movq (%rax,%rcx,8), %rsi
shrq $0x21, %rsi
xorl %eax, %eax
movl %eax, %ecx
leaq -0x30(%rbp), %r8
leaq -0x34(%rbp), %r9
movq %rcx, %rdx
movq $0x0, (%rsp)
callq 0x1c4b20
movl $0x0, -0x28(%rbp)
movl -0x28(%rbp), %eax
cmpl -0x34(%rbp), %eax
jae 0x1e08d9
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movq 0x10(%rax), %rax
movq -0x30(%rbp), %rcx
movl -0x28(%rbp), %edx
movl (%rcx,%rdx,4), %ecx
shrl %ecx
movl %ecx, %ecx
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
movl 0x10(%rax), %eax
addl -0x38(%rbp), %eax
movl %eax, -0x38(%rbp)
movl -0x28(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x28(%rbp)
jmp 0x1e089c
jmp 0x1e08db
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x1e0852
movl -0x38(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: get_utg_end_from_btg(bubble_type*, ma_ug_t*, unsigned int)
uint32_t get_utg_end_from_btg(bubble_type* bub, ma_ug_t *bub_ug, uint32_t v)
{
    ma_utg_t *u = &(bub_ug->u.a[v>>1]);
    
    if((v&1)==1)
    {
        return (u->a[0]>>32)^1;
    }
    else
    {
        return u->a[u->n-1]>>32;
    } 
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x1c(%rbp), %ecx
shrl %ecx
movl %ecx, %ecx
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movl -0x1c(%rbp), %eax
andl $0x1, %eax
cmpl $0x1, %eax
jne 0x1e22ac
movq -0x28(%rbp), %rax
movq 0x18(%rax), %rax
movq (%rax), %rax
shrq $0x20, %rax
xorq $0x1, %rax
movl %eax, -0x4(%rbp)
jmp 0x1e22cb
movq -0x28(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x28(%rbp), %rcx
movl 0x10(%rcx), %ecx
subl $0x1, %ecx
movl %ecx, %ecx
movq (%rax,%rcx,8), %rax
shrq $0x20, %rax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
// File: chhylp123[P]hifiasm/hic.cpp
// Function: print_b_utg_occ(bubble_type*, unsigned int)
uint32_t print_b_utg_occ(bubble_type* bub, uint32_t v)
{
    ma_ug_t *bub_ug = bub->b_ug;
    ma_utg_t *u = NULL;
    uint32_t k_i, k_j, *a = NULL, n, tan_occ = 0, beg, sink;

    
    u = &(bub_ug->u.a[v]);
    fprintf(stderr, "\nstart: %u-th bubble-utg-start (# bubbles: %u)\n", v, (uint32_t)u->n);
    for (k_i = 0; k_i < u->n; k_i++)
    {
        get_bubbles(bub, u->a[k_i]>>33, &beg, &sink, &a, &n, NULL);
        for (k_j = 0; k_j < n; k_j++)
        {
            tan_occ += bub->ug->u.a[a[k_j]>>1].n;
        }

        fprintf(stderr, "bid: %lu, n: %u, beg-utg%.6dl(%u), sink-utg%.6dl(%u)\n", u->a[k_i]>>33, n, (beg>>1)+1, beg&1, (sink>>1)+1, sink&1);
    }

    fprintf(stderr, "end: %u-th bubble-utg-end\n\n", v);
    return tan_occ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rax
movq 0xc0(%rax), %rax
movq %rax, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
movq $0x0, -0x30(%rbp)
movl $0x0, -0x38(%rbp)
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0xc(%rbp), %ecx
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
movq 0x1e149e(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movl -0xc(%rbp), %edx
movq -0x20(%rbp), %rax
movl 0x10(%rax), %ecx
leaq 0x1a9f7c(%rip), %rsi    # 0x38cad2
movb $0x0, %al
callq 0x22a0
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
movq -0x20(%rbp), %rcx
cmpl 0x10(%rcx), %eax
jae 0x1e2c56
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rax
movl -0x24(%rbp), %ecx
movq (%rax,%rcx,8), %rsi
shrq $0x21, %rsi
leaq -0x3c(%rbp), %rdx
leaq -0x40(%rbp), %rcx
leaq -0x30(%rbp), %r8
leaq -0x34(%rbp), %r9
xorl %eax, %eax
movq $0x0, (%rsp)
callq 0x1c4b20
movl $0x0, -0x28(%rbp)
movl -0x28(%rbp), %eax
cmpl -0x34(%rbp), %eax
jae 0x1e2bee
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movq 0x10(%rax), %rax
movq -0x30(%rbp), %rcx
movl -0x28(%rbp), %edx
movl (%rcx,%rdx,4), %ecx
shrl %ecx
movl %ecx, %ecx
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
movl 0x10(%rax), %eax
addl -0x38(%rbp), %eax
movl %eax, -0x38(%rbp)
movl -0x28(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x28(%rbp)
jmp 0x1e2bb1
movq 0x1e13eb(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rax
movl -0x24(%rbp), %ecx
movq (%rax,%rcx,8), %rdx
shrq $0x21, %rdx
movl -0x34(%rbp), %ecx
movl -0x3c(%rbp), %r8d
shrl %r8d
addl $0x1, %r8d
movl -0x3c(%rbp), %r9d
andl $0x1, %r9d
movl -0x40(%rbp), %r10d
shrl %r10d
addl $0x1, %r10d
movl -0x40(%rbp), %eax
andl $0x1, %eax
leaq 0x1a9ec9(%rip), %rsi    # 0x38cb02
movl %r10d, (%rsp)
movl %eax, 0x8(%rsp)
movb $0x0, %al
callq 0x22a0
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x1e2b64
movq 0x1e1383(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movl -0xc(%rbp), %edx
leaq 0x1a9ece(%rip), %rsi    # 0x38cb38
movb $0x0, %al
callq 0x22a0
movl -0x38(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: is_same_phase(unsigned long, unsigned long, H_partition*, signed char*, mc_gg_status*)
uint32_t is_same_phase(uint64_t bid, uint64_t eid, H_partition* hap, int8_t *s, mc_gg_status *sa)
{
    if(bid == eid) return 1;
    if(hap || s)
    {
        int beg_status, end_status;
        beg_status = (hap? get_phase_status(hap, bid):s[bid]);
        if(beg_status != 1 && beg_status != -1) return (uint32_t)-1;
        end_status = (hap? get_phase_status(hap, eid):s[eid]);
        if(end_status != 1 && end_status != -1) return (uint32_t)-1;
        if(beg_status == end_status) return 1;
        return 0;
    }

    if(sa)
    {
        if(sa[bid].s == 0 || sa[eid].s == 0) return (uint32_t)-1;
        return !!(sa[bid].s&sa[eid].s);
    }
    return (uint32_t)-1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x30(%rbp)
movq -0x10(%rbp), %rax
cmpq -0x18(%rbp), %rax
jne 0x1ea372
movl $0x1, -0x4(%rbp)
jmp 0x1ea4a3
cmpq $0x0, -0x20(%rbp)
jne 0x1ea384
cmpq $0x0, -0x28(%rbp)
je 0x1ea42e
cmpq $0x0, -0x20(%rbp)
je 0x1ea39f
movq -0x20(%rbp), %rdi
movq -0x10(%rbp), %rax
movl %eax, %esi
callq 0x2145e0
movl %eax, -0x3c(%rbp)
jmp 0x1ea3ae
movq -0x28(%rbp), %rax
movq -0x10(%rbp), %rcx
movsbl (%rax,%rcx), %eax
movl %eax, -0x3c(%rbp)
movl -0x3c(%rbp), %eax
movl %eax, -0x34(%rbp)
cmpl $0x1, -0x34(%rbp)
je 0x1ea3cc
cmpl $-0x1, -0x34(%rbp)
je 0x1ea3cc
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x1ea4a3
cmpq $0x0, -0x20(%rbp)
je 0x1ea3e7
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rax
movl %eax, %esi
callq 0x2145e0
movl %eax, -0x40(%rbp)
jmp 0x1ea3f6
movq -0x28(%rbp), %rax
movq -0x18(%rbp), %rcx
movsbl (%rax,%rcx), %eax
movl %eax, -0x40(%rbp)
movl -0x40(%rbp), %eax
movl %eax, -0x38(%rbp)
cmpl $0x1, -0x38(%rbp)
je 0x1ea414
cmpl $-0x1, -0x38(%rbp)
je 0x1ea414
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x1ea4a3
movl -0x34(%rbp), %eax
cmpl -0x38(%rbp), %eax
jne 0x1ea425
movl $0x1, -0x4(%rbp)
jmp 0x1ea4a3
movl $0x0, -0x4(%rbp)
jmp 0x1ea4a3
cmpq $0x0, -0x30(%rbp)
je 0x1ea49c
movq -0x30(%rbp), %rax
movq -0x10(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
cmpl $0x0, (%rax)
je 0x1ea45d
movq -0x30(%rbp), %rax
movq -0x18(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
cmpl $0x0, (%rax)
jne 0x1ea466
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x1ea4a3
movq -0x30(%rbp), %rax
movq -0x10(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movl (%rax), %eax
movq -0x30(%rbp), %rcx
movq -0x18(%rbp), %rdx
shlq $0x5, %rdx
addq %rdx, %rcx
andl (%rcx), %eax
cmpl $0x0, %eax
setne %al
xorb $-0x1, %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x4(%rbp)
jmp 0x1ea4a3
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: get_path_weight(unsigned int, unsigned int, unsigned int, bub_p_t_warp*, hc_links*)
double get_path_weight(uint32_t query, uint32_t v0, uint32_t root, bub_p_t_warp *b, hc_links* x)
{
    if(v0 == root) return 0;
    uint32_t v, u;
    hc_edge *p = NULL;
    double weight = 0;
    v = v0;
    do {
		u = b->a[v].p; // u->v
        p = get_hc_edge(x, query>>1, v>>1, 0);
        if(p) weight += p->weight;
		v = u;
	} while (v != root);

    return weight;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movl %edi, -0xc(%rbp)
movl %esi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movl -0x10(%rbp), %eax
cmpl -0x14(%rbp), %eax
jne 0x1eb8ce
xorps %xmm0, %xmm0
movsd %xmm0, -0x8(%rbp)
jmp 0x1eb94e
movq $0x0, -0x38(%rbp)
xorps %xmm0, %xmm0
movsd %xmm0, -0x40(%rbp)
movl -0x10(%rbp), %eax
movl %eax, -0x2c(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x38, %rcx, %rcx
addq %rcx, %rax
movl (%rax), %eax
movl %eax, -0x30(%rbp)
movq -0x28(%rbp), %rdi
movl -0xc(%rbp), %eax
shrl %eax
movl %eax, %eax
movl %eax, %esi
movl -0x2c(%rbp), %eax
shrl %eax
movl %eax, %eax
movl %eax, %edx
xorl %eax, %eax
movl %eax, %ecx
callq 0x1d09c0
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
je 0x1eb936
movq -0x38(%rbp), %rax
movsd (%rax), %xmm0
addsd -0x40(%rbp), %xmm0
movsd %xmm0, -0x40(%rbp)
movl -0x30(%rbp), %eax
movl %eax, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
cmpl -0x14(%rbp), %eax
jne 0x1eb8e4
movsd -0x40(%rbp), %xmm0
movsd %xmm0, -0x8(%rbp)
movsd -0x8(%rbp), %xmm0
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: reset_ambiguous_label(H_partition*, unsigned char*, unsigned int)
void reset_ambiguous_label(H_partition* hap, uint8_t* hap_label_flag, uint32_t uID)
{
    uint32_t hap_label = (uint32_t)-1;
    if(get_weightest_hap_label_from_uid(uID, hap, hap_label_flag, &hap_label, NULL)>0)
    {
        double cur_w0, cur_w1;
        get_related_weight(uID, hap, &cur_w0, &cur_w1, &hap_label);
        if(cur_w0 >= cur_w1)
        {
            hap->hap[uID] |= (hap_label | hap->m[0]);
        }
        else
        {
            hap->hap[uID] |= (hap_label | hap->m[1]);
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movl $0xffffffff, -0x18(%rbp) # imm = 0xFFFFFFFF
movl -0x14(%rbp), %eax
movl %eax, %edi
movq -0x8(%rbp), %rsi
movq -0x10(%rbp), %rdx
leaq -0x18(%rbp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x1ecdc0
cmpl $0x0, %eax
jbe 0x1eddd8
movl -0x14(%rbp), %edi
movq -0x8(%rbp), %rsi
leaq -0x20(%rbp), %rdx
leaq -0x28(%rbp), %rcx
leaq -0x18(%rbp), %r8
callq 0x1eb960
movsd -0x20(%rbp), %xmm0
ucomisd -0x28(%rbp), %xmm0
jb 0x1eddbb
movl -0x18(%rbp), %edx
movq -0x8(%rbp), %rax
orl 0x18(%rax), %edx
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x14(%rbp), %ecx
orl (%rax,%rcx,4), %edx
movl %edx, (%rax,%rcx,4)
jmp 0x1eddd6
movl -0x18(%rbp), %edx
movq -0x8(%rbp), %rax
orl 0x1c(%rax), %edx
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x14(%rbp), %ecx
orl (%rax,%rcx,4), %edx
movl %edx, (%rax,%rcx,4)
jmp 0x1eddd8
addq $0x30, %rsp
popq %rbp
retq
nop
// File: chhylp123[P]hifiasm/hic.cpp
// Function: get_unset_com(H_partition*, bubble_type*, ma_ug_t*, unsigned char*, unsigned int*)
uint32_t get_unset_com(H_partition* hap, bubble_type* bub, ma_ug_t *ug, uint8_t* hap_label_flag, uint32_t* max_hap_label)
{
    uint32_t max_i = get_available_com(hap, bub, ug, 1, 1, hap_label_flag, max_hap_label);

    if(max_i == (uint32_t)-1)
    {
        max_i = get_available_com(hap, bub, ug, 1, 0, hap_label_flag, max_hap_label);
        if(max_i != (uint32_t)-1)
        {
            hap->label += hap->label_add;
            (*max_hap_label) = hap->label;
        }
    }

    return max_i;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %r9
movq -0x28(%rbp), %rax
movl $0x1, %r8d
movl %r8d, %ecx
movq %rax, (%rsp)
callq 0x1ed680
movl %eax, -0x2c(%rbp)
cmpl $-0x1, -0x2c(%rbp)
jne 0x1ede79
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %r9
movq -0x28(%rbp), %rax
movl $0x1, %ecx
xorl %r8d, %r8d
movq %rax, (%rsp)
callq 0x1ed680
movl %eax, -0x2c(%rbp)
cmpl $-0x1, -0x2c(%rbp)
je 0x1ede77
movq -0x8(%rbp), %rax
movl 0x28(%rax), %ecx
movq -0x8(%rbp), %rax
addl 0x24(%rax), %ecx
movl %ecx, 0x24(%rax)
movq -0x8(%rbp), %rax
movl 0x24(%rax), %ecx
movq -0x28(%rbp), %rax
movl %ecx, (%rax)
jmp 0x1ede79
movl -0x2c(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: phase_com(H_partition*, ma_ug_t*, bub_p_t_warp*, bubble_type*, unsigned int, unsigned int)
void phase_com(H_partition* hap, ma_ug_t *ug, bub_p_t_warp* b, bubble_type* bub, uint32_t bid, uint32_t max_hap_label)
{
    
    if((bid & 1) == 0) ///bubble
    {
        uint32_t beg = (uint32_t)-1, sink = (uint32_t)-1, n, *a;
        get_bubbles(bub, bid>>1, &beg, &sink, &a, &n, NULL);
        ///fprintf(stderr, "+bubble-%uth, beg: %u, sink: %u, phasing ID: %u\n", bid>>1, beg>>1, sink>>1, hap->label>>3);
        b->exist_hap_label = (uint32_t)-1;
        get_phase_path(ug, beg, sink, b, hap, max_hap_label);
        get_phase_path(ug, beg, sink, b, hap, max_hap_label);
        ///fprintf(stderr, "-bubble-%uth, beg: %u, sink: %u, phasing ID: %u\n", bid>>1, beg>>1, sink>>1, hap->label>>3);
    }
    else
    {
        double cur_w0, cur_w1;
        get_related_weight(bid>>1, hap, &cur_w0, &cur_w1, &max_hap_label);
        ///fprintf(stderr, "utg-%uth, phasing ID: %u\n", bid>>1, hap->label>>3);
        if(cur_w0 >= cur_w1)
        {
            hap->hap[bid>>1] |= (max_hap_label | hap->m[0]);
        }
        else
        {
            hap->hap[bid>>1] |= (max_hap_label | hap->m[1]);
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movl %r8d, -0x24(%rbp)
movl %r9d, -0x28(%rbp)
movl -0x24(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
jne 0x1edf38
movl $0xffffffff, -0x2c(%rbp) # imm = 0xFFFFFFFF
movl $0xffffffff, -0x30(%rbp) # imm = 0xFFFFFFFF
movq -0x20(%rbp), %rdi
movl -0x24(%rbp), %eax
shrl %eax
movl %eax, %eax
movl %eax, %esi
leaq -0x2c(%rbp), %rdx
leaq -0x30(%rbp), %rcx
leaq -0x40(%rbp), %r8
leaq -0x34(%rbp), %r9
xorl %eax, %eax
movq $0x0, (%rsp)
callq 0x1c4b20
movq -0x18(%rbp), %rax
movl $0xffffffff, 0x68(%rax) # imm = 0xFFFFFFFF
movq -0x10(%rbp), %rdi
movl -0x2c(%rbp), %esi
movl -0x30(%rbp), %edx
movq -0x18(%rbp), %rcx
movq -0x8(%rbp), %r8
movl -0x28(%rbp), %r9d
callq 0x1ebd50
movq -0x10(%rbp), %rdi
movl -0x2c(%rbp), %esi
movl -0x30(%rbp), %edx
movq -0x18(%rbp), %rcx
movq -0x8(%rbp), %r8
movl -0x28(%rbp), %r9d
callq 0x1ebd50
jmp 0x1edfa0
movl -0x24(%rbp), %edi
shrl %edi
movq -0x8(%rbp), %rsi
leaq -0x48(%rbp), %rdx
leaq -0x50(%rbp), %rcx
leaq -0x28(%rbp), %r8
callq 0x1eb960
movsd -0x48(%rbp), %xmm0
ucomisd -0x50(%rbp), %xmm0
jb 0x1edf7f
movl -0x28(%rbp), %edx
movq -0x8(%rbp), %rax
orl 0x18(%rax), %edx
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x24(%rbp), %ecx
shrl %ecx
movl %ecx, %ecx
orl (%rax,%rcx,4), %edx
movl %edx, (%rax,%rcx,4)
jmp 0x1edf9e
movl -0x28(%rbp), %edx
movq -0x8(%rbp), %rax
orl 0x1c(%rax), %edx
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x24(%rbp), %ecx
shrl %ecx
movl %ecx, %ecx
orl (%rax,%rcx,4), %edx
movl %edx, (%rax,%rcx,4)
jmp 0x1edfa0
addq $0x60, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: get_cluster_inner_weight(H_partition*, hc_links*, unsigned int*, unsigned int, unsigned int*, unsigned int)
double get_cluster_inner_weight(H_partition* hap, hc_links* link, uint32_t *h0, uint32_t h0_n, 
uint32_t *h1, uint32_t h1_n)
{
    double weight = 0;
    uint32_t j, k, m;
    for (j = 0, weight = 0; j < h0_n; j++)
    {
        for (k = 0; k < link->a.a[h0[j]].e.n; k++)
        {
            if(link->a.a[h0[j]].e.a[k].del) continue;
            for (m = 0; m < h1_n; m++)
            {
                if(h1[m] == link->a.a[h0[j]].e.a[k].uID) break;
            }
            if(m == h1_n) continue;

            weight += link->a.a[h0[j]].e.a[k].weight;
        }
    }

    return weight * 2;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movq %r8, -0x28(%rbp)
movl %r9d, -0x2c(%rbp)
xorps %xmm0, %xmm0
movsd %xmm0, -0x38(%rbp)
movl $0x0, -0x3c(%rbp)
xorps %xmm0, %xmm0
movsd %xmm0, -0x38(%rbp)
movl -0x3c(%rbp), %eax
cmpl -0x1c(%rbp), %eax
jae 0x1ee2b1
movl $0x0, -0x40(%rbp)
movl -0x40(%rbp), %eax
movq -0x10(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq -0x18(%rbp), %rdx
movl -0x3c(%rbp), %esi
movl (%rdx,%rsi,4), %edx
imulq $0x30, %rdx, %rdx
addq %rdx, %rcx
cmpq (%rcx), %rax
jae 0x1ee2a1
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x18(%rbp), %rcx
movl -0x3c(%rbp), %edx
movl (%rcx,%rdx,4), %ecx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rax
movl -0x40(%rbp), %ecx
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
movb 0x18(%rax), %al
shrb $0x7, %al
cmpb $0x0, %al
je 0x1ee200
jmp 0x1ee293
movl $0x0, -0x44(%rbp)
movl -0x44(%rbp), %eax
cmpl -0x2c(%rbp), %eax
jae 0x1ee254
movq -0x28(%rbp), %rax
movl -0x44(%rbp), %ecx
movl (%rax,%rcx,4), %eax
movq -0x10(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq -0x18(%rbp), %rdx
movl -0x3c(%rbp), %esi
movl (%rdx,%rsi,4), %edx
imulq $0x30, %rdx, %rdx
addq %rdx, %rcx
movq 0x10(%rcx), %rcx
movl -0x40(%rbp), %edx
imulq $0x28, %rdx, %rdx
addq %rdx, %rcx
cmpl 0x8(%rcx), %eax
jne 0x1ee247
jmp 0x1ee254
jmp 0x1ee249
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
jmp 0x1ee207
movl -0x44(%rbp), %eax
cmpl -0x2c(%rbp), %eax
jne 0x1ee25e
jmp 0x1ee293
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x18(%rbp), %rcx
movl -0x3c(%rbp), %edx
movl (%rcx,%rdx,4), %ecx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rax
movl -0x40(%rbp), %ecx
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
movsd (%rax), %xmm0
addsd -0x38(%rbp), %xmm0
movsd %xmm0, -0x38(%rbp)
movl -0x40(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x40(%rbp)
jmp 0x1ee1a5
jmp 0x1ee2a3
movl -0x3c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x3c(%rbp)
jmp 0x1ee192
movsd 0x19402f(%rip), %xmm0   # 0x3822e8
mulsd -0x38(%rbp), %xmm0
popq %rbp
retq
// File: chhylp123[P]hifiasm/hic.cpp
// Function: print_contig_partition(H_partition*, char const*)
void print_contig_partition(H_partition* hap, const char* debug)
{
    uint32_t i;
    int status;
    for (i = 0; i < hap->n; i++)
    {
        status = get_phase_status(hap, i);
        fprintf(stderr, "%s\tutg%.6d\tP:%u\tHG:A:%d\n", debug, (int)(i+1), hap->hap[i]>>3, status);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl $0x0, -0x14(%rbp)
movl -0x14(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpq (%rcx), %rax
jae 0x1ee7d6
movq -0x8(%rbp), %rdi
movl -0x14(%rbp), %esi
callq 0x2145e0
movl %eax, -0x18(%rbp)
movq 0x1d5847(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0x10(%rbp), %rdx
movl -0x14(%rbp), %ecx
addl $0x1, %ecx
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x14(%rbp), %esi
movl (%rax,%rsi,4), %r8d
shrl $0x3, %r8d
movl -0x18(%rbp), %r9d
leaq 0x19e422(%rip), %rsi    # 0x38cbe6
movb $0x0, %al
callq 0x22a0
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x1ee777
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: if_flip(H_partition*, G_partition*, hc_links*, bubble_type*, unsigned int)
uint32_t if_flip(H_partition* h, G_partition* g_p, hc_links* link,  
bubble_type* bub, uint32_t gid)
{
    double weight = 0;
    if(h->lock[gid]) return 0;
    if(g_p->a[gid].h[0] > 0 && (g_p->a[gid].status[0] == 1 || g_p->a[gid].status[0] == -1))
    {
        weight += (g_p->a[gid].weight[0] * g_p->a[gid].status[0]);
    }

    if(g_p->a[gid].h[1] > 0 && (g_p->a[gid].status[1] == 1 || g_p->a[gid].status[1] == -1))
    {
        weight += (g_p->a[gid].weight[1] * g_p->a[gid].status[1]);
    }
    weight += g_p->a[gid].weight_convex*2;
    if(weight >= 0) return 0;
    return 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movl %r8d, -0x2c(%rbp)
xorps %xmm0, %xmm0
movsd %xmm0, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movl -0x2c(%rbp), %ecx
cmpb $0x0, (%rax,%rcx)
je 0x1efc7d
movl $0x0, -0x4(%rbp)
jmp 0x1efdd4
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
cmpl $0x0, 0x18(%rax)
jbe 0x1efd05
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
cmpl $0x1, 0x24(%rax)
je 0x1efcc5
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
cmpl $-0x1, 0x24(%rax)
jne 0x1efd05
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
movsd 0x30(%rax), %xmm0
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
cvtsi2sdl 0x24(%rax), %xmm2
movsd -0x38(%rbp), %xmm1
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, -0x38(%rbp)
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
cmpl $0x0, 0x1c(%rax)
jbe 0x1efd8d
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
cmpl $0x1, 0x28(%rax)
je 0x1efd4d
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
cmpl $-0x1, 0x28(%rax)
jne 0x1efd8d
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
movsd 0x38(%rax), %xmm0
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
cvtsi2sdl 0x28(%rax), %xmm2
movsd -0x38(%rbp), %xmm1
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, -0x38(%rbp)
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
movsd 0x40(%rax), %xmm0
movsd -0x38(%rbp), %xmm1
addsd %xmm0, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, -0x38(%rbp)
movsd -0x38(%rbp), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jb 0x1efdcd
movl $0x0, -0x4(%rbp)
jmp 0x1efdd4
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopl (%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: print_phase_group(G_partition*, bubble_type*, char const*)
void print_phase_group(G_partition* g_p, bubble_type* bub, const char* command)
{
    uint32_t i, k;
    partition_warp *res = NULL;
    for (i = 0; i < g_p->n; i++)
    {
        res = &(g_p->a[i]);
        fprintf(stderr, "\n%s: %u-th group: # %d = %u (weight: %f), # %d = %u (weight: %f), inner_weight: %f\n", command, i,
        res->status[0], res->h[0], res->weight[0], res->status[1], res->h[1], res->weight[1], res->weight_convex);
        for (k = 0; k < res->h[0]; k++)
        {
            fprintf(stderr, "%d: utg%.6ul\n", res->status[0], int(res->a.a[k]+1));
        }

        for (; k < res->a.n; k++)
        {
            fprintf(stderr, "%d: utg%.6ul\n", res->status[1], int(res->a.a[k]+1));
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq $0x0, -0x28(%rbp)
movl $0x0, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpq (%rcx), %rax
jae 0x1f09d1
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x1c(%rbp), %ecx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movq 0x1d3710(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0x18(%rbp), %rdx
movl -0x1c(%rbp), %ecx
movq -0x28(%rbp), %rax
movl 0x24(%rax), %r8d
movq -0x28(%rbp), %rax
movl 0x18(%rax), %r9d
movq -0x28(%rbp), %rax
movsd 0x30(%rax), %xmm0
movq -0x28(%rbp), %rax
movl 0x28(%rax), %r10d
movq -0x28(%rbp), %rax
movl 0x1c(%rax), %eax
movq -0x28(%rbp), %rsi
movsd 0x38(%rsi), %xmm1
movq -0x28(%rbp), %rsi
movsd 0x40(%rsi), %xmm2
leaq 0x19c365(%rip), %rsi    # 0x38cc80
movl %r10d, (%rsp)
movl %eax, 0x8(%rsp)
movb $0x3, %al
callq 0x22a0
movl $0x0, -0x20(%rbp)
movl -0x20(%rbp), %eax
movq -0x28(%rbp), %rcx
cmpl 0x18(%rcx), %eax
jae 0x1f0978
movq 0x1d369c(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0x28(%rbp), %rax
movl 0x24(%rax), %edx
movq -0x28(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x20(%rbp), %ecx
movl (%rax,%rcx,4), %ecx
addl $0x1, %ecx
leaq 0x19c36e(%rip), %rsi    # 0x38ccd4
movb $0x0, %al
callq 0x22a0
movl -0x20(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x20(%rbp)
jmp 0x1f0931
jmp 0x1f097a
movl -0x20(%rbp), %eax
movq -0x28(%rbp), %rcx
cmpq (%rcx), %rax
jae 0x1f09c1
movq 0x1d3653(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0x28(%rbp), %rax
movl 0x28(%rax), %edx
movq -0x28(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x20(%rbp), %ecx
movl (%rax,%rcx,4), %ecx
addl $0x1, %ecx
leaq 0x19c325(%rip), %rsi    # 0x38ccd4
movb $0x0, %al
callq 0x22a0
movl -0x20(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x20(%rbp)
jmp 0x1f097a
jmp 0x1f09c3
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x1f08a3
addq $0x40, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: set_bubble(H_partition*, G_partition*, bubble_type*, block_phase_type*, unsigned long)
void set_bubble(H_partition* hap, G_partition* g_p, bubble_type* bub, block_phase_type* block, 
uint64_t bid)
{
    uint32_t beg, sink, k, uid, *a, n, gid;
    block->weight = 0;
    get_bubbles(bub, bid, &beg, &sink, &a, &n, NULL);
    for (k = 0; k < n; k++)
    {
        uid = a[k]>>1;
        if(g_p->index[uid] == (uint32_t)-1) continue;
        gid = g_p->index[uid]>>1;
        block->vis.a[gid] = 1;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x20(%rbp), %rax
xorps %xmm0, %xmm0
movsd %xmm0, 0x18(%rax)
movq -0x18(%rbp), %rdi
movq -0x28(%rbp), %rsi
leaq -0x2c(%rbp), %rdx
leaq -0x30(%rbp), %rcx
leaq -0x40(%rbp), %r8
leaq -0x44(%rbp), %r9
xorl %eax, %eax
movq $0x0, (%rsp)
callq 0x1c4b20
movl $0x0, -0x34(%rbp)
movl -0x34(%rbp), %eax
cmpl -0x44(%rbp), %eax
jae 0x1f0a8d
movq -0x40(%rbp), %rax
movl -0x34(%rbp), %ecx
movl (%rax,%rcx,4), %eax
shrl %eax
movl %eax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movl -0x38(%rbp), %ecx
cmpl $-0x1, (%rax,%rcx,4)
jne 0x1f0a60
jmp 0x1f0a82
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movl -0x38(%rbp), %ecx
movl (%rax,%rcx,4), %eax
shrl %eax
movl %eax, -0x48(%rbp)
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x48(%rbp), %ecx
movb $0x1, (%rax,%rcx)
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x1f0a36
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: shift_block_phase_type(ma_utg_t*, G_partition*, bubble_type*, block_phase_type*, unsigned int)
uint32_t shift_block_phase_type(ma_utg_t *u, G_partition* g_p, bubble_type* bub, 
block_phase_type* b, uint32_t offset)
{
    long long c_bid, c_uid;
    uint32_t gid, occ = 0;
    b->bid = b->uid = 0;
    while (1)
    {
        if(occ == offset) break;
        gid = next_hap_label_id(b, g_p, bub, u, 1, &c_bid, &c_uid);
        if(gid == (uint32_t)-1) break;
        occ++;
    }
    return occ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movl %r8d, -0x24(%rbp)
movl $0x0, -0x40(%rbp)
movq -0x20(%rbp), %rax
movq $0x0, 0x28(%rax)
movq -0x20(%rbp), %rax
movq $0x0, 0x20(%rax)
movl -0x40(%rbp), %eax
cmpl -0x24(%rbp), %eax
jne 0x1f1c25
jmp 0x1f1c62
movq -0x20(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x8(%rbp), %rcx
movl $0x1, %r8d
leaq -0x30(%rbp), %r9
leaq -0x38(%rbp), %rax
movq %rax, (%rsp)
callq 0x1f0aa0
movl %eax, -0x3c(%rbp)
cmpl $-0x1, -0x3c(%rbp)
jne 0x1f1c57
jmp 0x1f1c62
movl -0x40(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x40(%rbp)
jmp 0x1f1c1b
movl -0x40(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: get_block_phase_type(unsigned long*, G_partition*, bubble_type*, unsigned int, block_phase_type*)
void get_block_phase_type(uint64_t* chain_idx, G_partition* g_p, bubble_type* bub, uint32_t id, block_phase_type* i_b)
{
    uint64_t i;
    ma_utg_t *u = NULL;
    for (i = 0; i < bub->chain_weight.n; i++)
    {
        if(id >= chain_idx[i] && id < chain_idx[i+1]) break;
    }

    u = &(bub->b_ug->u.a[bub->chain_weight.a[i].id]);
    shift_block_phase_type(u, g_p, bub, i_b, id - chain_idx[i]);
    i_b->chainID = bub->chain_weight.a[i].id;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movq %r8, -0x28(%rbp)
movq $0x0, -0x38(%rbp)
movq $0x0, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq -0x18(%rbp), %rcx
cmpq 0xc8(%rcx), %rax
jae 0x1f1ce1
movl -0x1c(%rbp), %eax
movq -0x8(%rbp), %rcx
movq -0x30(%rbp), %rdx
cmpq (%rcx,%rdx,8), %rax
jb 0x1f1cd1
movl -0x1c(%rbp), %eax
movq -0x8(%rbp), %rcx
movq -0x30(%rbp), %rdx
cmpq 0x8(%rcx,%rdx,8), %rax
jae 0x1f1cd1
jmp 0x1f1ce1
jmp 0x1f1cd3
movq -0x30(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
jmp 0x1f1c9b
movq -0x18(%rbp), %rax
movq 0xc0(%rax), %rax
movq 0x10(%rax), %rax
movq -0x18(%rbp), %rcx
movq 0xd8(%rcx), %rcx
movq -0x30(%rbp), %rdx
shlq $0x5, %rdx
addq %rdx, %rcx
imulq $0x28, 0x10(%rcx), %rcx
addq %rcx, %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x28(%rbp), %rcx
movl -0x1c(%rbp), %eax
movq -0x8(%rbp), %r8
movq -0x30(%rbp), %r9
subq (%r8,%r9,8), %rax
movl %eax, %r8d
callq 0x1f1be0
movq -0x18(%rbp), %rax
movq 0xd8(%rax), %rax
movq -0x30(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x30(%rax)
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: destory_mul_block_phase_type(mul_block_phase_type*)
void destory_mul_block_phase_type(mul_block_phase_type* x)
{
    uint32_t i;
    free(x->res);
    free(x->chain_idx);
    for (i = 0; i < x->n_thread; i++)
    {
        kv_destroy(x->x[i].vis);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rdi
callq 0x2210
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x2210
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl 0x8(%rcx), %eax
jae 0x1f204e
movq -0x8(%rbp), %rax
movq (%rax), %rax
movl -0xc(%rbp), %ecx
imulq $0x38, %rcx, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rdi
callq 0x2210
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x1f201d
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: select_max_block_by_utg_multi_thread_by_chain(H_partition*, G_partition*, bubble_type*, hc_links*, block_phase_type*, unsigned int, block_res_type*)
void select_max_block_by_utg_multi_thread_by_chain(H_partition* h, G_partition* g_p, bubble_type* bub, 
hc_links* link, block_phase_type* i_b, uint32_t id, block_res_type* res)
{
    long long c_bid, c_uid, l_bid, l_uid;
    uint32_t gid;
    ma_utg_t *u = &(bub->b_ug->u.a[id]);
    i_b->bid = i_b->uid = 0; i_b->chainID = id;
    while (1)
    {
        gid = next_hap_label_id(i_b, g_p, bub, u, 1, &c_bid, &c_uid);
        if(gid == (uint32_t)-1) break;

        if(identify_best_interval(i_b, h->lock, g_p, bub, u, link, c_bid, c_uid, &l_bid, &l_uid))
        {
            break;
        }
        if(l_bid == -1 || l_uid == -1) continue;
        if(res->min_w > i_b->weight)
        {
            res->min_w = i_b->weight;
            res->min_f_bid = c_bid;
            res->min_f_uid = c_uid;
            res->min_l_bid = l_bid;
            res->min_l_uid = l_uid;
            res->min_chain_id = i_b->chainID;
            res->min_idx = id;
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x88, %rsp
movq 0x10(%rbp), %rax
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x30(%rbp)
movl %r9d, -0x34(%rbp)
movq -0x20(%rbp), %rax
movq 0xc0(%rax), %rax
movq 0x10(%rax), %rax
movl -0x34(%rbp), %ecx
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x68(%rbp)
movq -0x30(%rbp), %rax
movq $0x0, 0x28(%rax)
movq -0x30(%rbp), %rax
movq $0x0, 0x20(%rax)
movl -0x34(%rbp), %eax
movl %eax, %ecx
movq -0x30(%rbp), %rax
movq %rcx, 0x30(%rax)
movq -0x30(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
movq -0x68(%rbp), %rcx
movl $0x1, %r8d
leaq -0x40(%rbp), %r9
leaq -0x48(%rbp), %rax
movq %rax, (%rsp)
callq 0x1f0aa0
movl %eax, -0x5c(%rbp)
cmpl $-0x1, -0x5c(%rbp)
jne 0x1f229f
jmp 0x1f2377
movq -0x30(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rsi
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %rcx
movq -0x68(%rbp), %r8
movq -0x28(%rbp), %r9
movq -0x40(%rbp), %rbx
movq -0x48(%rbp), %r11
leaq -0x50(%rbp), %r10
leaq -0x58(%rbp), %rax
movq %rbx, (%rsp)
movq %r11, 0x8(%rsp)
movq %r10, 0x10(%rsp)
movq %rax, 0x18(%rsp)
callq 0x1f1280
cmpl $0x0, %eax
je 0x1f22ed
jmp 0x1f2377
cmpq $-0x1, -0x50(%rbp)
je 0x1f22fb
cmpq $-0x1, -0x58(%rbp)
jne 0x1f2300
jmp 0x1f226a
movq 0x10(%rbp), %rax
movsd 0x30(%rax), %xmm0
movq -0x30(%rbp), %rax
ucomisd 0x18(%rax), %xmm0
jbe 0x1f2372
movq -0x30(%rbp), %rax
movsd 0x18(%rax), %xmm0
movq 0x10(%rbp), %rax
movsd %xmm0, 0x30(%rax)
movq -0x40(%rbp), %rcx
movq 0x10(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x48(%rbp), %rcx
movq 0x10(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x50(%rbp), %rcx
movq 0x10(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x58(%rbp), %rcx
movq 0x10(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x30(%rbp), %rax
movq 0x30(%rax), %rcx
movq 0x10(%rbp), %rax
movq %rcx, (%rax)
movl -0x34(%rbp), %eax
movl %eax, %ecx
movq 0x10(%rbp), %rax
movq %rcx, 0x28(%rax)
jmp 0x1f226a
addq $0x88, %rsp
popq %rbx
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/hic.cpp
// Function: phasing_improvement_by_block(H_partition*, G_partition*, bubble_type*, mul_block_phase_type*)
void phasing_improvement_by_block(H_partition* h, G_partition* g_p, bubble_type* bub, mul_block_phase_type* x)
{
    long long min_u, min_f_bid, min_f_uid, min_l_bid, min_l_uid; 
    double min_w;

    memset(h->lock, 0, sizeof(uint8_t)*h->n);
    while(get_max_block_multi_thread(h, g_p, bub, x, &min_u, &min_f_bid, &min_f_uid, &min_l_bid, &min_l_uid, &min_w))
    ///while(get_max_block(h, g_p, bub, &min_u, &min_f_bid, &min_f_uid, &min_l_bid, &min_l_uid, &min_w))
    {
        ///fprintf(stderr, "\nmin_w: %f, min_u: %lld, min_f_bid: %lld, min_f_uid: %lld, min_l_bid: %lld, min_l_uid: %lld\n", min_w, min_u, min_f_bid, min_f_uid, min_l_bid, min_l_uid);
        ///fprintf(stderr, "before weight: %f\n", get_total_weight(h, g_p));
        flip_block(&(h->b), g_p, bub, &(bub->b_ug->u.a[min_u]), h->link, h->lock, min_f_bid, 
        min_f_uid, min_l_bid, min_l_uid);
        ///fprintf(stderr, "after weight: %f\n", get_total_weight(h, g_p));
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x78, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rdx
shlq $0x0, %rdx
xorl %esi, %esi
callq 0x2100
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
movq -0x28(%rbp), %rcx
leaq -0x30(%rbp), %r8
leaq -0x38(%rbp), %r9
leaq -0x40(%rbp), %rbx
leaq -0x48(%rbp), %r11
leaq -0x50(%rbp), %r10
leaq -0x58(%rbp), %rax
movq %rbx, (%rsp)
movq %r11, 0x8(%rsp)
movq %r10, 0x10(%rsp)
movq %rax, 0x18(%rsp)
callq 0x1f2390
cmpl $0x0, %eax
je 0x1f2c8f
movq -0x10(%rbp), %rdi
addq $0x90, %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
movq -0x20(%rbp), %rax
movq 0xc0(%rax), %rax
movq 0x10(%rax), %rcx
imulq $0x28, -0x30(%rbp), %rax
addq %rax, %rcx
movq -0x10(%rbp), %rax
movq 0x30(%rax), %r8
movq -0x10(%rbp), %rax
movq 0x8(%rax), %r9
movq -0x38(%rbp), %rbx
movq -0x40(%rbp), %r11
movq -0x48(%rbp), %r10
movq -0x50(%rbp), %rax
movq %rbx, (%rsp)
movq %r11, 0x8(%rsp)
movq %r10, 0x10(%rsp)
movq %rax, 0x18(%rsp)
callq 0x1f16b0
jmp 0x1f2be3
addq $0x78, %rsp
popq %rbx
popq %rbp
retq
nopw %cs:(%rax,%rax)