// File: /workspace/github_cpp_makefile_star2_O3/chhylp123[P]hifiasm/hic.cpp
// Function: get_chain_weight_hic(bubble_type*, ma_ug_t*, buf_t*, unsigned int, unsigned int, kv_u_trans_t*, unsigned char*, unsigned char*, ma_ug_t*, kvec_t_u32_warp*, kvec_t_u32_warp*, unsigned int, unsigned int, kvec_t_u32_warp*, unsigned int*)
double get_chain_weight_hic(bubble_type* bub, ma_ug_t *bub_ug, buf_t* b, uint32_t v, uint32_t convex_source, 
kv_u_trans_t *ta, uint8_t* vis_flag, uint8_t* is_vis, ma_ug_t* ug, kvec_t_u32_warp* stack, 
kvec_t_u32_warp* result, uint32_t e_flag, uint32_t ava_flag, kvec_t_u32_warp* res_utg, uint32_t* link_occ)
{
    long long nodeLen, baseLen, max_stop_nodeLen, max_stop_baseLen;
    ma_utg_t *u = NULL;
    uint32_t convex, k, k_i, k_j, *a, n, beg, sink, uID, root, cur, ncur, n_vx = ug->g->n_seq<<1, occ;
    asg_arc_t *acur = NULL;
    double w = 0;
    b->b.n = 0;
    get_unitig(bub_ug->g, NULL, v, &convex, &nodeLen, &baseLen, &max_stop_nodeLen, 
                                                                    &max_stop_baseLen, 1, b);
    memset(is_vis, 0, n_vx);

    for (k = 0; k < b->b.n; k++)
    {
        u = &(bub_ug->u.a[b->b.a[k]>>1]);
        if(u->n == 0) continue;

        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++) is_vis[a[k_j]] = is_vis[a[k_j]^1] = 1;
            if(beg != (uint32_t)-1) is_vis[beg] = is_vis[beg^1] = 1; 
            if(sink != (uint32_t)-1) is_vis[sink] = is_vis[sink^1] = 1; 
        }
    }

    u = &(bub_ug->u.a[v>>1]);
    if((v&1)==0)
    {
        get_bubbles(bub, (u->a[0]>>32)>>1, (((u->a[0]>>32)&1)^1)==1?&root:NULL, 
                                    (((u->a[0]>>32)&1)^1) == 0?&root:NULL, NULL, NULL, NULL);
    } 
    else
    {
        get_bubbles(bub, (u->a[u->n-1]>>32)>>1, ((u->a[u->n-1]>>32)&1)==1?&root:NULL, 
                                    ((u->a[u->n-1]>>32)&1) == 0?&root:NULL, NULL, NULL, NULL);
    }
    
    root ^= 1;
    is_vis[root] = 0; 
    stack->a.n = 0;
    kv_push(uint32_t, stack->a, root);
    while (stack->a.n > 0)///label all untigs not in any chain
    {
        stack->a.n--;
        cur = stack->a.a[stack->a.n];
        if(is_vis[cur]) continue;
        is_vis[cur] = 1;
        if(vis_flag[cur>>1] == 0) vis_flag[cur>>1] = ava_flag;///unitig not in any chain
       
        ncur = asg_arc_n(ug->g, cur);
        acur = asg_arc_a(ug->g, cur);
        for (k = 0; k < ncur; k++)
        {
            if(acur[k].del) continue;
            if(is_vis[acur[k].v]) continue;
            if(vis_flag[acur[k].v>>1] != 0 && vis_flag[acur[k].v>>1] != ava_flag) continue;
            kv_push(uint32_t, stack->a, acur[k].v);
        }
    }


    ///vis_flag keeps isloated nodes
    uint32_t aim_0, aim_1, root_source;
    aim_0 = root>>1;
    u = &(bub_ug->u.a[convex_source>>1]);
    if((convex_source&1)==1)
    {
        get_bubbles(bub, (u->a[0]>>32)>>1, (((u->a[0]>>32)&1)^1)==1?&root_source:NULL, 
                                    (((u->a[0]>>32)&1)^1) == 0?&root_source:NULL, NULL, NULL, NULL);
    } 
    else
    {
        get_bubbles(bub, (u->a[u->n-1]>>32)>>1, ((u->a[u->n-1]>>32)&1)==1?&root_source:NULL, 
                                    ((u->a[u->n-1]>>32)&1) == 0?&root_source:NULL, NULL, NULL, NULL);
    }
    root_source ^= 1;
    aim_1 = root_source>>1;


    cur = root_source;///scan nodes that cannot be reached from root but can be reached from root_source
    ncur = asg_arc_n(ug->g, cur);
    acur = asg_arc_a(ug->g, cur);
    for (k_i = 0; k_i < ncur; k_i++)
    {
        if(acur[k_i].del) continue;
        if(vis_flag[acur[k_i].v>>1] != 0) continue;///skip nodes that are already reachable
        ///don't label any path that can reack other chains
        if_conflict_utg(acur[k_i].v, &aim_0, &aim_1, ug, vis_flag, is_vis, ava_flag, stack);
    }


    for (k = 0; k < ug->g->n_seq; k++)
    {
        if(vis_flag[k] == ava_flag)
        {
            cur = k<<1;
            ncur = asg_arc_n(ug->g, cur);
            acur = asg_arc_a(ug->g, cur);
            for (k_i = 0; k_i < ncur; k_i++)
            {
                if(acur[k_i].del) continue;
                if(vis_flag[acur[k_i].v>>1] != 0) continue;
                if_conflict_utg(acur[k_i].v, &aim_0, &aim_1, ug, vis_flag, is_vis, ava_flag, stack);
            }



            cur = (k<<1)+1;
            ncur = asg_arc_n(ug->g, cur);
            acur = asg_arc_a(ug->g, cur);
            for (k_i = 0; k_i < ncur; k_i++)
            {
                if(acur[k_i].del) continue;
                if(vis_flag[acur[k_i].v>>1] != 0) continue;
                if_conflict_utg(acur[k_i].v, &aim_0, &aim_1, ug, vis_flag, is_vis, ava_flag, stack);
            }
        }
    }
    


    memset(is_vis, 0, n_vx);
    if(link_occ) (*link_occ) = 0;
    for (k = result->a.n = 0, w = 0; k < b->b.n; k++)
    {
        u = &(bub_ug->u.a[b->b.a[k]>>1]);
        if(u->n == 0) continue;
        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++)
            {
                uID = a[k_j]>>1;
                w += dfs_weight_hic(uID, vis_flag, is_vis, ta, stack, result, e_flag, ava_flag, &occ);
                if(link_occ) (*link_occ) += occ;
            }
        }
    }


    for (k = 0; k < ug->g->n_seq; k++)
    {
        if(vis_flag[k] == ava_flag)
        {
            vis_flag[k] = 0;
            if(res_utg && (!IF_HOM(k, *bub)))
            {
                kv_push(uint32_t, res_utg->a, k<<1);
            }
        }
    }

    return w;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %r9, 0x48(%rsp)
