// File: chhylp123[P]hifiasm/hic.cpp
// Function: collect_hc_reverse_links(hc_links*, ma_ug_t*, bubble_type*)
void collect_hc_reverse_links(hc_links* link, ma_ug_t* ug, bubble_type* bub)
{
    uint64_t i, j, k, d = RC_0, m, pre;
    uint32_t beg, sink, n, v, *a = NULL;
    kvec_t_u32_warp stack, result;
    hc_edge *e = NULL;
    kv_init(stack.a); kv_init(result.a);
    ///clean all reverse overlaps within bubbles
    ///might be wrong
    for (i = 0; i < bub->f_bub; i++)
    {
        get_bubbles(bub, i, &beg, &sink, &a, &n, NULL);
        for (k = 0; k < n; k++)
        {
            v = a[k]>>1;
            for (j = 0; j < link->a.a[v].f.n; j++)
            {
                if(link->a.a[v].f.a[j].del) continue;
                e = get_hc_edge(link, link->a.a[v].f.a[j].uID, v, 1);
                e->del = 1;
            }
            link->a.a[v].f.n = 0;
        }

        v = beg>>1; 
        if(IF_HOM(v, *bub))
        {
            for (j = 0; j < link->a.a[v].f.n; j++)
            {
                if(link->a.a[v].f.a[j].del) continue;
                e = get_hc_edge(link, link->a.a[v].f.a[j].uID, v, 1);
                e->del = 1;
            }
            link->a.a[v].f.n = 0;
        }

        v = sink>>1;
        if(IF_HOM(v, *bub))
        {
            for (j = 0; j < link->a.a[v].f.n; j++)
            {
                if(link->a.a[v].f.a[j].del) continue;
                e = get_hc_edge(link, link->a.a[v].f.a[j].uID, v, 1);
                e->del = 1;
            }
            link->a.a[v].f.n = 0;
        }
    }

    for (i = 0; i < bub->f_bub; i++)
    {
        get_bubbles(bub, i, &beg, &sink, &a, &n, NULL);
        if(n == 2)
        {
            push_hc_edge(&(link->a.a[a[0]>>1]), a[1]>>1, 1, 1, &d);
            push_hc_edge(&(link->a.a[a[1]>>1]), a[0]>>1, 1, 1, &d);
            continue;
        }
        ///for complex bubbles, shouldn't have any assumption
        ///if(i >= bub->s_bub) continue;

        beg = beg>>1; sink = sink>>1;
        for (k = 0; k < n; k++)
        {
            v = a[k]>>1;
            dfs_bubble(ug->g, &stack, &result, v, beg, sink);
            set_reverse_links(a, n, &result, v, link);
        }
    }
    
    uint8_t* vis_flag = NULL;
    MALLOC(vis_flag, ug->g->n_seq*2);
    ///for broken bubbles
    for (i = bub->f_bub; i < bub->f_bub + bub->b_bub; i++)
    {
        get_bubbles(bub, i, &beg, &sink, &a, &n, NULL);

        for (k = 0; k < n; k++)
        {
            v = a[k];
            dfs_bubble_broken(ug->g, &stack, &result, vis_flag, ug->g->n_seq*2, v, beg, sink);
            set_reverse_links(a, n, &result, v>>1, link);
        }
    }
    
    kv_destroy(stack.a); kv_destroy(result.a); free(vis_flag);


    for (i = 0; i < link->a.n; i++)
    {
        for (k = m = 0; k < link->a.a[i].f.n; k++)
        {
            if(link->a.a[i].f.a[k].del) continue;
            link->a.a[i].f.a[m] = link->a.a[i].f.a[k];
            m++;
        }
        link->a.a[i].f.n = m;
        radix_sort_hc_edge_u(link->a.a[i].f.a, link->a.a[i].f.a + link->a.a[i].f.n);

        for (k = m = 0, pre = (uint64_t)-1; k < link->a.a[i].f.n; k++)
        {
            if(link->a.a[i].f.a[k].del) continue;
            if(link->a.a[i].f.a[k].uID == pre)
            {
                if(link->a.a[i].f.a[k].dis == RC_0) link->a.a[i].f.a[m-1].dis = RC_0;
                continue;
            }
             
            pre = link->a.a[i].f.a[k].uID;
            link->a.a[i].f.a[m] = link->a.a[i].f.a[k];
            m++;
        }
        link->a.a[i].f.n = m;
        radix_sort_hc_edge_d(link->a.a[i].f.a, link->a.a[i].f.a + link->a.a[i].f.n);
    }


    // hc_edge *e = NULL;
    // for (i = 0; i < link->a.n; i++)
    // {
    //     for (k = 0; k < link->a.a[i].f.n; k++)
    //     {
    //         if(link->a.a[i].f.a[k].del) continue;
    //         e = get_hc_edge(link, link->a.a[i].f.a[k].uID, i, 1);
    //         if(e == NULL) fprintf(stderr, "ERROR\n");
    //     }
    // }
    
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xc0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq $0x0, -0x38(%rbp)
movq $0x0, -0x60(%rbp)
movq $0x0, -0xa8(%rbp)
movq $0x0, -0x78(%rbp)
movq $0x0, -0x80(%rbp)
movq $0x0, -0x70(%rbp)
movq $0x0, -0x98(%rbp)
movq $0x0, -0xa0(%rbp)
movq $0x0, -0x90(%rbp)
movq $0x0, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rcx
cmpq 0x80(%rcx), %rax
jae 0x1d39dc
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rsi
leaq -0x4c(%rbp), %rdx
leaq -0x50(%rbp), %rcx
leaq -0x60(%rbp), %r8
leaq -0x54(%rbp), %r9
xorl %eax, %eax
movq $0x0, (%rsp)
callq 0x1c4b20
movq $0x0, -0x30(%rbp)
movq -0x30(%rbp), %rax
movl -0x54(%rbp), %ecx
cmpq %rcx, %rax
jae 0x1d37d5
movq -0x60(%rbp), %rax
movq -0x30(%rbp), %rcx
movl (%rax,%rcx,4), %eax
shrl %eax
movl %eax, -0x58(%rbp)
movq $0x0, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq -0x8(%rbp), %rcx
movq 0x10(%rcx), %rcx
movl -0x58(%rbp), %edx
imulq $0x30, %rdx, %rdx
addq %rdx, %rcx
cmpq 0x18(%rcx), %rax
jae 0x1d37aa
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x58(%rbp), %ecx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
imulq $0x28, -0x28(%rbp), %rcx
addq %rcx, %rax
movb 0x18(%rax), %al
shrb $0x7, %al
cmpb $0x0, %al
je 0x1d3749
jmp 0x1d3799
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x58(%rbp), %ecx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
imulq $0x28, -0x28(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
movl %eax, %esi
movl -0x58(%rbp), %eax
movl %eax, %edx
movl $0x1, %ecx
callq 0x1d09c0
movq %rax, -0xa8(%rbp)
movq -0xa8(%rbp), %rax
movb 0x18(%rax), %cl
andb $0x7f, %cl
orb $-0x80, %cl
movb %cl, 0x18(%rax)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x1d36ff
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x58(%rbp), %ecx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movq $0x0, 0x18(%rax)
movq -0x30(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
jmp 0x1d36d7
movl -0x4c(%rbp), %eax
shrl %eax
movl %eax, -0x58(%rbp)
movq -0x18(%rbp), %rax
movq (%rax), %rax
movl -0x58(%rbp), %ecx
movl (%rax,%rcx,4), %eax
movq -0x18(%rbp), %rcx
movq 0x80(%rcx), %rcx
addq $0x1, %rcx
cmpq %rcx, %rax
jbe 0x1d38cf
movq $0x0, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq -0x8(%rbp), %rcx
movq 0x10(%rcx), %rcx
movl -0x58(%rbp), %edx
imulq $0x30, %rdx, %rdx
addq %rdx, %rcx
cmpq 0x18(%rcx), %rax
jae 0x1d38b5
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x58(%rbp), %ecx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
imulq $0x28, -0x28(%rbp), %rcx
addq %rcx, %rax
movb 0x18(%rax), %al
shrb $0x7, %al
cmpb $0x0, %al
je 0x1d3854
jmp 0x1d38a4
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x58(%rbp), %ecx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
imulq $0x28, -0x28(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
movl %eax, %esi
movl -0x58(%rbp), %eax
movl %eax, %edx
movl $0x1, %ecx
callq 0x1d09c0
movq %rax, -0xa8(%rbp)
movq -0xa8(%rbp), %rax
movb 0x18(%rax), %cl
andb $0x7f, %cl
orb $-0x80, %cl
movb %cl, 0x18(%rax)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x1d380a
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x58(%rbp), %ecx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movq $0x0, 0x18(%rax)
movl -0x50(%rbp), %eax
shrl %eax
movl %eax, -0x58(%rbp)
movq -0x18(%rbp), %rax
movq (%rax), %rax
movl -0x58(%rbp), %ecx
movl (%rax,%rcx,4), %eax
movq -0x18(%rbp), %rcx
movq 0x80(%rcx), %rcx
addq $0x1, %rcx
cmpq %rcx, %rax
jbe 0x1d39c9
movq $0x0, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq -0x8(%rbp), %rcx
movq 0x10(%rcx), %rcx
movl -0x58(%rbp), %edx
imulq $0x30, %rdx, %rdx
addq %rdx, %rcx
cmpq 0x18(%rcx), %rax
jae 0x1d39af
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x58(%rbp), %ecx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
imulq $0x28, -0x28(%rbp), %rcx
addq %rcx, %rax
movb 0x18(%rax), %al
shrb $0x7, %al
cmpb $0x0, %al
je 0x1d394e
jmp 0x1d399e
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x58(%rbp), %ecx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
imulq $0x28, -0x28(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
movl %eax, %esi
movl -0x58(%rbp), %eax
movl %eax, %edx
movl $0x1, %ecx
callq 0x1d09c0
movq %rax, -0xa8(%rbp)
movq -0xa8(%rbp), %rax
movb 0x18(%rax), %cl
andb $0x7f, %cl
orb $-0x80, %cl
movb %cl, 0x18(%rax)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x1d3904
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x58(%rbp), %ecx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movq $0x0, 0x18(%rax)
jmp 0x1d39cb
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
jmp 0x1d3693
movq $0x0, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rcx
cmpq 0x80(%rcx), %rax
jae 0x1d3b35
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rsi
leaq -0x4c(%rbp), %rdx
leaq -0x50(%rbp), %rcx
leaq -0x60(%rbp), %r8
leaq -0x54(%rbp), %r9
xorl %eax, %eax
movq $0x0, (%rsp)
callq 0x1c4b20
cmpl $0x2, -0x54(%rbp)
jne 0x1d3aa3
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x60(%rbp), %rax
movl (%rax), %eax
shrl %eax
movl %eax, %eax
imulq $0x30, %rax, %rax
addq %rax, %rdi
movq -0x60(%rbp), %rax
movl 0x4(%rax), %eax
shrl %eax
movl %eax, %eax
movl %eax, %esi
movsd 0x1ae5ac(%rip), %xmm0   # 0x382000
movl $0x1, %edx
leaq -0x38(%rbp), %rcx
callq 0x1cb380
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x60(%rbp), %rax
movl 0x4(%rax), %eax
shrl %eax
movl %eax, %eax
imulq $0x30, %rax, %rax
addq %rax, %rdi
movq -0x60(%rbp), %rax
movl (%rax), %eax
shrl %eax
movl %eax, %eax
movl %eax, %esi
movsd 0x1ae570(%rip), %xmm0   # 0x382000
movl $0x1, %edx
leaq -0x38(%rbp), %rcx
callq 0x1cb380
jmp 0x1d3b24
movl -0x4c(%rbp), %eax
shrl %eax
movl %eax, -0x4c(%rbp)
movl -0x50(%rbp), %eax
shrl %eax
movl %eax, -0x50(%rbp)
movq $0x0, -0x30(%rbp)
movq -0x30(%rbp), %rax
movl -0x54(%rbp), %ecx
cmpq %rcx, %rax
jae 0x1d3b22
movq -0x60(%rbp), %rax
movq -0x30(%rbp), %rcx
movl (%rax,%rcx,4), %eax
shrl %eax
movl %eax, -0x58(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
movl -0x58(%rbp), %ecx
movl -0x4c(%rbp), %r8d
movl -0x50(%rbp), %r9d
leaq -0x80(%rbp), %rsi
leaq -0xa0(%rbp), %rdx
callq 0x1c54a0
movq -0x60(%rbp), %rdi
movl -0x54(%rbp), %esi
movl -0x58(%rbp), %ecx
movq -0x8(%rbp), %r8
leaq -0xa0(%rbp), %rdx
callq 0x1d3500
movq -0x30(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
jmp 0x1d3abb
jmp 0x1d3b24
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
jmp 0x1d39e4
movq $0x0, -0xb0(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movl 0x14(%rax), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
shll %eax
movslq %eax, %rdi
shlq $0x0, %rdi
callq 0x2270
movq %rax, -0xb0(%rbp)
movq -0x18(%rbp), %rax
movq 0x80(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x80(%rcx), %rcx
movq -0x18(%rbp), %rdx
addq 0x88(%rdx), %rcx
cmpq %rcx, %rax
jae 0x1d3c6c
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rsi
leaq -0x4c(%rbp), %rdx
leaq -0x50(%rbp), %rcx
leaq -0x60(%rbp), %r8
leaq -0x54(%rbp), %r9
xorl %eax, %eax
movq $0x0, (%rsp)
callq 0x1c4b20
movq $0x0, -0x30(%rbp)
movq -0x30(%rbp), %rax
movl -0x54(%rbp), %ecx
cmpq %rcx, %rax
jae 0x1d3c59
movq -0x60(%rbp), %rax
movq -0x30(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x58(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0xb0(%rbp), %rcx
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movl 0x14(%rax), %r8d
andl $0x7fffffff, %r8d       # imm = 0x7FFFFFFF
shll %r8d
movl -0x58(%rbp), %r9d
movl -0x4c(%rbp), %r10d
movl -0x50(%rbp), %eax
leaq -0x80(%rbp), %rsi
leaq -0xa0(%rbp), %rdx
movl %r10d, (%rsp)
movl %eax, 0x8(%rsp)
callq 0x1c4c20
movq -0x60(%rbp), %rdi
movl -0x54(%rbp), %esi
movl -0x58(%rbp), %ecx
shrl %ecx
movq -0x8(%rbp), %r8
leaq -0xa0(%rbp), %rdx
callq 0x1d3500
movq -0x30(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
jmp 0x1d3bc6
jmp 0x1d3c5b
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
jmp 0x1d3b74
movq -0x70(%rbp), %rdi
callq 0x2210
movq -0x90(%rbp), %rdi
callq 0x2210
movq -0xb0(%rbp), %rdi
callq 0x2210
movq $0x0, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq -0x8(%rbp), %rcx
cmpq (%rcx), %rax
jae 0x1d3f7e
movq $0x0, -0x40(%rbp)
movq $0x0, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq -0x8(%rbp), %rcx
movq 0x10(%rcx), %rcx
imulq $0x30, -0x20(%rbp), %rdx
addq %rdx, %rcx
cmpq 0x18(%rcx), %rax
jae 0x1d3d5b
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
imulq $0x28, -0x30(%rbp), %rcx
addq %rcx, %rax
movb 0x18(%rax), %al
shrb $0x7, %al
cmpb $0x0, %al
je 0x1d3cfc
jmp 0x1d3d4a
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rsi
imulq $0x28, -0x30(%rbp), %rax
addq %rax, %rsi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rdi
imulq $0x28, -0x40(%rbp), %rax
addq %rax, %rdi
movl $0x28, %edx
callq 0x2180
movq -0x40(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x40(%rbp)
movq -0x30(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
jmp 0x1d3cb6
movq -0x40(%rbp), %rcx
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rdx
addq %rdx, %rax
movq %rcx, 0x18(%rax)
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rdi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rsi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
imulq $0x28, 0x18(%rax), %rax
addq %rax, %rsi
callq 0x1be980
movq $0x0, -0x40(%rbp)
movq $0x0, -0x30(%rbp)
movq $-0x1, -0x48(%rbp)
movq -0x30(%rbp), %rax
movq -0x8(%rbp), %rcx
movq 0x10(%rcx), %rcx
imulq $0x30, -0x20(%rbp), %rdx
addq %rdx, %rcx
cmpq 0x18(%rcx), %rax
jae 0x1d3f10
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
imulq $0x28, -0x30(%rbp), %rcx
addq %rcx, %rax
movb 0x18(%rax), %al
shrb $0x7, %al
cmpb $0x0, %al
je 0x1d3e19
jmp 0x1d3eff
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
imulq $0x28, -0x30(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
cmpq -0x48(%rbp), %rax
jne 0x1d3e8e
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
imulq $0x28, -0x30(%rbp), %rcx
addq %rcx, %rax
cmpq $0x0, 0x10(%rax)
jne 0x1d3e8c
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
movq -0x40(%rbp), %rcx
subq $0x1, %rcx
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
movq $0x0, 0x10(%rax)
jmp 0x1d3eff
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
imulq $0x28, -0x30(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
movq %rax, -0x48(%rbp)
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rsi
imulq $0x28, -0x30(%rbp), %rax
addq %rax, %rsi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rdi
imulq $0x28, -0x40(%rbp), %rax
addq %rax, %rdi
movl $0x28, %edx
callq 0x2180
movq -0x40(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x40(%rbp)
movq -0x30(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
jmp 0x1d3dd0
movq -0x40(%rbp), %rcx
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rdx
addq %rdx, %rax
movq %rcx, 0x18(%rax)
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rdi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
movq 0x28(%rax), %rsi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
imulq $0x30, -0x20(%rbp), %rcx
addq %rcx, %rax
imulq $0x28, 0x18(%rax), %rax
addq %rax, %rsi
callq 0x1bee60
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
jmp 0x1d3c95
addq $0xc0, %rsp
popq %rbp
retq
nopw (%rax,%rax)