// File: chhylp123[P]hifiasm/horder.cpp
// Function: debug_debug_phasing_t(debug_phasing_t*, ma_ug_t*, kvec_pe_hit*, kv_u_trans_t*, h_covs*, unsigned long*)
void debug_debug_phasing_t(debug_phasing_t *x, ma_ug_t *cug, kvec_pe_hit *chits, kv_u_trans_t *ck_trans, 
h_covs *join, uint64_t *idx)
{
    uint64_t i, k, m, pv, cv, pui, pri, cui, cri, e;
    uint32_t p_cvx, c_cvx, pr, cr, occ;
    long long p_nodeLen, p_baseLen, t1, t2;
    long long c_nodeLen, c_baseLen;
    asg_arc_t *ap, *ac;
    u_trans_t *pk, *ck, *p;
    buf_t pb, cb;
    memset(&pb, 0, sizeof(buf_t));
    memset(&cb, 0, sizeof(buf_t));

    uint32_t *cnt = NULL; CALLOC(cnt, cug->g->n_seq<<1);
    for (cv = 0; cv < (uint64_t)(cug->g->n_seq<<1); ++cv) {
        ///out-nodes of v
        ac = asg_arc_a(cug->g, cv);
        ///if v just have one out-node, there is no muti-edge
        if (asg_arc_n(cug->g, cv) < 2) continue;
        for (i = 0; i < asg_arc_n(cug->g, cv); ++i) ++cnt[ac[i].v];
        for (i = 0; i < asg_arc_n(cug->g, cv); ++i)
            if (--cnt[ac[i].v] != 0) fprintf(stderr, "ERROR-9\n");
    }
    free(cnt);

    for (e = 0; e < cug->g->n_arc; ++e) {
        uint32_t v = cug->g->arc[e].v^1, u = cug->g->arc[e].ul>>32^1;
        asg_arc_t *av = asg_arc_a(cug->g, v);
        for (i = 0; i < asg_arc_n(cug->g, v); ++i)
            if (av[i].v == u) break;
        if (i == asg_arc_n(cug->g, v)) fprintf(stderr, "ERROR-10\n");
    }


    for (i = 0; i < x->ug->g->n_seq; i++)
    {
        pv = (i<<1);
        cv = new_node(pv, join, idx, 1);
        if(asg_arc_n(x->ug->g, pv) != asg_arc_n(cug->g, cv)) fprintf(stderr, "ERROR-1\n");
        ap = asg_arc_a(x->ug->g, pv); ac = asg_arc_a(cug->g, cv);
        for (k = 0; k < asg_arc_n(x->ug->g, pv); k++)
        {
            for (m = 0; m < asg_arc_n(cug->g, cv); m++)
            {
                if(new_node(ap[k].v, join, idx, 0) == ac[m].v) break;
            }
            if(m >= asg_arc_n(cug->g, cv))
            {
                fprintf(stderr, "\n+ERROR-2\n");
                fprintf(stderr, "+putg%.6lul (%lu), cutg%.6lul (%lu)\n", (pv>>1) + 1, pv&1, (cv>>1) + 1, cv&1);
                fprintf(stderr, "+p-occ: %u, c-occ: %u\n", asg_arc_n(x->ug->g, pv), asg_arc_n(cug->g, cv));
                fprintf(stderr, "+ap[k]-utg%.6ul (%u), new-utg%.6lul (%lu)\n", (ap[k].v>>1)+1, ap[k].v&1, 
                                (new_node(ap[k].v, join, idx, 0)>>1)+1, new_node(ap[k].v, join, idx, 0)&1);
                for (m = 0; m < asg_arc_n(cug->g, cv); m++)
                {
                    fprintf(stderr, "+ac[%lu]-utg%.6ul (%u)\n", m, (ac[m].v>>1) + 1, ac[m].v&1);
                }
            }
        }
        


        pv = (i<<1) + 1;
        cv = new_node(pv, join, idx, 1);
        if(asg_arc_n(x->ug->g, pv) != asg_arc_n(cug->g, cv)) fprintf(stderr, "ERROR-1\n");
        ap = asg_arc_a(x->ug->g, pv); ac = asg_arc_a(cug->g, cv);
        for (k = 0; k < asg_arc_n(x->ug->g, pv); k++)
        {
            for (m = 0; m < asg_arc_n(cug->g, cv); m++)
            {
                if(new_node(ap[k].v, join, idx, 0) == ac[m].v) break;
            }
            if(m >= asg_arc_n(cug->g, cv))
            {
                fprintf(stderr, "\n-ERROR-2\n");
                fprintf(stderr, "-putg%.6lul (%lu), cutg%.6lul (%lu)\n", (pv>>1) + 1, pv&1, (cv>>1) + 1, cv&1);
                fprintf(stderr, "-p-occ: %u, c-occ: %u\n", asg_arc_n(x->ug->g, pv), asg_arc_n(cug->g, cv));
                fprintf(stderr, "-ap[k]-utg%.6ul (%u), new-utg%.6lul (%lu)\n", (ap[k].v>>1)+1, ap[k].v&1, 
                                (new_node(ap[k].v, join, idx, 0)>>1)+1, new_node(ap[k].v, join, idx, 0)&1);
                for (m = 0; m < asg_arc_n(cug->g, cv); m++)
                {
                    fprintf(stderr, "-ac[%lu]-utg%.6ul (%u)\n", m, (ac[m].v>>1) + 1, ac[m].v&1);
                }
            }
        }

        pb.b.n = cb.b.n = 0;
        if(get_unitig(x->ug->g, NULL, i<<1, &p_cvx, &p_nodeLen, &p_baseLen, &t1, &t2, 1, &pb) !=
           get_unitig(cug->g, NULL, new_node((i<<1)+1, join, idx, 1)^1, &c_cvx, &c_nodeLen, &c_baseLen, &t1, &t2, 1, &cb))
        {
            fprintf(stderr, "ERROR-3\n");
        }
        if(new_node(p_cvx, join, idx, 1) != c_cvx) fprintf(stderr, "ERROR-4\n");
        if(p_baseLen != c_baseLen)
        {
            fprintf(stderr, "ERROR-6\n");
            fprintf(stderr, "-putg%.6lul, pb.b.n: %u, p_nodeLen: %lld, p_baseLen: %lld, cb.b.n: %u, c_nodeLen: %lld, c_baseLen: %lld\n", 
            i+1, (uint32_t)pb.b.n, p_nodeLen, p_baseLen, (uint32_t)cb.b.n, c_nodeLen, c_baseLen);
        } 
        
        

        pui = pri = cui = cri = 0;
        while(1)
        {
            pr = iter_rid(&pb, &pui, &pri, x->ug);
            cr = iter_rid(&cb, &cui, &cri, cug);
            if(pr != cr) fprintf(stderr, "ERROR-7\n");
            if(pr == (uint32_t)-1 || cr == (uint32_t)-1) break;
        }
    }

    for (i = 0; i < x->k_trans.n; i++)
    {
        pk = &(x->k_trans.a[i]);
        if(((uint32_t)idx[pk->qn]) <= 1 && ((uint32_t)idx[pk->tn]) <= 1)
        {
            get_u_trans_spec(ck_trans, ((uint32_t)join->a[idx[pk->qn]>>32].dp), 
            ((uint32_t)join->a[idx[pk->tn]>>32].dp), &ck, &occ);
            if(occ != 1 || !ck) fprintf(stderr, "ERROR-8\n");

            if(pk->qs != ck->qs || pk->qe != ck->qe || pk->ts != ck->ts || pk->te != ck->te ||
               pk->f != ck->f || pk->rev != ck->rev || pk->del != ck->del)
            {
                fprintf(stderr, "ERROR-9\n");
            }
        }
        else
        {
            p = pk;
            fprintf(stderr, "\n+q-utg%.6ul\tqs(%u)\tqe(%u)\tt-utg%.6ul\tts(%u)\tte(%u)\trev(%u)\tw(%f)\tf(%u)\n", 
            p->qn+1, p->qs, p->qe, p->tn+1, p->ts, p->te, p->rev, p->nw, p->f);

            uint64_t qi, ti, qid = p->qn, tid = p->tn;
            for (qi = 0; qi < (uint32_t)idx[qid]; qi++)
            {                
                for (ti = 0; ti < (uint32_t)idx[tid]; ti++)
                {
                    get_u_trans_spec(ck_trans, (uint32_t)(join->a[(idx[qid]>>32)+qi].dp),
                    (uint32_t)(join->a[(idx[tid]>>32)+ti].dp), &ck, &occ);
                    // fprintf(stderr, "s-utg%.6ul\td-utg%.6ul\tocc:%u\n", 
                    // (uint32_t)(join->a[(idx[qid]>>32)+qi].dp)+1,
                    // (uint32_t)(join->a[(idx[tid]>>32)+ti].dp)+1,
                    // occ);
                    for (k = 0; k < occ; k++)
                    {
                        p = &(ck[k]);
                        fprintf(stderr, "-q-utg%.6ul\tqs(%u)\tqe(%u)\tt-utg%.6ul\tts(%u)\tte(%u)\trev(%u)\tw(%f)\tf(%u)\n", 
                        p->qn+1, p->qs, p->qe, p->tn+1, p->ts, p->te, p->rev, p->nw, p->f);
                    }
                }
                
            }
            
            
            // get_u_trans_spec(ck_trans, ((uint32_t)join->a[idx[pk->qn]>>32].dp), 
            // ((uint32_t)join->a[idx[pk->tn]>>32].dp), &ck, &occ);
            // for (k = 0; k < occ; k++)
            // {
            //     p = &(ck[k]);
            //     fprintf(stderr, "-q-utg%.6ul\tqs(%u)\tqe(%u)\tt-utg%.6ul\tts(%u)\tte(%u)\trev(%u)\tw(%f)\tf(%u)\n", 
            //     p->qn+1, p->qs, p->qe, p->tn+1, p->ts, p->te, p->rev, p->nw, p->f);
            // }
        }
    }

    free(pb.b.a); free(cb.b.a);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x258, %rsp            # imm = 0x258
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x30(%rbp)
movq %r9, -0x38(%rbp)
leaq -0x160(%rbp), %rdi
xorl %esi, %esi
movl $0x68, %edx
callq 0x2100
leaq -0x1c8(%rbp), %rdi
xorl %esi, %esi
movl $0x68, %edx
callq 0x2100
movq $0x0, -0x1d0(%rbp)
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movl 0x14(%rax), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
shll %eax
movslq %eax, %rdi
movl $0x4, %esi
callq 0x2140
movq %rax, -0x1d0(%rbp)
movq $0x0, -0x60(%rbp)
movq -0x60(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movl 0x14(%rcx), %ecx
andl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
shll %ecx
movslq %ecx, %rcx
cmpq %rcx, %rax
jae 0x231c78
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x8(%rax), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
shrq $0x20, %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0xe0(%rbp)
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x28(%rax), %rax
movq -0x60(%rbp), %rcx
movq (%rax,%rcx,8), %rax
cmpl $0x2, %eax
jae 0x231b96
jmp 0x231c67
movq $0x0, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x231bed
movq -0x1d0(%rbp), %rax
movq -0xe0(%rbp), %rcx
imulq $0x18, -0x40(%rbp), %rdx
addq %rdx, %rcx
movl 0x8(%rcx), %ecx
movl (%rax,%rcx,4), %edx
addl $0x1, %edx
movl %edx, (%rax,%rcx,4)
movq -0x40(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x40(%rbp)
jmp 0x231b9e
movq $0x0, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x231c65
movq -0x1d0(%rbp), %rcx
movq -0xe0(%rbp), %rax
imulq $0x18, -0x40(%rbp), %rdx
addq %rdx, %rax
movl 0x8(%rax), %eax
movl %eax, %edx
movl (%rcx,%rdx,4), %eax
addl $-0x1, %eax
movl %eax, (%rcx,%rdx,4)
cmpl $0x0, %eax
je 0x231c55
movq 0x19239c(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x15605b(%rip), %rsi    # 0x387ca9
movb $0x0, %al
callq 0x22a0
jmp 0x231c57
movq -0x40(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x40(%rbp)
jmp 0x231bf5
jmp 0x231c67
movq -0x60(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x60(%rbp)
jmp 0x231b23
movq -0x1d0(%rbp), %rdi
callq 0x2210
movq $0x0, -0x88(%rbp)
movq -0x88(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movl 0x4(%rcx), %ecx
andl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x231dd8
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x8(%rax), %rax
imulq $0x18, -0x88(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
xorl $0x1, %eax
movl %eax, -0x1d4(%rbp)
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x8(%rax), %rax
imulq $0x18, -0x88(%rbp), %rcx
addq %rcx, %rax
movq (%rax), %rax
shrq $0x20, %rax
xorq $0x1, %rax
movl %eax, -0x1d8(%rbp)
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x8(%rax), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movl -0x1d4(%rbp), %edx
movq (%rcx,%rdx,8), %rcx
shrq $0x20, %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x1e0(%rbp)
movq $0x0, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movl -0x1d4(%rbp), %edx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x231d86
movq -0x1e0(%rbp), %rax
imulq $0x18, -0x40(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
cmpl -0x1d8(%rbp), %eax
jne 0x231d76
jmp 0x231d86
jmp 0x231d78
movq -0x40(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x40(%rbp)
jmp 0x231d39
movq -0x40(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movl -0x1d4(%rbp), %edx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jne 0x231dbf
movq 0x192232(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x15c3b8(%rip), %rsi    # 0x38e170
movb $0x0, %al
callq 0x22a0
jmp 0x231dc1
movq -0x88(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x88(%rbp)
jmp 0x231c8f
movq $0x0, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq -0x10(%rbp), %rcx
movq (%rcx), %rcx
movq 0x18(%rcx), %rcx
movl 0x14(%rcx), %ecx
andl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x2327d0
movq -0x40(%rbp), %rax
shlq %rax
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rdi
movq -0x30(%rbp), %rsi
movq -0x38(%rbp), %rdx
movl $0x1, %ecx
callq 0x2318e0
movq %rax, -0x60(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x18(%rax), %rax
movq 0x28(%rax), %rax
movq -0x58(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
cmpl %ecx, %eax
je 0x231e6f
movq 0x192182(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x156bea(%rip), %rsi    # 0x388a52
movb $0x0, %al
callq 0x22a0
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x18(%rax), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rcx
movq (%rcx), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x58(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
shrq $0x20, %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0xd8(%rbp)
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x8(%rax), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
shrq $0x20, %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0xe0(%rbp)
movq $0x0, -0x48(%rbp)
movq -0x48(%rbp), %rax
movq -0x10(%rbp), %rcx
movq (%rcx), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x58(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x2321a0
movq $0x0, -0x50(%rbp)
movq -0x50(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x231f7c
movq -0xd8(%rbp), %rax
imulq $0x18, -0x48(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
movl %eax, %edi
movq -0x30(%rbp), %rsi
movq -0x38(%rbp), %rdx
xorl %eax, %eax
movl %eax, %ecx
callq 0x2318e0
movq -0xe0(%rbp), %rcx
imulq $0x18, -0x50(%rbp), %rdx
addq %rdx, %rcx
movl 0x8(%rcx), %ecx
cmpq %rcx, %rax
jne 0x231f6c
jmp 0x231f7c
jmp 0x231f6e
movq -0x50(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x50(%rbp)
jmp 0x231f0f
movq -0x50(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jb 0x23218d
movq 0x19203a(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x15c1ca(%rip), %rsi    # 0x38e17a
movb $0x0, %al
callq 0x22a0
movq 0x192022(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0x58(%rbp), %rdx
shrq %rdx
addq $0x1, %rdx
movq -0x58(%rbp), %rcx
andq $0x1, %rcx
movq -0x60(%rbp), %r8
shrq %r8
addq $0x1, %r8
movq -0x60(%rbp), %r9
andq $0x1, %r9
leaq 0x15c197(%rip), %rsi    # 0x38e185
movb $0x0, %al
callq 0x22a0
movq 0x191fe4(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x18(%rax), %rax
movq 0x28(%rax), %rax
movq -0x58(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movl %eax, %edx
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x28(%rax), %rax
movq -0x60(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movl %eax, %ecx
leaq 0x15c175(%rip), %rsi    # 0x38e1aa
movb $0x0, %al
callq 0x22a0
movq 0x191f9d(%rip), %rax    # 0x3c3fe0
movq (%rax), %rax
movq %rax, -0x218(%rbp)
movq -0xd8(%rbp), %rax
imulq $0x18, -0x48(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
shrl %eax
addl $0x1, %eax
movl %eax, -0x210(%rbp)
movq -0xd8(%rbp), %rax
imulq $0x18, -0x48(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
andl $0x1, %eax
movl %eax, -0x20c(%rbp)
movq -0xd8(%rbp), %rax
imulq $0x18, -0x48(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
movl %eax, %edi
movq -0x30(%rbp), %rsi
movq -0x38(%rbp), %rdx
xorl %eax, %eax
movl %eax, %ecx
callq 0x2318e0
shrq %rax
addq $0x1, %rax
movq %rax, -0x208(%rbp)
movq -0xd8(%rbp), %rax
imulq $0x18, -0x48(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
movl %eax, %edi
movq -0x30(%rbp), %rsi
movq -0x38(%rbp), %rdx
xorl %eax, %eax
movl %eax, %ecx
callq 0x2318e0
movq -0x218(%rbp), %rdi
movl -0x210(%rbp), %edx
movl -0x20c(%rbp), %ecx
movq -0x208(%rbp), %r8
movq %rax, %r9
andq $0x1, %r9
leaq 0x15c0bc(%rip), %rsi    # 0x38e1c1
movb $0x0, %al
callq 0x22a0
movq $0x0, -0x50(%rbp)
movq -0x50(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x23218b
movq 0x191ea6(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0x50(%rbp), %rdx
movq -0xe0(%rbp), %rax
imulq $0x18, -0x50(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %ecx
shrl %ecx
addl $0x1, %ecx
movq -0xe0(%rbp), %rax
imulq $0x18, -0x50(%rbp), %rsi
addq %rsi, %rax
movl 0x8(%rax), %r8d
andl $0x1, %r8d
leaq 0x15c076(%rip), %rsi    # 0x38e1ec
movb $0x0, %al
callq 0x22a0
movq -0x50(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x50(%rbp)
jmp 0x232114
jmp 0x23218d
jmp 0x23218f
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
jmp 0x231ee1
movq -0x40(%rbp), %rax
shlq %rax
addq $0x1, %rax
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rdi
movq -0x30(%rbp), %rsi
movq -0x38(%rbp), %rdx
movl $0x1, %ecx
callq 0x2318e0
movq %rax, -0x60(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x18(%rax), %rax
movq 0x28(%rax), %rax
movq -0x58(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
cmpl %ecx, %eax
je 0x232210
movq 0x191de1(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x156849(%rip), %rsi    # 0x388a52
movb $0x0, %al
callq 0x22a0
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x18(%rax), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rcx
movq (%rcx), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x58(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
shrq $0x20, %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0xd8(%rbp)
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x8(%rax), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
shrq $0x20, %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0xe0(%rbp)
movq $0x0, -0x48(%rbp)
movq -0x48(%rbp), %rax
movq -0x10(%rbp), %rcx
movq (%rcx), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x58(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x232541
movq $0x0, -0x50(%rbp)
movq -0x50(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x23231d
movq -0xd8(%rbp), %rax
imulq $0x18, -0x48(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
movl %eax, %edi
movq -0x30(%rbp), %rsi
movq -0x38(%rbp), %rdx
xorl %eax, %eax
movl %eax, %ecx
callq 0x2318e0
movq -0xe0(%rbp), %rcx
imulq $0x18, -0x50(%rbp), %rdx
addq %rdx, %rcx
movl 0x8(%rcx), %ecx
cmpq %rcx, %rax
jne 0x23230d
jmp 0x23231d
jmp 0x23230f
movq -0x50(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x50(%rbp)
jmp 0x2322b0
movq -0x50(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jb 0x23252e
movq 0x191c99(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x15beb3(%rip), %rsi    # 0x38e204
movb $0x0, %al
callq 0x22a0
movq 0x191c81(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0x58(%rbp), %rdx
shrq %rdx
addq $0x1, %rdx
movq -0x58(%rbp), %rcx
andq $0x1, %rcx
movq -0x60(%rbp), %r8
shrq %r8
addq $0x1, %r8
movq -0x60(%rbp), %r9
andq $0x1, %r9
leaq 0x15be80(%rip), %rsi    # 0x38e20f
movb $0x0, %al
callq 0x22a0
movq 0x191c43(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x18(%rax), %rax
movq 0x28(%rax), %rax
movq -0x58(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movl %eax, %edx
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x28(%rax), %rax
movq -0x60(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movl %eax, %ecx
leaq 0x15be5e(%rip), %rsi    # 0x38e234
movb $0x0, %al
callq 0x22a0
movq 0x191bfc(%rip), %rax    # 0x3c3fe0
movq (%rax), %rax
movq %rax, -0x230(%rbp)
movq -0xd8(%rbp), %rax
imulq $0x18, -0x48(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
shrl %eax
addl $0x1, %eax
movl %eax, -0x228(%rbp)
movq -0xd8(%rbp), %rax
imulq $0x18, -0x48(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
andl $0x1, %eax
movl %eax, -0x224(%rbp)
movq -0xd8(%rbp), %rax
imulq $0x18, -0x48(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
movl %eax, %edi
movq -0x30(%rbp), %rsi
movq -0x38(%rbp), %rdx
xorl %eax, %eax
movl %eax, %ecx
callq 0x2318e0
shrq %rax
addq $0x1, %rax
movq %rax, -0x220(%rbp)
movq -0xd8(%rbp), %rax
imulq $0x18, -0x48(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
movl %eax, %edi
movq -0x30(%rbp), %rsi
movq -0x38(%rbp), %rdx
xorl %eax, %eax
movl %eax, %ecx
callq 0x2318e0
movq -0x230(%rbp), %rdi
movl -0x228(%rbp), %edx
movl -0x224(%rbp), %ecx
movq -0x220(%rbp), %r8
movq %rax, %r9
andq $0x1, %r9
leaq 0x15bda5(%rip), %rsi    # 0x38e24b
movb $0x0, %al
callq 0x22a0
movq $0x0, -0x50(%rbp)
movq -0x50(%rbp), %rax
movq -0x18(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x28(%rcx), %rcx
movq -0x60(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x23252c
movq 0x191b05(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0x50(%rbp), %rdx
movq -0xe0(%rbp), %rax
imulq $0x18, -0x50(%rbp), %rcx
addq %rcx, %rax
movl 0x8(%rax), %ecx
shrl %ecx
addl $0x1, %ecx
movq -0xe0(%rbp), %rax
imulq $0x18, -0x50(%rbp), %rsi
addq %rsi, %rax
movl 0x8(%rax), %r8d
andl $0x1, %r8d
leaq 0x15bd5f(%rip), %rsi    # 0x38e276
movb $0x0, %al
callq 0x22a0
movq -0x50(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x50(%rbp)
jmp 0x2324b5
jmp 0x23252e
jmp 0x232530
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
jmp 0x232282
movq $0x0, -0x190(%rbp)
movq $0x0, -0x128(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x18(%rax), %rdi
movq -0x40(%rbp), %rax
shlq %rax
movl %eax, %edx
xorl %eax, %eax
movl %eax, %esi
leaq -0x8c(%rbp), %rcx
leaq -0xa8(%rbp), %r8
leaq -0xb0(%rbp), %r9
leaq -0xb8(%rbp), %r11
leaq -0xc0(%rbp), %r10
leaq -0x160(%rbp), %rax
movq %r11, (%rsp)
movq %r10, 0x8(%rsp)
movl $0x1, 0x10(%rsp)
movq %rax, 0x18(%rsp)
callq 0x166c30
movl %eax, -0x234(%rbp)
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x240(%rbp)
movq -0x40(%rbp), %rdi
shlq %rdi
addq $0x1, %rdi
movq -0x30(%rbp), %rsi
movq -0x38(%rbp), %rdx
movl $0x1, %ecx
callq 0x2318e0
movq -0x240(%rbp), %rdi
xorq $0x1, %rax
movl %eax, %edx
xorl %eax, %eax
movl %eax, %esi
leaq -0x90(%rbp), %rcx
leaq -0xc8(%rbp), %r8
leaq -0xd0(%rbp), %r9
leaq -0xb8(%rbp), %r11
leaq -0xc0(%rbp), %r10
leaq -0x1c8(%rbp), %rax
movq %r11, (%rsp)
movq %r10, 0x8(%rsp)
movl $0x1, 0x10(%rsp)
movq %rax, 0x18(%rsp)
callq 0x166c30
movl %eax, %ecx
movl -0x234(%rbp), %eax
cmpl %ecx, %eax
je 0x232660
movq 0x191991(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x155605(%rip), %rsi    # 0x387c5e
movb $0x0, %al
callq 0x22a0
movl -0x8c(%rbp), %eax
movl %eax, %edi
movq -0x30(%rbp), %rsi
movq -0x38(%rbp), %rdx
movl $0x1, %ecx
callq 0x2318e0
movl -0x90(%rbp), %ecx
cmpq %rcx, %rax
je 0x23269d
movq 0x191954(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x15bbf8(%rip), %rsi    # 0x38e28e
movb $0x0, %al
callq 0x22a0
movq -0xb0(%rbp), %rax
cmpq -0xd0(%rbp), %rax
je 0x232722
movq 0x19192c(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x1555d0(%rip), %rsi    # 0x387c8e
movb $0x0, %al
callq 0x22a0
movq 0x191914(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0x40(%rbp), %rdx
addq $0x1, %rdx
movq -0x128(%rbp), %rax
movl %eax, %ecx
movq -0xa8(%rbp), %r8
movq -0xb0(%rbp), %r9
movq -0x190(%rbp), %rax
movl %eax, %r11d
movq -0xc8(%rbp), %r10
movq -0xd0(%rbp), %rax
leaq 0x15bb8a(%rip), %rsi    # 0x38e297
movl %r11d, (%rsp)
movq %r10, 0x8(%rsp)
movq %rax, 0x10(%rsp)
movb $0x0, %al
callq 0x22a0
movq $0x0, -0x80(%rbp)
movq $0x0, -0x78(%rbp)
movq $0x0, -0x70(%rbp)
movq $0x0, -0x68(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rcx
leaq -0x160(%rbp), %rdi
leaq -0x68(%rbp), %rsi
leaq -0x70(%rbp), %rdx
callq 0x2319e0
movl %eax, -0x94(%rbp)
movq -0x18(%rbp), %rcx
leaq -0x1c8(%rbp), %rdi
leaq -0x78(%rbp), %rsi
leaq -0x80(%rbp), %rdx
callq 0x2319e0
movl %eax, -0x98(%rbp)
movl -0x94(%rbp), %eax
cmpl -0x98(%rbp), %eax
je 0x2327a7
movq 0x19184a(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x1554f7(%rip), %rsi    # 0x387c97
movb $0x0, %al
callq 0x22a0
cmpl $-0x1, -0x94(%rbp)
je 0x2327b9
cmpl $-0x1, -0x98(%rbp)
jne 0x2327bb
jmp 0x2327bd
jmp 0x232742
jmp 0x2327bf
movq -0x40(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x40(%rbp)
jmp 0x231de0
movq $0x0, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq -0x10(%rbp), %rcx
cmpq 0x60(%rcx), %rax
jae 0x232c78
movq -0x10(%rbp), %rax
movq 0x70(%rax), %rax
imulq $0x30, -0x40(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0xe8(%rbp)
movq -0x38(%rbp), %rax
movq -0xe8(%rbp), %rcx
movl 0x8(%rcx), %ecx
movq (%rax,%rcx,8), %rax
cmpl $0x1, %eax
ja 0x2329bc
movq -0x38(%rbp), %rax
movq -0xe8(%rbp), %rcx
movl 0x14(%rcx), %ecx
movq (%rax,%rcx,8), %rax
cmpl $0x1, %eax
ja 0x2329bc
movq -0x28(%rbp), %rdi
movq -0x30(%rbp), %rax
movq (%rax), %rax
movq -0x38(%rbp), %rcx
movq -0xe8(%rbp), %rdx
movl 0x8(%rdx), %edx
movq (%rcx,%rdx,8), %rcx
shrq $0x20, %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rax
movl %eax, %esi
movq -0x30(%rbp), %rax
movq (%rax), %rax
movq -0x38(%rbp), %rcx
movq -0xe8(%rbp), %rdx
movl 0x14(%rdx), %edx
movq (%rcx,%rdx,8), %rcx
shrq $0x20, %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rax
movl %eax, %edx
leaq -0xf0(%rbp), %rcx
leaq -0x9c(%rbp), %r8
callq 0x110ee0
cmpl $0x1, -0x9c(%rbp)
jne 0x2328b5
cmpq $0x0, -0xf0(%rbp)
jne 0x2328cd
movq 0x191724(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x1553da(%rip), %rsi    # 0x387ca0
movb $0x0, %al
callq 0x22a0
movq -0xe8(%rbp), %rax
movl (%rax), %eax
movq -0xf0(%rbp), %rcx
cmpl (%rcx), %eax
jne 0x23299f
movq -0xe8(%rbp), %rax
movl 0x4(%rax), %eax
movq -0xf0(%rbp), %rcx
cmpl 0x4(%rcx), %eax
jne 0x23299f
movq -0xe8(%rbp), %rax
movl 0xc(%rax), %eax
movq -0xf0(%rbp), %rcx
cmpl 0xc(%rcx), %eax
jne 0x23299f
movq -0xe8(%rbp), %rax
movl 0x10(%rax), %eax
movq -0xf0(%rbp), %rcx
cmpl 0x10(%rcx), %eax
jne 0x23299f
movq -0xe8(%rbp), %rax
movb 0x28(%rax), %al
andb $0x3f, %al
movzbl %al, %eax
movq -0xf0(%rbp), %rcx
movb 0x28(%rcx), %cl
andb $0x3f, %cl
movzbl %cl, %ecx
cmpl %ecx, %eax
jne 0x23299f
movq -0xe8(%rbp), %rax
movb 0x28(%rax), %al
shrb $0x6, %al
andb $0x1, %al
movzbl %al, %eax
movq -0xf0(%rbp), %rcx
movb 0x28(%rcx), %cl
shrb $0x6, %cl
andb $0x1, %cl
movzbl %cl, %ecx
cmpl %ecx, %eax
jne 0x23299f
movq -0xe8(%rbp), %rax
movb 0x28(%rax), %al
shrb $0x7, %al
movzbl %al, %eax
movq -0xf0(%rbp), %rcx
movb 0x28(%rcx), %cl
shrb $0x7, %cl
movzbl %cl, %ecx
cmpl %ecx, %eax
je 0x2329b7
movq 0x19163a(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x1552f9(%rip), %rsi    # 0x387ca9
movb $0x0, %al
callq 0x22a0
jmp 0x232c65
movq -0xe8(%rbp), %rax
movq %rax, -0xf8(%rbp)
movq 0x19160f(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0xf8(%rbp), %rax
movl 0x8(%rax), %edx
addl $0x1, %edx
movq -0xf8(%rbp), %rax
movl (%rax), %ecx
movq -0xf8(%rbp), %rax
movl 0x4(%rax), %r8d
movq -0xf8(%rbp), %rax
movl 0x14(%rax), %r9d
addl $0x1, %r9d
movq -0xf8(%rbp), %rax
movl 0xc(%rax), %ebx
movq -0xf8(%rbp), %rax
movl 0x10(%rax), %r11d
movq -0xf8(%rbp), %rax
movb 0x28(%rax), %al
shrb $0x6, %al
andb $0x1, %al
movzbl %al, %r10d
movq -0xf8(%rbp), %rax
movsd 0x20(%rax), %xmm0
movq -0xf8(%rbp), %rax
movb 0x28(%rax), %al
andb $0x3f, %al
movzbl %al, %eax
leaq 0x15b8b2(%rip), %rsi    # 0x38e300
movl %ebx, (%rsp)
movl %r11d, 0x8(%rsp)
movl %r10d, 0x10(%rsp)
movl %eax, 0x18(%rsp)
movb $0x1, %al
callq 0x22a0
movq -0xf8(%rbp), %rax
movl 0x8(%rax), %eax
movq %rax, -0x1f8(%rbp)
movq -0xf8(%rbp), %rax
movl 0x14(%rax), %eax
movq %rax, -0x200(%rbp)
movq $0x0, -0x1e8(%rbp)
movq -0x1e8(%rbp), %rax
movq -0x38(%rbp), %rcx
movq -0x1f8(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x232c63
movq $0x0, -0x1f0(%rbp)
movq -0x1f0(%rbp), %rax
movq -0x38(%rbp), %rcx
movq -0x200(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
movl %ecx, %ecx
cmpq %rcx, %rax
jae 0x232c4a
movq -0x28(%rbp), %rdi
movq -0x30(%rbp), %rax
movq (%rax), %rax
movq -0x38(%rbp), %rcx
movq -0x1f8(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
shrq $0x20, %rcx
addq -0x1e8(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rax
movl %eax, %esi
movq -0x30(%rbp), %rax
movq (%rax), %rax
movq -0x38(%rbp), %rcx
movq -0x200(%rbp), %rdx
movq (%rcx,%rdx,8), %rcx
shrq $0x20, %rcx
addq -0x1f0(%rbp), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rax
movl %eax, %edx
leaq -0xf0(%rbp), %rcx
leaq -0x9c(%rbp), %r8
callq 0x110ee0
movq $0x0, -0x48(%rbp)
movq -0x48(%rbp), %rax
movl -0x9c(%rbp), %ecx
cmpq %rcx, %rax
jae 0x232c31
movq -0xf0(%rbp), %rax
imulq $0x30, -0x48(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0xf8(%rbp)
movq 0x191455(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movq -0xf8(%rbp), %rax
movl 0x8(%rax), %edx
addl $0x1, %edx
movq -0xf8(%rbp), %rax
movl (%rax), %ecx
movq -0xf8(%rbp), %rax
movl 0x4(%rax), %r8d
movq -0xf8(%rbp), %rax
movl 0x14(%rax), %r9d
addl $0x1, %r9d
movq -0xf8(%rbp), %rax
movl 0xc(%rax), %ebx
movq -0xf8(%rbp), %rax
movl 0x10(%rax), %r11d
movq -0xf8(%rbp), %rax
movb 0x28(%rax), %al
shrb $0x6, %al
andb $0x1, %al
movzbl %al, %r10d
movq -0xf8(%rbp), %rax
movsd 0x20(%rax), %xmm0
movq -0xf8(%rbp), %rax
movb 0x28(%rax), %al
andb $0x3f, %al
movzbl %al, %eax
leaq 0x15b741(%rip), %rsi    # 0x38e349
movl %ebx, (%rsp)
movl %r11d, 0x8(%rsp)
movl %r10d, 0x10(%rsp)
movl %eax, 0x18(%rsp)
movb $0x1, %al
callq 0x22a0
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
jmp 0x232b5b
jmp 0x232c33
movq -0x1f0(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x1f0(%rbp)
jmp 0x232abf
jmp 0x232c4c
movq -0x1e8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x1e8(%rbp)
jmp 0x232a93
jmp 0x232c65
jmp 0x232c67
movq -0x40(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x40(%rbp)
jmp 0x2327d8
movq -0x118(%rbp), %rdi
callq 0x2210
movq -0x180(%rbp), %rdi
callq 0x2210
addq $0x258, %rsp            # imm = 0x258
popq %rbx
popq %rbp
retq
nopw (%rax,%rax)