movl %r8d, 0x30(%rsp)
movl %ecx, %r13d
movq %rdx, %r14
movq %rdi, %rbp
movq 0xc0(%rsp), %rax
movq 0xb8(%rsp), %r15
movq 0x18(%rax), %rax
movl 0x14(%rax), %r12d
addl %r12d, %r12d
movq $0x0, 0x38(%rdx)
movq %rsi, 0x28(%rsp)
movq 0x18(%rsi), %rdi
leaq 0x58(%rsp), %rax
leaq 0x60(%rsp), %r10
xorl %ebx, %ebx
leaq 0x54(%rsp), %rcx
leaq 0x70(%rsp), %r8
leaq 0x68(%rsp), %r9
xorl %esi, %esi
movl %r13d, %edx
pushq %r14
pushq $0x1
pushq %rax
pushq %r10
callq 0x1053a7
addq $0x20, %rsp
movq %r15, %rdi
xorl %esi, %esi
movq %r12, 0x18(%rsp)
movq %r12, %rdx
callq 0x20e0
movq 0x38(%r14), %rcx
testq %rcx, %rcx
je 0x158bc1
movb $0x1, %al
movq 0x28(%rsp), %rdx
movq 0x10(%rdx), %rdx
movq 0x48(%r14), %rsi
movl (%rsi,%rbx,4), %esi
shrl %esi
leaq (%rsi,%rsi,4), %rsi
cmpl $0x0, 0x10(%rdx,%rsi,8)
je 0x158bb6
leaq (%rdx,%rsi,8), %rcx
xorl %edx, %edx
movq 0x18(%rcx), %rsi
movq (%rsi,%rdx,8), %rsi
movq 0x28(%rbp), %r8
movq 0x40(%rbp), %rdi
shrq $0x21, %rsi
movl (%rdi,%rsi,4), %r10d
movl 0x4(%rdi,%rsi,4), %r9d
subl %r10d, %r9d
leal 0x1(%r10), %esi
movl (%r8,%r10,4), %edi
movl (%r8,%rsi,4), %esi
addl $-0x2, %r9d
je 0x158b7b
leaq (%r8,%r10,4), %r8
movl %r9d, %r9d
xorl %r10d, %r10d
movl 0x8(%r8,%r10,4), %r11d
xorq $0x1, %r11
movb %al, (%r15,%r11)
movl 0x8(%r8,%r10,4), %r11d
movb %al, (%r15,%r11)
incq %r10
cmpq %r10, %r9
jne 0x158b5d
cmpl $-0x1, %edi
je 0x158b8f
movq %rdi, %r8
xorq $0x1, %r8
movb %al, (%r15,%r8)
movb %al, (%r15,%rdi)
cmpl $-0x1, %esi
je 0x158ba3
movq %rsi, %rdi
xorq $0x1, %rdi
movb %al, (%r15,%rdi)
movb %al, (%r15,%rsi)
incq %rdx
movl 0x10(%rcx), %esi
cmpq %rsi, %rdx
jb 0x158b21
movq 0x38(%r14), %rcx
incl %ebx
cmpq %rbx, %rcx
ja 0x158afa
movq 0xc8(%rsp), %r10
movq 0x28(%rsp), %rax
movq 0x10(%rax), %rcx
movl %r13d, %eax
shrl %eax
leaq (%rax,%rax,4), %rdx
movq 0x18(%rcx,%rdx,8), %rax
testb $0x1, %r13b
jne 0x158c01
movq (%rax), %rcx
movq 0x40(%rbp), %rax
movq %rcx, %rdx
shrq $0x21, %rdx
movl (%rax,%rdx,4), %eax
btq $0x20, %rcx
adcl $0x0, %eax
jmp 0x158c24
leaq (%rcx,%rdx,8), %rcx
movl 0x10(%rcx), %ecx
decl %ecx
movq (%rax,%rcx,8), %rax
movq %rax, %rcx
shrq $0x21, %rcx
btq $0x20, %rax
movq 0x40(%rbp), %rax
movl (%rax,%rcx,4), %eax
sbbl $-0x1, %eax
movq %r14, 0x10(%rsp)
movq 0x28(%rbp), %rcx
movl %eax, %eax
movl (%rcx,%rax,4), %ebx
movq %rbx, 0x20(%rsp)
xorq $0x1, %rbx
movb $0x0, (%r15,%rbx)
movq $0x0, (%r10)
cmpq $0x0, 0x8(%r10)
je 0x158c60
movq 0x10(%r10), %rax
movl %ebx, (%rax)
movl $0x1, %ecx
movl 0x30(%rsp), %r15d
jmp 0x158c9c
movq $0x2, 0x8(%r10)
movq 0x10(%r10), %rdi
movl $0x8, %esi
callq 0x2370
movq 0xc8(%rsp), %r10
movq %rax, 0x10(%r10)
movq (%r10), %rdx
movq %rdx, %rcx
incq %rcx
movq %rcx, (%r10)
movl %ebx, (%rax,%rdx,4)
movl 0x30(%rsp), %r15d
je 0x158dc7
movl $0x2, %r12d
leaq -0x1(%rcx), %rax
movq %rax, (%r10)
movq 0x10(%r10), %rax
movl -0x4(%rax,%rcx,4), %eax
movq 0xb8(%rsp), %rcx
cmpb $0x0, (%rcx,%rax)
jne 0x158dbb
movb $0x1, (%rcx,%rax)
movl %eax, %ecx
shrl %ecx
movq 0xb0(%rsp), %rdx
cmpb $0x0, (%rdx,%rcx)
jne 0x158ceb
movl 0xe0(%rsp), %edx
movq 0xb0(%rsp), %rsi
movb %dl, (%rsi,%rcx)
movq 0xc0(%rsp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rdx
movq (%rdx,%rax,8), %rax
testl %eax, %eax
je 0x158dbb
movq 0x8(%rcx), %rcx
movq %rax, %rdx
shrq $0x20, %rdx
movl %eax, %eax
leaq (%rdx,%rdx,2), %rdx
leaq (%rcx,%rdx,8), %r14
addq $0x8, %r14
shlq $0x3, %rax
leaq (%rax,%rax,2), %r13
xorl %ebx, %ebx
cmpl $0x0, 0x4(%r14,%rbx)
js 0x158dae
movl (%r14,%rbx), %ecx
movq 0xb8(%rsp), %rax
cmpb $0x0, (%rax,%rcx)
jne 0x158dae
movl %ecx, %eax
shrl %eax
movq 0xb0(%rsp), %rdx
movzbl (%rdx,%rax), %eax
testl %eax, %eax
setne %dl
movl 0xe0(%rsp), %esi
cmpl %esi, %eax
setne %al
testb %al, %dl
jne 0x158dae
movq (%r10), %rdx
movq 0x10(%r10), %rax
cmpq 0x8(%r10), %rdx
jne 0x158da4
leaq (%rdx,%rdx), %rsi
testq %rdx, %rdx
cmoveq %r12, %rsi
movq %rsi, 0x8(%r10)
shlq $0x2, %rsi
movq %rax, %rdi
callq 0x2370
movq 0xc8(%rsp), %r10
movq %rax, 0x10(%r10)
movl (%r14,%rbx), %ecx
movq (%r10), %rdx
leaq 0x1(%rdx), %rsi
movq %rsi, (%r10)
movl %ecx, (%rax,%rdx,4)
addq $0x18, %rbx
cmpq %rbx, %r13
jne 0x158d2a
movq (%r10), %rcx
testq %rcx, %rcx
jne 0x158ca2
movq 0x20(%rsp), %rax
shrl %eax
movl %eax, 0xc(%rsp)
movq 0x28(%rsp), %rax
movq 0x10(%rax), %rax
movl %r15d, %ecx
shrl %ecx
leaq (%rcx,%rcx,4), %rdx
movq 0x18(%rax,%rdx,8), %rcx
testb $0x1, %r15b
jne 0x158e14
leaq (%rax,%rdx,8), %rax
movl 0x10(%rax), %eax
decl %eax
movq (%rcx,%rax,8), %rax
movq %rax, %rcx
shrq $0x21, %rcx
btq $0x20, %rax
movq 0x40(%rbp), %rax
movl (%rax,%rcx,4), %eax
sbbl $-0x1, %eax
jmp 0x158e2d
movq (%rcx), %rcx
movq 0x40(%rbp), %rax
movq %rcx, %rdx
shrq $0x21, %rdx
movl (%rax,%rdx,4), %eax
btq $0x20, %rcx
adcl $0x0, %eax
movq 0xc0(%rsp), %r12
movq 0x10(%rsp), %r14
movq 0x28(%rbp), %rcx
movl %eax, %eax
movl (%rcx,%rax,4), %eax
movq %rax, %rcx
xorq $0x1, %rcx
shrl %eax
movl %eax, 0x8(%rsp)
movq 0x18(%r12), %rax
movq 0x28(%rax), %rdx
movq (%rdx,%rcx,8), %rdx
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
andq %rdx, %rcx
je 0x158ef6
movq 0x8(%rax), %rax
shrq $0x20, %rdx
leaq (%rdx,%rdx,2), %rdx
leaq (%rax,%rdx,8), %rbx
addq $0xc, %rbx
shlq $0x3, %rcx
leaq (%rcx,%rcx,2), %r14
xorl %r15d, %r15d
leaq 0xc(%rsp), %r13
cmpl $0x0, (%rbx,%r15)
js 0x158ee3
movl -0x4(%rbx,%r15), %edi
movl %edi, %eax
shrl %eax
movq 0xb0(%rsp), %rcx
cmpb $0x0, (%rcx,%rax)
jne 0x158ee3
movq %r13, %rsi
leaq 0x8(%rsp), %rdx
movq %r12, %rcx
movq 0xb0(%rsp), %r8
movq 0xb8(%rsp), %r9
pushq %r10
movl 0xe8(%rsp), %eax
pushq %rax
callq 0x1503f7
movq 0xd8(%rsp), %r10
addq $0x10, %rsp
addq $0x18, %r15
cmpq %r15, %r14
jne 0x158e8f
movq 0x18(%r12), %rax
movq 0x10(%rsp), %r14
testl $0x7fffffff, 0x14(%rax) # imm = 0x7FFFFFFF
je 0x159081
xorl %r13d, %r13d
movq 0xb0(%rsp), %rcx
movzbl (%rcx,%r13), %ecx
movl 0xe0(%rsp), %edx
cmpl %edx, %ecx
jne 0x15906c
movq 0x8(%rax), %rcx
movq 0x28(%rax), %rdx
movq %r13, %rsi
shlq $0x4, %rsi
movq (%rdx,%rsi), %rsi
testl %esi, %esi
je 0x158fce
movq %rsi, %rax
shrq $0x20, %rax
movl %esi, %edx
leaq (%rax,%rax,2), %rax
leaq (%rcx,%rax,8), %r14
addq $0xc, %r14
shlq $0x3, %rdx
leaq (%rdx,%rdx,2), %rbx
xorl %r15d, %r15d
cmpl $0x0, (%r14,%r15)
js 0x158fb3
movl -0x4(%r14,%r15), %edi
movl %edi, %eax
shrl %eax
movq 0xb0(%rsp), %rcx
cmpb $0x0, (%rcx,%rax)
jne 0x158fb3
leaq 0xc(%rsp), %rsi
leaq 0x8(%rsp), %rdx
movq %r12, %rcx
movq 0xb0(%rsp), %r8
movq 0xb8(%rsp), %r9
pushq %r10
movl 0xe8(%rsp), %eax
pushq %rax
callq 0x1503f7
movq 0xd8(%rsp), %r10
addq $0x10, %rsp
addq $0x18, %r15
cmpq %r15, %rbx
jne 0x158f5d
movq 0x18(%r12), %rax
movq 0x8(%rax), %rcx
movq 0x28(%rax), %rdx
movq 0x10(%rsp), %r14
leaq (,%r13,2), %rsi
movq 0x8(%rdx,%rsi,8), %rdx
testl %edx, %edx
je 0x15906c
movq %rdx, %rax
shrq $0x20, %rax
movl %edx, %edx
leaq (%rax,%rax,2), %rax
leaq (%rcx,%rax,8), %r14
addq $0xc, %r14
shlq $0x3, %rdx
leaq (%rdx,%rdx,2), %rbx
xorl %r15d, %r15d
cmpl $0x0, (%r14,%r15)
js 0x159059
movl -0x4(%r14,%r15), %edi
movl %edi, %eax
shrl %eax
movq 0xb0(%rsp), %rcx
cmpb $0x0, (%rcx,%rax)
jne 0x159059
leaq 0xc(%rsp), %rsi
leaq 0x8(%rsp), %rdx
movq %r12, %rcx
movq 0xb0(%rsp), %r8
movq 0xb8(%rsp), %r9
pushq %r10
movl 0xe8(%rsp), %eax
pushq %rax
callq 0x1503f7
movq 0xd8(%rsp), %r10
addq $0x10, %rsp
addq $0x18, %r15
cmpq %r15, %rbx
jne 0x159003
movq 0x18(%r12), %rax
movq 0x10(%rsp), %r14
incq %r13
movl 0x14(%rax), %ecx
andl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
cmpq %rcx, %r13
jb 0x158f06
movq 0xd0(%rsp), %rbx
movq 0xb8(%rsp), %rdi
xorl %esi, %esi
movq 0x18(%rsp), %rdx
callq 0x20e0
movq 0xf0(%rsp), %rax
testq %rax, %rax
je 0x1590b0
movl $0x0, (%rax)
movq $0x0, (%rbx)
movq 0x38(%r14), %rax
testq %rax, %rax
movq 0xc8(%rsp), %r8
je 0x1591ec
movl 0xd8(%rsp), %r12d
xorl %esi, %esi
xorpd %xmm0, %xmm0
movsd %xmm0, 0x18(%rsp)
leaq 0x3c(%rsp), %r13
movq %rbp, 0x40(%rsp)
movq 0x28(%rsp), %rcx
movq 0x10(%rcx), %rdx
movq 0x48(%r14), %rcx
movq %rsi, 0x20(%rsp)
movl (%rcx,%rsi,4), %ecx
shrl %ecx
leaq (%rcx,%rcx,4), %rsi
movl 0x10(%rdx,%rsi,8), %ecx
testl %ecx, %ecx
je 0x1591da
leaq (%rdx,%rsi,8), %rdi
xorl %r14d, %r14d
movq %rdi, 0x30(%rsp)
movq 0x18(%rdi), %rax
movq (%rax,%r14,8), %rax
movq 0x40(%rbp), %rsi
shrq $0x21, %rax
movl (%rsi,%rax,4), %edx
movl 0x4(%rsi,%rax,4), %eax
subl %edx, %eax
addl $-0x2, %eax
je 0x1591c3
movq 0x28(%rbp), %rcx
leaq (%rcx,%rdx,4), %r15
addq $0x8, %r15
movl %eax, %ebp
xorl %ebx, %ebx
movl (%r15,%rbx,4), %edi
shrl %edi
subq $0x8, %rsp
movq 0xb8(%rsp), %rsi
movq 0xc0(%rsp), %rdx
movq 0x50(%rsp), %rcx
pushq %r13
movl 0xf0(%rsp), %eax
pushq %rax
pushq %r12
callq 0x15884c
movq 0x110(%rsp), %rcx
addq $0x20, %rsp
testq %rcx, %rcx
je 0x159196
movl 0x3c(%rsp), %eax
addl %eax, (%rcx)
movsd 0x18(%rsp), %xmm1
addsd %xmm0, %xmm1
movsd %xmm1, 0x18(%rsp)
incq %rbx
cmpq %rbx, %rbp
movq 0xc8(%rsp), %r8
jne 0x15914f
movq 0x30(%rsp), %rdi
movl 0x10(%rdi), %ecx
movq 0x40(%rsp), %rbp
incq %r14
movl %ecx, %eax
cmpq %rax, %r14
jb 0x15911d
movq 0x10(%rsp), %r14
movq 0x38(%r14), %rax
movq 0x20(%rsp), %rsi
incl %esi
cmpq %rsi, %rax
ja 0x1590ea
jmp 0x1591f6
xorpd %xmm0, %xmm0
movsd %xmm0, 0x18(%rsp)
movq 0xc0(%rsp), %r13
movq 0x18(%r13), %rax
testl $0x7fffffff, 0x14(%rax) # imm = 0x7FFFFFFF
je 0x1592ba
movq 0xe8(%rsp), %rbx
xorl %r14d, %r14d
movl $0x2, %r15d
xorl %r12d, %r12d
movq 0xb0(%rsp), %rax
movzbl (%rax,%r12), %eax
movl 0xe0(%rsp), %ecx
cmpl %ecx, %eax
jne 0x15929e
movq 0xb0(%rsp), %rax
movb $0x0, (%rax,%r12)
testq %rbx, %rbx
je 0x15929e
movq (%rbp), %rax
movq 0x80(%rbp), %rcx
movl (%rax,%r12,4), %eax
incq %rcx
cmpq %rax, %rcx
jb 0x15929e
movq (%rbx), %rcx
movq 0x10(%rbx), %rax
cmpq 0x8(%rbx), %rcx
jne 0x159293
leaq (%rcx,%rcx), %rsi
testq %rcx, %rcx
cmoveq %r15, %rsi
movq %rsi, 0x8(%rbx)
shlq $0x2, %rsi
movq %rax, %rdi
callq 0x2370
movq %rax, 0x10(%rbx)
movq (%rbx), %rcx
leaq 0x1(%rcx), %rdx
movq %rdx, (%rbx)
movl %r14d, (%rax,%rcx,4)
incq %r12
movq 0x18(%r13), %rax
movl 0x14(%rax), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
addl $0x2, %r14d
cmpq %rax, %r12
jb 0x159223
movsd 0x18(%rsp), %xmm0
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq