// File: /workspace/github_cpp_makefile_star2_O2/chhylp123[P]hifiasm/gfa_ut.cpp
// Function: integer_candidate(ul_resolve_t*, integer_t*, unsigned int, unsigned int)
void integer_candidate(ul_resolve_t *uidx, integer_t *buf, uint32_t qid, uint32_t is_hom)
{
    uint64_t k, z, m_het, m_het_occ, ref_occ, b_n, m; uint32_t vk, vz, is_circle = 0; integer_aln_t *p; ul_chain_t sc;
    ul_str_idx_t *str_idx = &(uidx->pstr); ma_ug_t *ug = uidx->l1_ug; 
    uint64_t *hid_a, hid_n; uc_block_t *xi;
    ul_str_t *str = &(str_idx->str.a[qid]);
    if(str->cn < 2) return; ///directly filter out too short UL
    kv_resize(uint64_t, buf->u, str->cn); buf->u.n = str->cn;
    for (k = m_het = m_het_occ = ref_occ = 0; k < str->cn; k++) {
        xi = &(uidx->idx->a[qid].bb.a[str->a[k]>>32]);
        assert(((xi->hid<<1)+xi->rev)==((uint32_t)str->a[k]));
        buf->u.a[k] = ug_occ_w(xi->ts, xi->te, &(ug->u.a[xi->hid]));
        assert(buf->u.a[k] > 0);
        if((!is_hom) && (!IF_HOM((((uint32_t)str->a[k])>>1), (*uidx->bub)))) {
            m_het++; m_het_occ += buf->u.a[k];///m_het_occ: how many het HiFi reads
        }
        ref_occ += buf->u.a[k];
        // fprintf(stderr, "[M::%s::k->%lu] buf->u.a[k]->%lu, ts->%u, te->%u, pchain->%u\n", __func__, k, buf->u.a[k], xi->ts, xi->te, xi->pchain);
    }
    // if((!is_hom) && (m_het < 2) && (m_het > 0)) return;///if all matched unitigs are hom, is ok
    if(m_het == 0 || m_het_occ == 0) is_hom = 1;
    // print_ul_alignment(ug, &UL_INF, 27512, "inner-0");
    for (k = 0, buf->b.n = 0; k < str->cn; k++) {
        vk = (uint32_t)str->a[k];
        hid_a = str_idx->occ.a + str_idx->idx.a[vk>>1];
        hid_n = str_idx->idx.a[(vk>>1)+1] - str_idx->idx.a[vk>>1];
        for (z = 0; z < hid_n; z++) {
            if((hid_a[z]>>32) == qid) continue;
            if(str_idx->str.a[hid_a[z]>>32].cn < 2) continue;
            vz = (uint32_t)(str_idx->str.a[hid_a[z]>>32].a[(uint32_t)hid_a[z]]);
            assert((vk>>1) == (vz>>1));
            kv_pushp(integer_aln_t, buf->b, &p);
            p->vq = vk; p->tk = (uint32_t)hid_a[z]; 
            if((vk^vz)&1) p->tk = str_idx->str.a[hid_a[z]>>32].cn - p->tk - 1;///rev
            p->tn_rev_qk = (hid_a[z]>>32); p->tn_rev_qk <<= 1; p->tn_rev_qk |= ((vk^vz)&1);
            p->tn_rev_qk <<= 32; p->tn_rev_qk += k; 
            ///set score of this pair
            p->sc = buf->u.a[k];
            xi = &(uidx->idx->a[hid_a[z]>>32].bb.a[(str_idx->str.a[hid_a[z]>>32].a[(uint32_t)hid_a[z]])>>32]);
            assert(((xi->hid<<1)+xi->rev)==vz); m = ug_occ_w(xi->ts, xi->te, &(ug->u.a[xi->hid]));
            if(p->sc > m) p->sc = m;
        }
    }
    // print_ul_alignment(ug, &UL_INF, 27512, "inner-1");
    radix_sort_integer_aln_t_srt(buf->b.a, buf->b.a + buf->b.n); 
    b_n = buf->b.n; buf->sc.n = 0;
    for (k = 1, z = 0; k <= b_n; k++) {
        if(k == b_n || (buf->b.a[z].tn_rev_qk>>32) != (buf->b.a[k].tn_rev_qk>>32)) {
            ///get the chain for <qn, tn>
            if(integer_chain(qid, buf->b.a + z, k - z, z, buf, ug, str_idx, uidx->idx, &sc) && sc.v != (uint32_t)-1) {
                if((buf->sc.n > 0) && ((buf->sc.a[buf->sc.n-1].v>>1) == (sc.v>>1))) {
                    if(buf->sc.a[buf->sc.n-1].sc < sc.sc) {
                        buf->sc.a[buf->sc.n-1] = sc;
                    }
                } else {
                    kv_push(ul_chain_t, buf->sc, sc);
                }
            }
            z = k;
        }
    }
    // print_ul_alignment(ug, &UL_INF, 27512, "inner-2");
    uint64_t *o, o_n, cns_het, cns_het_occ, ref_cns_occ, corrected = 0;
    o_n = integer_chain_dp(uidx->bub, buf, str_idx->str.a, buf->b.a, buf->sc.a, buf->sc.n, qid, is_hom, 2, &corrected);
    assert(o_n <= str->cn); 
    // if(qid == 2062 || qid == 2093) fprintf(stderr,"[M::%s::] o_n::%lu, str->cn::%u, corrected::%lu\n", __func__, o_n, str->cn, corrected);
    if(o_n <= 0) return; 
    if(corrected) return;
    // print_ul_alignment(ug, &UL_INF, 27512, "inner-3");
    
    for (k = cns_het = cns_het_occ = ref_cns_occ = 0, o = buf->o.a; k < o_n; k++) {
        if((!is_hom) && (!IF_HOM((((uint32_t)str->a[o[k]])>>1), (*uidx->bub)))) {
            cns_het++; cns_het_occ += buf->u.a[o[k]];
        }
        ref_cns_occ += buf->u.a[o[k]];     
    }
    buf->o.n = o_n;
    ///1. if the ref read only has hom unitigs, is fine
    ///2. otherwise need to have consenus het untigs
    if(!is_hom) {
        if((cns_het <= 0) || (cns_het_occ <= 0) || (cns_het_occ <= (m_het_occ*0.25))) return;
    } else {
        if(ref_cns_occ <= (ref_occ*0.25)) return;
    }
    // print_ul_alignment(ug, &UL_INF, 27512, "inner-4");
    // fprintf(stderr, "\n");
    // print_integer_seq(ug, str_idx->str.a, qid, 1);
    // print_aln_seq(ug, uidx->idx, qid, 1);
    // if(qid == 2062 || qid == 2093) print_cns_seq(ug, str, o, o_n);
    // print_ul_alignment(ug, &UL_INF, 27512, "inner-5");

    for (k = m = 0; k < buf->sc.n; k++) {
        // fprintf(stderr, "[M::%s::k->%lu] m::%lu\n", __func__, k, m);
        // if(k == 72) {
        //     print_integer_ovlps(ug, str_idx->str.a, buf->b.a, buf->b.n, buf->sc.a+k, 1, qid, o_n);
        // }
        if(refine_integer_ovlps(uidx->idx, uidx->bub, ug, str_idx->str.a, buf->b.a, 
                                                            &(buf->sc.a[k]), qid, buf, o, o_n)) {                                                
            buf->sc.a[m++] = buf->sc.a[k];
        } 
        // else {
        //     print_integer_ovlps(ug, str_idx->str.a, buf->b.a, buf->b.n, buf->sc.a+k, 1, qid, o_n);
        //     fprintf(stderr, "[M::%s::] idx->q_sidx::%u, idx->q_eidx::%u, idx->t_sidx::%u, idx->t_eidx::%u\n******************************************************\n", 
        //         __func__, buf->sc.a[k].q_sidx, buf->sc.a[k].q_eidx, buf->sc.a[k].t_sidx, buf->sc.a[k].t_eidx);
        // }
    }
    buf->sc.n = m;
    if(m <= 0) return;
    // print_ul_alignment(ug, &UL_INF, 27512, "inner-6");
    // if(m != str->cn) print_integer_ovlps(uidx->l1_ug, str_idx->str.a, buf->b.a, buf->b.n, buf->sc.a, buf->sc.n, qid, m);
    poa_cns_chain(&(buf->pg), uidx->idx, ug, str_idx->str.a, buf->sc.a, buf->sc.n, qid, buf, &is_circle);
    if(is_circle) {
        buf->n_circle++;
        return;
    }
    // print_ul_alignment(ug, &UL_INF, 27512, "inner-7");
    // print_res_seq(&(buf->pg), ug, buf->pg.srt_b.res.a, buf->pg.srt_b.res.n);
    // radix_sort_ul_chain_t_srt(buf->sc.a, buf->sc.a + buf->sc.n);
    
    // integer_phase(str_idx->str.a, buf, buf->sc.a, buf->sc.n, buf->b.a, qid);

    // radix_sort_ul_chain_t_srt(buf->sc.a, buf->sc.a + buf->sc.n);
    o = NULL; o_n = 0;
    update_raw_integer_seq(&(buf->pg), ug, buf->pg.srt_b.res.a, buf->pg.srt_b.res.n, uidx->idx, str_idx->str.a, qid, buf, buf->sc.a, buf->sc.n);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movl %ecx, %r13d
andl $0x0, 0x3c(%rsp)
movq 0x1d0(%rdi), %rbx
movl %edx, %ecx
movq %rcx, 0x10(%rsp)
shlq $0x5, %rcx
movl 0x18(%rbx,%rcx), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
cmpl $0x2, %eax
jae 0x1b9be5
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x18(%rdi), %rbp
addq %rcx, %rbx
cmpq %rax, 0x98(%rsi)
movq %rsi, (%rsp)
movq %rdi, 0x8(%rsp)
movq %rbx, 0x30(%rsp)
movq %rdx, 0x40(%rsp)
jae 0x1b9c73
decq %rax
movq %rax, %rcx
shrq %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x2, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x4, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x8, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x10, %rcx
orq %rax, %rcx
leaq 0x1(%rcx), %rax
movq %rax, 0x98(%rsi)
movq 0xa0(%rsi), %rdi
leaq 0x8(,%rcx,8), %rsi
callq 0x2370
movq 0x8(%rsp), %rdi
movq (%rsp), %rsi
movq %rax, 0xa0(%rsi)
movl 0x18(%rbx), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
leaq 0x190(%rdi), %rcx
movq %rcx, 0x58(%rsp)
movq %rax, 0x90(%rsi)
movq $0x0, 0x48(%rsp)
imulq $0x58, 0x10(%rsp), %r14
movq $0x0, 0x20(%rsp)
xorl %ebx, %ebx
xorl %r15d, %r15d
movq 0x30(%rsp), %rcx
movl 0x18(%rcx), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
cmpq %rax, %r15
jae 0x1b9d5e
movq 0x30(%rdi), %rax
movq 0x48(%rax), %rax
movq 0x30(%rax,%r14), %rax
movq 0x10(%rcx), %r12
movq (%r12,%r15,8), %rsi
movq %rsi, %rcx
shrq $0x20, %rcx
imulq $0x24, %rcx, %rdx
movl (%rax,%rdx), %ecx
movl 0x20(%rax,%rdx), %edi
shrl $0x5, %edi
andl $0x1, %edi
leal (%rdi,%rcx,2), %edi
cmpl %esi, %edi
jne 0x1ba3c9
addq %rdx, %rax
movl 0xc(%rax), %edi
movl 0x10(%rax), %esi
imulq $0x28, %rcx, %rdx
addq 0x10(%rbp), %rdx
callq 0x1b2312
movq (%rsp), %rsi
movq 0xa0(%rsi), %rcx
movq %rax, (%rcx,%r15,8)
testq %rax, %rax
je 0x1ba3e8
testl %r13d, %r13d
movq 0x8(%rsp), %rdi
jne 0x1b9d51
movq 0x28(%rdi), %rcx
movl (%r12,%r15,8), %edx
shrl %edx
movq (%rcx), %r8
movq 0x80(%rcx), %rcx
movl (%r8,%rdx,4), %edx
incq %rcx
cmpq %rdx, %rcx
jb 0x1b9d51
incq %rbx
addq %rax, 0x20(%rsp)
addq %rax, 0x48(%rsp)
incq %r15
jmp 0x1b9ca3
movq %rbp, 0x18(%rsp)
cmpq $0x0, 0x20(%rsp)
pushq $0x1
popq %rax
cmovel %eax, %r13d
testq %rbx, %rbx
cmovel %eax, %r13d
movq %r13, 0x28(%rsp)
andq $0x0, 0x30(%rsi)
xorl %ebp, %ebp
xorl %edx, %edx
movq 0x10(%rsp), %r8
movq 0x30(%rsp), %rcx
movl 0x18(%rcx), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
cmpq %rax, %rdx
jae 0x1b9f6d
movq 0x10(%rcx), %rax
movq %rdx, 0x50(%rsp)
movl (%rax,%rdx,8), %ecx
movq 0x1a0(%rdi), %rax
movq 0x1b8(%rdi), %rbx
movl %ecx, 0x38(%rsp)
shrl %ecx
movq (%rax,%rcx,8), %r15
movq %rcx, 0x60(%rsp)
movq 0x8(%rax,%rcx,8), %r14
cmpq %r15, %r14
je 0x1b9f60
movq (%rbx,%r15,8), %rax
movq %rax, %rdx
shrq $0x20, %rdx
cmpq %r8, %rdx
je 0x1b9f58
movq 0x1d0(%rdi), %rcx
shlq $0x5, %rdx
testl $0x7ffffffe, 0x18(%rcx,%rdx) # imm = 0x7FFFFFFE
je 0x1b9f58
addq %rcx, %rdx
movq 0x10(%rdx), %rdx
movl %eax, %eax
movl (%rdx,%rax,8), %r12d
movl %r12d, %eax
shrl %eax
cmpl %eax, 0x60(%rsp)
jne 0x1ba38b
movq 0x40(%rsi), %rax
cmpq 0x38(%rsi), %rbp
jne 0x1b9e64
leaq (,%rbp,2), %rcx
testq %rbp, %rbp
pushq $0x2
popq %rdx
cmoveq %rdx, %rcx
movq %rcx, 0x38(%rsi)
imulq $0x18, %rcx, %rsi
movq %rax, %rdi
callq 0x2370
movq 0x8(%rsp), %rdi
movq (%rsp), %rsi
movq %rax, 0x40(%rsi)
movq 0x30(%rsi), %rbp
movq 0x1d0(%rdi), %rcx
imulq $0x18, %rbp, %r8
incq %rbp
movq %rbp, 0x30(%rsi)
leaq (%rax,%r8), %r13
movl 0x38(%rsp), %r9d
movl %r9d, 0x4(%rax,%r8)
movq (%rbx,%r15,8), %rdx
movl %edx, (%rax,%r8)
movl %r12d, %eax
xorl %r9d, %eax
andl $0x1, %eax
je 0x1b9eb6
movq %rdx, %r8
shrq $0x1b, %r8
andq $-0x20, %r8
movl 0x18(%rcx,%r8), %r8d
movl $0x7fffffff, %r9d       # imm = 0x7FFFFFFF
andl %r9d, %r8d
movl %edx, %r9d
notl %r9d
addl %r8d, %r9d
movl %r9d, (%r13)
shrq $0x1f, %rdx
andl $-0x2, %edx
orl %eax, %edx
shlq $0x20, %rdx
movq 0x50(%rsp), %r8
addq %r8, %rdx
movq %rdx, 0x10(%r13)
movq 0xa0(%rsi), %rax
movq (%rax,%r8,8), %rax
movl %eax, 0x8(%r13)
movq 0x30(%rdi), %rdx
movq 0x48(%rdx), %rdx
movq (%rbx,%r15,8), %rsi
movl %esi, %edi
shrq $0x20, %rsi
imulq $0x58, %rsi, %r8
movq 0x30(%rdx,%r8), %rdx
shlq $0x5, %rsi
movq 0x10(%rcx,%rsi), %rcx
movl 0x4(%rcx,%rdi,8), %ecx
imulq $0x24, %rcx, %rsi
movl (%rdx,%rsi), %ecx
movl 0x20(%rdx,%rsi), %edi
shrl $0x5, %edi
andl $0x1, %edi
leal (%rdi,%rcx,2), %edi
cmpl %r12d, %edi
jne 0x1ba3aa
movl %eax, %r12d
addq %rsi, %rdx
movl 0xc(%rdx), %edi
movl 0x10(%rdx), %esi
imulq $0x28, %rcx, %rdx
movq 0x18(%rsp), %rax
addq 0x10(%rax), %rdx
callq 0x1b2312
cmpq %r12, %rax
jae 0x1b9f4a
movl %eax, 0x8(%r13)
movq (%rsp), %rsi
movq 0x8(%rsp), %rdi
movq 0x10(%rsp), %r8
incq %r15
jmp 0x1b9dce
movq 0x50(%rsp), %rdx
incq %rdx
jmp 0x1b9d8a
movq 0x40(%rsi), %rdi
imulq $0x18, %rbp, %rsi
addq %rdi, %rsi
callq 0x1a47a8
movq (%rsp), %r10
movq 0x30(%r10), %rbx
andq $0x0, 0xc0(%r10)
pushq $0x1
popq %r14
pushq $0x28
popq %r15
xorl %ecx, %ecx
leaq 0x70(%rsp), %r12
movq 0x40(%rsp), %r13
movq 0x18(%rsp), %rbp
cmpq %rbx, %r14
ja 0x1ba0db
movq 0x40(%r10), %rsi
je 0x1b9fcc
imulq $0x18, %rcx, %rax
movq (%rsi,%r15), %rdx
xorq 0x10(%rsi,%rax), %rdx
shrq $0x20, %rdx
je 0x1ba0cf
imulq $0x18, %rcx, %rax
addq %rax, %rsi
movq %r14, %rdx
subq %rcx, %rdx
subq $0x8, %rsp
movl %r13d, %edi
movq %r10, %r8
movq %rbp, %r9
pushq %r12
movq 0x18(%rsp), %rax
pushq 0x30(%rax)
pushq 0x70(%rsp)
callq 0x1b379d
movq 0x20(%rsp), %r10
addq $0x20, %rsp
movl 0x78(%rsp), %edx
cmpl $-0x1, %edx
setne %sil
andb %al, %sil
movq %r14, %rcx
cmpb $0x1, %sil
jne 0x1ba0cf
movq 0xc0(%r10), %rcx
movq 0xd0(%r10), %rax
testq %rcx, %rcx
je 0x1ba05a
imulq $0x28, %rcx, %rsi
xorl -0x20(%rax,%rsi), %edx
cmpl $0x1, %edx
ja 0x1ba05a
addq %rsi, %rax
movq -0x18(%rax), %rdx
movq %r14, %rcx
cmpq 0x80(%rsp), %rdx
jae 0x1ba0cf
addq $-0x28, %rax
movq %rax, %rcx
jmp 0x1ba0a8
cmpq 0xc8(%r10), %rcx
jne 0x1ba096
leaq (%rcx,%rcx), %rdx
testq %rcx, %rcx
pushq $0x2
popq %rcx
cmoveq %rcx, %rdx
movq %rdx, 0xc8(%r10)
imulq $0x28, %rdx, %rsi
movq %rax, %rdi
callq 0x2370
movq (%rsp), %r10
movq %rax, 0xd0(%r10)
movq 0xc0(%r10), %rcx
leaq 0x1(%rcx), %rdx
movq %rdx, 0xc0(%r10)
imulq $0x28, %rcx, %rcx
addq %rax, %rcx
movq 0x90(%rsp), %rax
movq %rax, 0x20(%rcx)
movupd 0x70(%rsp), %xmm0
movupd 0x80(%rsp), %xmm1
movupd %xmm1, 0x10(%rcx)
movupd %xmm0, (%rcx)
movq %r14, %rcx
incq %r14
addq $0x18, %r15
jmp 0x1b9fa6
leaq 0x68(%rsp), %rax
andq $0x0, (%rax)
movq 0x8(%rsp), %rcx
movq 0x28(%rcx), %rdi
movq 0x1d0(%rcx), %rdx
movq 0xd0(%r10), %r8
movq 0x40(%r10), %rcx
movq 0xc0(%r10), %r9
movq %r10, %rsi
pushq %rax
pushq $0x2
pushq 0x38(%rsp)
pushq 0x28(%rsp)
callq 0x1b3dbe
addq $0x20, %rsp
movq %rax, %rbp
movq 0x30(%rsp), %rbx
movl 0x18(%rbx), %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
cmpq %rax, %rbp
ja 0x1ba407
testq %rbp, %rbp
movq (%rsp), %r10
je 0x1b9bd3
cmpq $0x0, 0x68(%rsp)
jne 0x1b9bd3
movq 0x88(%r10), %r12
movq 0xa0(%r10), %rsi
xorl %edi, %edi
xorl %ecx, %ecx
xorl %eax, %eax
xorl %edx, %edx
cmpq %rdi, %rbp
je 0x1ba1b9
cmpl $0x0, 0x28(%rsp)
je 0x1ba177
movq (%r12,%rdi,8), %r8
jmp 0x1ba1b0
movq 0x8(%rsp), %r8
movq 0x28(%r8), %r9
movq 0x10(%rbx), %r10
movq (%r12,%rdi,8), %r8
movl (%r10,%r8,8), %r10d
shrl %r10d
movq (%r9), %r11
movq 0x80(%r9), %r9
movl (%r11,%r10,4), %r10d
incq %r9
cmpq %r10, %r9
jb 0x1ba1ac
incq %rcx
addq (%rsi,%r8,8), %rax
movq (%rsp), %r10
addq (%rsi,%r8,8), %rdx
incq %rdi
jmp 0x1ba165
movq %rbp, 0x78(%r10)
cmpl $0x0, 0x28(%rsp)
je 0x1ba1f5
movq %rdx, %xmm0
movq 0x2909f(%rip), %xmm1    # 0x1e3270
punpckldq %xmm1, %xmm0    # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
movapd 0x290a3(%rip), %xmm2    # 0x1e3280
subpd %xmm2, %xmm0
movapd %xmm0, %xmm3
unpckhpd %xmm0, %xmm3            # xmm3 = xmm3[1],xmm0[1]
addsd %xmm0, %xmm3
movq 0x48(%rsp), %xmm0
jmp 0x1ba236
testq %rcx, %rcx
je 0x1b9bd3
testq %rax, %rax
je 0x1b9bd3
movq %rax, %xmm0
movq 0x2905c(%rip), %xmm1    # 0x1e3270
punpckldq %xmm1, %xmm0    # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
movapd 0x29060(%rip), %xmm2    # 0x1e3280
subpd %xmm2, %xmm0
movapd %xmm0, %xmm3
unpckhpd %xmm0, %xmm3            # xmm3 = xmm3[1],xmm0[1]
addsd %xmm0, %xmm3
movq 0x20(%rsp), %xmm0
punpckldq %xmm1, %xmm0    # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
subpd %xmm2, %xmm0
movapd %xmm0, %xmm1
unpckhpd %xmm0, %xmm1            # xmm1 = xmm1[1],xmm0[1]
addsd %xmm0, %xmm1
mulsd 0x292ce(%rip), %xmm1    # 0x1e3520
ucomisd %xmm3, %xmm1
jae 0x1b9bd3
xorl %ebx, %ebx
xorl %r13d, %r13d
xorl %r14d, %r14d
cmpq 0xc0(%r10), %r14
jae 0x1ba2eb
movq 0x8(%rsp), %rax
movq 0x28(%rax), %rsi
movq 0x30(%rax), %rdi
movq 0x1d0(%rax), %rcx
movq 0x40(%r10), %r8
movq 0xd0(%r10), %r9
addq %rbx, %r9
movq 0x18(%rsp), %rdx
pushq %rbp
pushq %r12
pushq %r10
pushq 0x28(%rsp)
movq %r10, %r15
callq 0x1b5102
addq $0x20, %rsp
testq %rax, %rax
je 0x1ba2dc
movq 0xd0(%r15), %rax
imulq $0x28, %r13, %rcx
incq %r13
movq 0x20(%rax,%rbx), %rdx
movq %rdx, 0x20(%rax,%rcx)
movupd (%rax,%rbx), %xmm0
movupd 0x10(%rax,%rbx), %xmm1
movupd %xmm1, 0x10(%rax,%rcx)
movupd %xmm0, (%rax,%rcx)
movq %r15, %r10
incq %r14
addq $0x28, %rbx
jmp 0x1ba264
movq %r13, 0xc0(%r10)
testq %r13, %r13
je 0x1b9bd3
leaq 0xf0(%r10), %rbp
movq 0x8(%rsp), %r15
movq 0x30(%r15), %rsi
movq 0x1d0(%r15), %rcx
movq 0xd0(%r10), %r8
subq $0x8, %rsp
leaq 0x44(%rsp), %rbx
movq %rbp, %rdi
movq 0x20(%rsp), %r12
movq %r12, %rdx
movq %r13, %r9
pushq %rbx
pushq %r10
pushq 0x28(%rsp)
movq %r10, %r14
callq 0x1b8aff
addq $0x20, %rsp
cmpl $0x0, (%rbx)
je 0x1ba354
incq 0x320(%r14)
jmp 0x1b9bd3
movq 0x180(%r14), %rdx
movl 0x170(%r14), %ecx
movq 0x30(%r15), %r8
movq 0x1d0(%r15), %r9
subq $0x10, %rsp
movq %rbp, %rdi
movq %r12, %rsi
pushq %r14
pushq 0x58(%rsp)
callq 0x1b9820
addq $0x20, %rsp
jmp 0x1b9bd3
leaq 0x3f18b(%rip), %rdi     # 0x1f951d
leaq 0x3d140(%rip), %rsi     # 0x1f74d9
leaq 0x3f125(%rip), %rcx     # 0x1f94c5
movl $0x1953, %edx           # imm = 0x1953
callq 0x2110
leaq 0x3f17f(%rip), %rdi     # 0x1f9530
leaq 0x3d121(%rip), %rsi     # 0x1f74d9
leaq 0x3f106(%rip), %rcx     # 0x1f94c5
movl $0x195c, %edx           # imm = 0x195C
callq 0x2110
leaq 0x3f0c7(%rip), %rdi     # 0x1f9497
leaq 0x3d102(%rip), %rsi     # 0x1f74d9
leaq 0x3f0e7(%rip), %rcx     # 0x1f94c5
movl $0x193f, %edx           # imm = 0x193F
callq 0x2110
leaq 0x3f11e(%rip), %rdi     # 0x1f950d
leaq 0x3d0e3(%rip), %rsi     # 0x1f74d9
leaq 0x3f0c8(%rip), %rcx     # 0x1f94c5
movl $0x1941, %edx           # imm = 0x1941
callq 0x2110
leaq 0x3f13d(%rip), %rdi     # 0x1f954b
leaq 0x3d0c4(%rip), %rsi     # 0x1f74d9
leaq 0x3f0a9(%rip), %rcx     # 0x1f94c5
movl $0x1975, %edx           # imm = 0x1975
callq 0x2110