// File: readmapping[P]alfalfa/src/mapper.cpp
// Function: pairedMatch4(sparseSA const&, read_t&, read_t&, align_opt const&, paired_opt const&)
void pairedMatch4(const sparseSA& sa, read_t & mate1, read_t & mate2, const align_opt & alnOptions, const paired_opt & pairedOpt){
    //FIND CANDIDATE REGIONS FOR BOTH MATES
    vector<lis_t>  lisIntervals1;
    vector<lis_t>  lisIntervals2;
    if(alnOptions.print >= 3) cerr << "calculate LIS of both mates"  << endl;
    calculateCandRegions(sa, mate1, alnOptions, lisIntervals1, alnOptions.errorPercent);
    calculateCandRegions(sa, mate2, alnOptions, lisIntervals2, alnOptions.errorPercent);
    //SORT ALL LIS
    vector<alnScoreInfo_t> pairedOrder;
    pairedOrder.reserve(lisIntervals1.size()+lisIntervals2.size());
    for(size_t i = 0; i < lisIntervals1.size(); i++)
        pairedOrder.push_back(alnScoreInfo_t(true, i,lisIntervals1[i].score));
    for(size_t i = 0; i < lisIntervals2.size(); i++)
        pairedOrder.push_back(alnScoreInfo_t(false, i,lisIntervals2[i].score));
    sort(pairedOrder.begin(),pairedOrder.end(),compAlnScorePaired);
    //TRY TO EXTEND LIS
    int Plength1 = mate1.sequence.length();
    int editDist1 = (int)(alnOptions.errorPercent*Plength1)+1;
    int minScore1 = (int) (Plength1*alnOptions.match + (alnOptions.mismatch-alnOptions.match)*editDist1);
    int Plength2 = mate2.sequence.length();
    int editDist2 = (int)(alnOptions.errorPercent*Plength2)+1;
    int minScore2 = (int) (Plength2*alnOptions.match + (alnOptions.mismatch-alnOptions.match)*editDist2);
    if(alnOptions.print >= 3) cerr << "process LIS in sorted order of both paires"  << endl;
    processLisIntervalsPaired(sa, mate1, mate2, alnOptions, lisIntervals1, lisIntervals2, 
    pairedOrder, alnOptions.maxAlnCount, alnOptions.minCoverage, minScore1, minScore2);
    if(mate1.alignments.empty() && !mate2.alignments.empty() && alnOptions.rescue){
        if(alnOptions.print >= 2) cerr << "#RESCUE" << endl;
        minScore1 = max(0,(int)(Plength1*alnOptions.match + (alnOptions.mismatch-alnOptions.match)*0.2*Plength1));
        int maxAlignmentCount = 20;
        int minCoverage = Plength1*0.01;
        processLisIntervals(sa, mate1, alnOptions, lisIntervals1, editDist1, maxAlignmentCount, minCoverage, minScore1);
    }
    else if(mate2.alignments.empty() && !mate1.alignments.empty() && alnOptions.rescue){
        if(alnOptions.print >= 2) cerr << "#RESCUE" << endl;
        minScore2 = max(0,(int)(Plength2*alnOptions.match + (alnOptions.mismatch-alnOptions.match)*0.2*Plength2));
        int maxAlignmentCount = 20;
        int minCoverage = Plength1*0.01;
        processLisIntervals(sa, mate2, alnOptions, lisIntervals2, editDist2, maxAlignmentCount, minCoverage, minScore2);
    }
    if(alnOptions.print >= 3) cerr << "first  mate resulted in " << mate1.alignments.size() << " alignments" << endl;
    if(alnOptions.print >= 3) cerr << "second mate resulted in " << mate2.alignments.size() << " alignments" << endl;
    if(mate1.alignments.empty() && mate2.alignments.empty() && pairedOpt.pairedRescue){
        minScore1 = max(0,(int)(Plength1*alnOptions.match + (alnOptions.mismatch-alnOptions.match)*0.2*Plength1));
        minScore2 = max(0,(int)(Plength2*alnOptions.match + (alnOptions.mismatch-alnOptions.match)*0.2*Plength2));
        processLisIntervalsPaired(sa, mate1, mate2, alnOptions, lisIntervals1, lisIntervals2, 
    pairedOrder, 20, 0.01, minScore1, minScore2);
    }
    if(alnOptions.print >= 3) cerr << "first mate resulted in " << mate1.alignments.size() << " alignments" << endl;
    if(alnOptions.print >= 3) cerr << "second mate resulted in " << mate2.alignments.size() << " alignments" << endl;
    int alnCount1 = mate1.alignmentCount();
    int alnCount2 = mate2.alignmentCount();
    int alnCount = 0;
    int maxPairedAlignments = alnOptions.alignmentCount+1;
    //ORDER ALIGNMENTS ACCORDING TO SCORE
    pairedOrder.clear();
    pairedOrder.reserve(alnCount1+alnCount2);
    for(size_t i = 0; i < mate1.alignments.size(); i++)
        pairedOrder.push_back(alnScoreInfo_t(true, i,mate1.alignments[i]->alignmentScore ));
    for(size_t i = 0; i < mate2.alignments.size(); i++)
        pairedOrder.push_back(alnScoreInfo_t(false, i,mate2.alignments[i]->alignmentScore ));
    sort(pairedOrder.begin(),pairedOrder.end(),compAlnScorePaired);
    //TRY AND PAIR THE ALIGNMENTS
    if(alnCount1>0 && alnCount2>0){
        if(alnOptions.print >= 3) cerr << "search concordant alignments" << endl;
        pairAlignmentsOrdered(sa, mate1, mate2, alnOptions, pairedOpt, 
        pairedOrder, alnCount, maxPairedAlignments);
    }
    //RESCUE PROCEDURE IF NO CONCORDANT ALIGNMENTS WERE FOUND
    if(pairedOpt.pairedRescue && alnCount < maxPairedAlignments && max(alnCount1,alnCount2)>0){
        if(alnOptions.print >= 2) cerr << "#PAIREDRESCUE" << endl;
        vector<alnScoreInfo_t> newAlnFromWindow;
        pairAlignmentToWindow(sa, mate1, mate2, alnOptions, pairedOpt, pairedOrder, 
        newAlnFromWindow, alnCount, maxPairedAlignments);
    }
    //FIND DISCORDANT ALIGNMENTS AMONGST HIGHEST SCORING UNPAIRED ALIGNMENTS
    int pairedAlignments = mate1.pairedAlignmentCount;
    if(alnOptions.print >= 2) cerr << "#CONCORDANTCOUNT " << pairedAlignments << endl;
    if(pairedOpt.discordant && alnCount < maxPairedAlignments){
        if(alnOptions.print >= 3) cerr << "search discordant alignments" << endl;
        calculateDiscordantAlignments(sa, mate1, mate2);
    }
    if(alnOptions.print >= 2) cerr << "#DISCORDANTCOUNT " << mate1.pairedAlignmentCount-pairedAlignments << endl;
}

// Assembly:
subq $0x2f8, %rsp            # imm = 0x2F8
movq %rdi, 0x2f0(%rsp)
movq %rsi, 0x2e8(%rsp)
movq %rdx, 0x2e0(%rsp)
movq %rcx, 0x2d8(%rsp)
movq %r8, 0x2d0(%rsp)
leaq 0x2b8(%rsp), %rdi
callq 0x4e460
leaq 0x2a0(%rsp), %rdi
callq 0x4e460
movq 0x2d8(%rsp), %rax
cmpl $0x3, 0x78(%rax)
jl 0x47de5
movq 0x4f252(%rip), %rdi     # 0x96ff0
leaq 0x36684(%rip), %rsi     # 0x7e429
callq 0x8360
movq %rax, 0x178(%rsp)
jmp 0x47db4
movq 0x178(%rsp), %rdi
movq 0x4f1ed(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x47dca
jmp 0x47de5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x298(%rsp)
movl %eax, 0x294(%rsp)
jmp 0x48eb4
movq 0x2f0(%rsp), %rdi
movq 0x2e8(%rsp), %rsi
movq 0x2d8(%rsp), %rdx
movsd 0x30(%rdx), %xmm0
leaq 0x2b8(%rsp), %rcx
callq 0x429c0
jmp 0x47e11
movq 0x2f0(%rsp), %rdi
movq 0x2e0(%rsp), %rsi
movq 0x2d8(%rsp), %rdx
movsd 0x30(%rdx), %xmm0
leaq 0x2a0(%rsp), %rcx
callq 0x429c0
jmp 0x47e3d
leaq 0x278(%rsp), %rdi
movq %rdi, 0x170(%rsp)
callq 0x4e6a0
leaq 0x2b8(%rsp), %rdi
callq 0x4c4b0
movq %rax, 0x168(%rsp)
leaq 0x2a0(%rsp), %rdi
callq 0x4c4b0
movq 0x168(%rsp), %rsi
movq 0x170(%rsp), %rdi
addq %rax, %rsi
callq 0x4e6b0
jmp 0x47e8e
movq $0x0, 0x270(%rsp)
movq 0x270(%rsp), %rax
movq %rax, 0x160(%rsp)
leaq 0x2b8(%rsp), %rdi
callq 0x4c4b0
movq %rax, %rcx
movq 0x160(%rsp), %rax
cmpq %rcx, %rax
jae 0x47f51
movq 0x270(%rsp), %rsi
movl %esi, %eax
movl %eax, 0x15c(%rsp)
leaq 0x2b8(%rsp), %rdi
callq 0x4c850
movl 0x15c(%rsp), %edx
movl (%rax), %ecx
leaq 0x264(%rsp), %rdi
movl $0x1, %esi
callq 0x4e660
jmp 0x47f06
leaq 0x278(%rsp), %rdi
leaq 0x264(%rsp), %rsi
callq 0x4e630
jmp 0x47f1d
jmp 0x47f1f
movq 0x270(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x270(%rsp)
jmp 0x47e9a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x298(%rsp)
movl %eax, 0x294(%rsp)
jmp 0x48ea7
movq $0x0, 0x258(%rsp)
movq 0x258(%rsp), %rax
movq %rax, 0x150(%rsp)
leaq 0x2a0(%rsp), %rdi
callq 0x4c4b0
movq %rax, %rcx
movq 0x150(%rsp), %rax
cmpq %rcx, %rax
jae 0x47ff4
movq 0x258(%rsp), %rsi
movl %esi, %eax
movl %eax, 0x14c(%rsp)
leaq 0x2a0(%rsp), %rdi
callq 0x4c850
movl 0x14c(%rsp), %edx
movl (%rax), %ecx
leaq 0x24c(%rsp), %rdi
xorl %esi, %esi
callq 0x4e660
jmp 0x47fc2
leaq 0x278(%rsp), %rdi
leaq 0x24c(%rsp), %rsi
callq 0x4e630
jmp 0x47fd9
jmp 0x47fdb
movq 0x258(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x258(%rsp)
jmp 0x47f5d
leaq 0x278(%rsp), %rdi
movq %rdi, 0x140(%rsp)
callq 0x4e810
movq 0x140(%rsp), %rdi
movq %rax, 0x240(%rsp)
callq 0x4e840
movq %rax, 0x238(%rsp)
movq 0x240(%rsp), %rdi
movq 0x238(%rsp), %rsi
leaq -0x3e6d(%rip), %rdx     # 0x441d0
callq 0x4e7c0
jmp 0x48044
movq 0x2e8(%rsp), %rdi
addq $0x20, %rdi
callq 0x8630
movl %eax, 0x234(%rsp)
movq 0x2d8(%rsp), %rax
movsd 0x30(%rax), %xmm0
cvtsi2sdl 0x234(%rsp), %xmm1
mulsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
addl $0x1, %eax
movl %eax, 0x230(%rsp)
movl 0x234(%rsp), %eax
movq 0x2d8(%rsp), %rcx
imull (%rcx), %eax
movq 0x2d8(%rsp), %rcx
movl 0x4(%rcx), %ecx
movq 0x2d8(%rsp), %rdx
subl (%rdx), %ecx
imull 0x230(%rsp), %ecx
addl %ecx, %eax
movl %eax, 0x22c(%rsp)
movq 0x2e0(%rsp), %rdi
addq $0x20, %rdi
callq 0x8630
movl %eax, 0x228(%rsp)
movq 0x2d8(%rsp), %rax
movsd 0x30(%rax), %xmm0
cvtsi2sdl 0x228(%rsp), %xmm1
mulsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
addl $0x1, %eax
movl %eax, 0x224(%rsp)
movl 0x228(%rsp), %eax
movq 0x2d8(%rsp), %rcx
imull (%rcx), %eax
movq 0x2d8(%rsp), %rcx
movl 0x4(%rcx), %ecx
movq 0x2d8(%rsp), %rdx
subl (%rdx), %ecx
imull 0x224(%rsp), %ecx
addl %ecx, %eax
movl %eax, 0x220(%rsp)
movq 0x2d8(%rsp), %rax
cmpl $0x3, 0x78(%rax)
jl 0x48177
movq 0x4eea7(%rip), %rdi     # 0x96ff0
leaq 0x363e7(%rip), %rsi     # 0x7e537
callq 0x8360
movq %rax, 0x138(%rsp)
jmp 0x4815f
movq 0x138(%rsp), %rdi
movq 0x4ee42(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x48175
jmp 0x48177
movq 0x2f0(%rsp), %rdi
movq 0x2e8(%rsp), %rsi
movq 0x2e0(%rsp), %rdx
movq 0x2d8(%rsp), %rcx
movl 0x60(%rcx), %r8d
movsd 0x68(%rcx), %xmm0
movl 0x22c(%rsp), %r9d
movl 0x220(%rsp), %r10d
movq %rsp, %rax
movl %r10d, 0x18(%rax)
movl %r9d, 0x10(%rax)
movl %r8d, 0x8(%rax)
leaq 0x278(%rsp), %r8
movq %r8, (%rax)
leaq 0x2b8(%rsp), %r8
leaq 0x2a0(%rsp), %r9
callq 0x4fbf0
jmp 0x481e1
movq 0x2e8(%rsp), %rdi
addq $0xb0, %rdi
callq 0xbe60
testb $0x1, %al
jne 0x481fe
jmp 0x4836f
movq 0x2e0(%rsp), %rdi
addq $0xb0, %rdi
callq 0xbe60
testb $0x1, %al
jne 0x4836f
movq 0x2d8(%rsp), %rax
testb $0x1, 0x71(%rax)
je 0x4836f
movq 0x2d8(%rsp), %rax
cmpl $0x2, 0x78(%rax)
jl 0x4826f
movq 0x4edaf(%rip), %rdi     # 0x96ff0
leaq 0x35e4e(%rip), %rsi     # 0x7e096
callq 0x8360
movq %rax, 0x130(%rsp)
jmp 0x48257
movq 0x130(%rsp), %rdi
movq 0x4ed4a(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x4826d
jmp 0x4826f
movl $0x0, 0x21c(%rsp)
movl 0x234(%rsp), %eax
movq 0x2d8(%rsp), %rcx
movl (%rcx), %edx
movl 0x4(%rcx), %ecx
movl %eax, %esi
imull %edx, %esi
cvtsi2sd %esi, %xmm1
subl %edx, %ecx
cvtsi2sd %ecx, %xmm0
movsd 0x358b3(%rip), %xmm2    # 0x7db58
mulsd %xmm2, %xmm0
cvtsi2sd %eax, %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movl %eax, 0x218(%rsp)
leaq 0x21c(%rsp), %rdi
leaq 0x218(%rsp), %rsi
callq 0x14d40
movq %rax, 0x128(%rsp)
jmp 0x482df
movq 0x128(%rsp), %rax
movl (%rax), %eax
movl %eax, 0x22c(%rsp)
movl $0x14, 0x214(%rsp)
cvtsi2sdl 0x234(%rsp), %xmm0
movsd 0x315dc(%rip), %xmm1    # 0x798e8
mulsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movl %eax, 0x210(%rsp)
movq 0x2f0(%rsp), %rdi
movq 0x2e8(%rsp), %rsi
movq 0x2d8(%rsp), %rdx
movl 0x230(%rsp), %r8d
movl 0x214(%rsp), %r9d
movl 0x210(%rsp), %ecx
movl 0x22c(%rsp), %r10d
movq %rsp, %rax
movl %r10d, 0x8(%rax)
movl %ecx, (%rax)
leaq 0x2b8(%rsp), %rcx
callq 0x41a60
jmp 0x4836a
jmp 0x484fc
movq 0x2e0(%rsp), %rdi
addq $0xb0, %rdi
callq 0xbe60
testb $0x1, %al
jne 0x4838c
jmp 0x484fa
movq 0x2e8(%rsp), %rdi
addq $0xb0, %rdi
callq 0xbe60
testb $0x1, %al
jne 0x484fa
movq 0x2d8(%rsp), %rax
testb $0x1, 0x71(%rax)
je 0x484fa
movq 0x2d8(%rsp), %rax
cmpl $0x2, 0x78(%rax)
jl 0x483fd
movq 0x4ec21(%rip), %rdi     # 0x96ff0
leaq 0x35cc0(%rip), %rsi     # 0x7e096
callq 0x8360
movq %rax, 0x120(%rsp)
jmp 0x483e5
movq 0x120(%rsp), %rdi
movq 0x4ebbc(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x483fb
jmp 0x483fd
movl $0x0, 0x20c(%rsp)
movl 0x228(%rsp), %eax
movq 0x2d8(%rsp), %rcx
movl (%rcx), %edx
movl 0x4(%rcx), %ecx
movl %eax, %esi
imull %edx, %esi
cvtsi2sd %esi, %xmm1
subl %edx, %ecx
cvtsi2sd %ecx, %xmm0
movsd 0x35725(%rip), %xmm2    # 0x7db58
mulsd %xmm2, %xmm0
cvtsi2sd %eax, %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movl %eax, 0x208(%rsp)
leaq 0x20c(%rsp), %rdi
leaq 0x208(%rsp), %rsi
callq 0x14d40
movq %rax, 0x118(%rsp)
jmp 0x4846d
movq 0x118(%rsp), %rax
movl (%rax), %eax
movl %eax, 0x220(%rsp)
movl $0x14, 0x204(%rsp)
cvtsi2sdl 0x234(%rsp), %xmm0
movsd 0x3144e(%rip), %xmm1    # 0x798e8
mulsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movl %eax, 0x200(%rsp)
movq 0x2f0(%rsp), %rdi
movq 0x2e0(%rsp), %rsi
movq 0x2d8(%rsp), %rdx
movl 0x224(%rsp), %r8d
movl 0x204(%rsp), %r9d
movl 0x200(%rsp), %ecx
movl 0x220(%rsp), %r10d
movq %rsp, %rax
movl %r10d, 0x8(%rax)
movl %ecx, (%rax)
leaq 0x2a0(%rsp), %rcx
callq 0x41a60
jmp 0x484f8
jmp 0x484fa
jmp 0x484fc
movq 0x2d8(%rsp), %rax
cmpl $0x3, 0x78(%rax)
jl 0x4858f
movq 0x4eadb(%rip), %rdi     # 0x96ff0
leaq 0x35fa1(%rip), %rsi     # 0x7e4bd
callq 0x8360
movq %rax, 0x110(%rsp)
jmp 0x4852b
movq 0x2e8(%rsp), %rdi
addq $0xb0, %rdi
callq 0xdac0
movq 0x110(%rsp), %rdi
movq %rax, %rsi
callq 0x8100
movq %rax, 0x108(%rsp)
jmp 0x48559
movq 0x108(%rsp), %rdi
leaq 0x35f7f(%rip), %rsi     # 0x7e4e7
callq 0x8360
movq %rax, 0x100(%rsp)
jmp 0x48577
movq 0x100(%rsp), %rdi
movq 0x4ea2a(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x4858d
jmp 0x4858f
movq 0x2d8(%rsp), %rax
cmpl $0x3, 0x78(%rax)
jl 0x48622
movq 0x4ea48(%rip), %rdi     # 0x96ff0
leaq 0x35d71(%rip), %rsi     # 0x7e320
callq 0x8360
movq %rax, 0xf8(%rsp)
jmp 0x485be
movq 0x2e0(%rsp), %rdi
addq $0xb0, %rdi
callq 0xdac0
movq 0xf8(%rsp), %rdi
movq %rax, %rsi
callq 0x8100
movq %rax, 0xf0(%rsp)
jmp 0x485ec
movq 0xf0(%rsp), %rdi
leaq 0x35eec(%rip), %rsi     # 0x7e4e7
callq 0x8360
movq %rax, 0xe8(%rsp)
jmp 0x4860a
movq 0xe8(%rsp), %rdi
movq 0x4e997(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x48620
jmp 0x48622
movq 0x2e8(%rsp), %rdi
addq $0xb0, %rdi
callq 0xbe60
testb $0x1, %al
jne 0x4863f
jmp 0x487de
movq 0x2e0(%rsp), %rdi
addq $0xb0, %rdi
callq 0xbe60
testb $0x1, %al
jne 0x4865c
jmp 0x487de
movq 0x2d0(%rsp), %rax
testb $0x1, 0x14(%rax)
je 0x487de
movl $0x0, 0x1fc(%rsp)
movl 0x234(%rsp), %eax
movq 0x2d8(%rsp), %rcx
movl (%rcx), %edx
movl 0x4(%rcx), %ecx
movl %eax, %esi
imull %edx, %esi
cvtsi2sd %esi, %xmm1
subl %edx, %ecx
cvtsi2sd %ecx, %xmm0
movsd 0x354b4(%rip), %xmm2    # 0x7db58
mulsd %xmm2, %xmm0
cvtsi2sd %eax, %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movl %eax, 0x1f8(%rsp)
leaq 0x1fc(%rsp), %rdi
leaq 0x1f8(%rsp), %rsi
callq 0x14d40
movq %rax, 0xe0(%rsp)
jmp 0x486de
movq 0xe0(%rsp), %rax
movl (%rax), %eax
movl %eax, 0x22c(%rsp)
movl $0x0, 0x1f4(%rsp)
movl 0x228(%rsp), %eax
movq 0x2d8(%rsp), %rcx
movl (%rcx), %edx
movl 0x4(%rcx), %ecx
movl %eax, %esi
imull %edx, %esi
cvtsi2sd %esi, %xmm1
subl %edx, %ecx
cvtsi2sd %ecx, %xmm0
movsd 0x35433(%rip), %xmm2    # 0x7db58
mulsd %xmm2, %xmm0
cvtsi2sd %eax, %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movl %eax, 0x1f0(%rsp)
leaq 0x1f4(%rsp), %rdi
leaq 0x1f0(%rsp), %rsi
callq 0x14d40
movq %rax, 0xd8(%rsp)
jmp 0x4875f
movq 0xd8(%rsp), %rax
movl (%rax), %eax
movl %eax, 0x220(%rsp)
movq 0x2f0(%rsp), %rdi
movq 0x2e8(%rsp), %rsi
movq 0x2e0(%rsp), %rdx
movq 0x2d8(%rsp), %rcx
movl 0x22c(%rsp), %r8d
movl 0x220(%rsp), %r9d
movq %rsp, %rax
movl %r9d, 0x18(%rax)
movl %r8d, 0x10(%rax)
leaq 0x278(%rsp), %r8
movq %r8, (%rax)
movl $0x14, 0x8(%rax)
leaq 0x2b8(%rsp), %r8
leaq 0x2a0(%rsp), %r9
movsd 0x31113(%rip), %xmm0    # 0x798e8
callq 0x4fbf0
jmp 0x487dc
jmp 0x487de
movq 0x2d8(%rsp), %rax
cmpl $0x3, 0x78(%rax)
jl 0x48871
movq 0x4e7f9(%rip), %rdi     # 0x96ff0
leaq 0x35af1(%rip), %rsi     # 0x7e2ef
callq 0x8360
movq %rax, 0xd0(%rsp)
jmp 0x4880d
movq 0x2e8(%rsp), %rdi
addq $0xb0, %rdi
callq 0xdac0
movq 0xd0(%rsp), %rdi
movq %rax, %rsi
callq 0x8100
movq %rax, 0xc8(%rsp)
jmp 0x4883b
movq 0xc8(%rsp), %rdi
leaq 0x35c9d(%rip), %rsi     # 0x7e4e7
callq 0x8360
movq %rax, 0xc0(%rsp)
jmp 0x48859
movq 0xc0(%rsp), %rdi
movq 0x4e748(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x4886f
jmp 0x48871
movq 0x2d8(%rsp), %rax
cmpl $0x3, 0x78(%rax)
jl 0x48904
movq 0x4e766(%rip), %rdi     # 0x96ff0
leaq 0x35a8f(%rip), %rsi     # 0x7e320
callq 0x8360
movq %rax, 0xb8(%rsp)
jmp 0x488a0
movq 0x2e0(%rsp), %rdi
addq $0xb0, %rdi
callq 0xdac0
movq 0xb8(%rsp), %rdi
movq %rax, %rsi
callq 0x8100
movq %rax, 0xb0(%rsp)
jmp 0x488ce
movq 0xb0(%rsp), %rdi
leaq 0x35c0a(%rip), %rsi     # 0x7e4e7
callq 0x8360
movq %rax, 0xa8(%rsp)
jmp 0x488ec
movq 0xa8(%rsp), %rdi
movq 0x4e6b5(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x48902
jmp 0x48904
movq 0x2e8(%rsp), %rdi
callq 0xc0c0
movl %eax, 0xa4(%rsp)
jmp 0x4891a
movl 0xa4(%rsp), %eax
movl %eax, 0x1ec(%rsp)
movq 0x2e0(%rsp), %rdi
callq 0xc0c0
movl %eax, 0xa0(%rsp)
jmp 0x4893e
movl 0xa0(%rsp), %eax
movl %eax, 0x1e8(%rsp)
movl $0x0, 0x1e4(%rsp)
movq 0x2d8(%rsp), %rax
movl 0x50(%rax), %eax
incl %eax
movl %eax, 0x1e0(%rsp)
leaq 0x278(%rsp), %rdi
movq %rdi, 0x98(%rsp)
callq 0x509d0
movq 0x98(%rsp), %rdi
movl 0x1ec(%rsp), %eax
movl 0x1e8(%rsp), %ecx
addl %ecx, %eax
movslq %eax, %rsi
callq 0x4e6b0
jmp 0x489a2
movq $0x0, 0x1d8(%rsp)
movq 0x1d8(%rsp), %rax
movq %rax, 0x90(%rsp)
movq 0x2e8(%rsp), %rdi
addq $0xb0, %rdi
callq 0xdac0
movq %rax, %rcx
movq 0x90(%rsp), %rax
cmpq %rcx, %rax
jae 0x48a5a
movq 0x1d8(%rsp), %rsi
movl %esi, %eax
movl %eax, 0x8c(%rsp)
movq 0x2e8(%rsp), %rdi
addq $0xb0, %rdi
callq 0xdae0
movl 0x8c(%rsp), %edx
movq (%rax), %rax
movl 0x70(%rax), %ecx
leaq 0x1cc(%rsp), %rdi
movl $0x1, %esi
callq 0x4e660
jmp 0x48a28
leaq 0x278(%rsp), %rdi
leaq 0x1cc(%rsp), %rsi
callq 0x4e630
jmp 0x48a3f
jmp 0x48a41
movq 0x1d8(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x1d8(%rsp)
jmp 0x489ae
movq $0x0, 0x1c0(%rsp)
movq 0x1c0(%rsp), %rax
movq %rax, 0x80(%rsp)
movq 0x2e0(%rsp), %rdi
addq $0xb0, %rdi
callq 0xdac0
movq %rax, %rcx
movq 0x80(%rsp), %rax
cmpq %rcx, %rax
jae 0x48b09
movq 0x1c0(%rsp), %rsi
movl %esi, %eax
movl %eax, 0x7c(%rsp)
movq 0x2e0(%rsp), %rdi
addq $0xb0, %rdi
callq 0xdae0
movl 0x7c(%rsp), %edx
movq (%rax), %rax
movl 0x70(%rax), %ecx
leaq 0x1b4(%rsp), %rdi
xorl %esi, %esi
callq 0x4e660
jmp 0x48ad7
leaq 0x278(%rsp), %rdi
leaq 0x1b4(%rsp), %rsi
callq 0x4e630
jmp 0x48aee
jmp 0x48af0
movq 0x1c0(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x1c0(%rsp)
jmp 0x48a66
leaq 0x278(%rsp), %rdi
movq %rdi, 0x70(%rsp)
callq 0x4e810
movq 0x70(%rsp), %rdi
movq %rax, 0x1a8(%rsp)
callq 0x4e840
movq %rax, 0x1a0(%rsp)
movq 0x1a8(%rsp), %rdi
movq 0x1a0(%rsp), %rsi
leaq -0x497c(%rip), %rdx     # 0x441d0
callq 0x4e7c0
jmp 0x48b53
cmpl $0x0, 0x1ec(%rsp)
jle 0x48bff
cmpl $0x0, 0x1e8(%rsp)
jle 0x48bff
movq 0x2d8(%rsp), %rax
cmpl $0x3, 0x78(%rax)
jl 0x48bac
movq 0x4e46c(%rip), %rdi     # 0x96ff0
leaq 0x3594b(%rip), %rsi     # 0x7e4d6
callq 0x8360
movq %rax, 0x68(%rsp)
jmp 0x48b97
movq 0x68(%rsp), %rdi
movq 0x4e40d(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x48baa
jmp 0x48bac
movq 0x2f0(%rsp), %rdi
movq 0x2e8(%rsp), %rsi
movq 0x2e0(%rsp), %rdx
movq 0x2d8(%rsp), %rcx
movq 0x2d0(%rsp), %r8
movl 0x1e0(%rsp), %r9d
movq %rsp, %rax
movl %r9d, 0x8(%rax)
leaq 0x1e4(%rsp), %r9
movq %r9, (%rax)
leaq 0x278(%rsp), %r9
callq 0x44f10
jmp 0x48bfd
jmp 0x48bff
movq 0x2d0(%rsp), %rax
testb $0x1, 0x14(%rax)
je 0x48d2d
movl 0x1e4(%rsp), %eax
cmpl 0x1e0(%rsp), %eax
jge 0x48d2d
leaq 0x1ec(%rsp), %rdi
leaq 0x1e8(%rsp), %rsi
callq 0x14d40
movq %rax, 0x60(%rsp)
jmp 0x48c41
movq 0x60(%rsp), %rax
cmpl $0x0, (%rax)
jle 0x48d2d
movq 0x2d8(%rsp), %rax
cmpl $0x2, 0x78(%rax)
jl 0x48c8c
movq 0x4e38c(%rip), %rdi     # 0x96ff0
leaq 0x356f6(%rip), %rsi     # 0x7e361
callq 0x8360
movq %rax, 0x58(%rsp)
jmp 0x48c77
movq 0x58(%rsp), %rdi
movq 0x4e32d(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x48c8a
jmp 0x48c8c
leaq 0x188(%rsp), %rdi
movq %rdi, 0x50(%rsp)
callq 0x4e6a0
movq 0x50(%rsp), %r9
movq 0x2f0(%rsp), %rdi
movq 0x2e8(%rsp), %rsi
movq 0x2e0(%rsp), %rdx
movq 0x2d8(%rsp), %rcx
movq 0x2d0(%rsp), %r8
movl 0x1e0(%rsp), %r10d
movq %rsp, %rax
movl %r10d, 0x10(%rax)
leaq 0x1e4(%rsp), %r10
movq %r10, 0x8(%rax)
movq %r9, (%rax)
leaq 0x278(%rsp), %r9
callq 0x44370
jmp 0x48cf8
leaq 0x188(%rsp), %rdi
callq 0x4e870
jmp 0x48d2d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x298(%rsp)
movl %eax, 0x294(%rsp)
leaq 0x188(%rsp), %rdi
callq 0x4e870
jmp 0x48ea7
movq 0x2e8(%rsp), %rax
movl 0xc8(%rax), %eax
movl %eax, 0x184(%rsp)
movq 0x2d8(%rsp), %rax
cmpl $0x2, 0x78(%rax)
jl 0x48d97
movq 0x4e299(%rip), %rdi     # 0x96ff0
leaq 0x35663(%rip), %rsi     # 0x7e3c1
callq 0x8360
movq %rax, 0x48(%rsp)
jmp 0x48d6a
movq 0x48(%rsp), %rdi
movl 0x184(%rsp), %esi
callq 0x8710
movq %rax, 0x40(%rsp)
jmp 0x48d82
movq 0x40(%rsp), %rdi
movq 0x4e222(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x48d95
jmp 0x48d97
movq 0x2d0(%rsp), %rax
testb $0x1, 0x9(%rax)
je 0x48e13
movl 0x1e4(%rsp), %eax
cmpl 0x1e0(%rsp), %eax
jge 0x48e13
movq 0x2d8(%rsp), %rax
cmpl $0x3, 0x78(%rax)
jl 0x48df2
movq 0x4e226(%rip), %rdi     # 0x96ff0
leaq 0x35722(%rip), %rsi     # 0x7e4f3
callq 0x8360
movq %rax, 0x38(%rsp)
jmp 0x48ddd
movq 0x38(%rsp), %rdi
movq 0x4e1c7(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x48df0
jmp 0x48df2
movq 0x2f0(%rsp), %rdi
movq 0x2e8(%rsp), %rsi
movq 0x2e0(%rsp), %rdx
callq 0x43d30
jmp 0x48e11
jmp 0x48e13
movq 0x2d8(%rsp), %rax
cmpl $0x2, 0x78(%rax)
jl 0x48e78
movq 0x4e1c8(%rip), %rdi     # 0x96ff0
leaq 0x355a4(%rip), %rsi     # 0x7e3d3
callq 0x8360
movq %rax, 0x30(%rsp)
jmp 0x48e3b
movq 0x30(%rsp), %rdi
movq 0x2e8(%rsp), %rax
movl 0xc8(%rax), %esi
movl 0x184(%rsp), %eax
subl %eax, %esi
callq 0x8710
movq %rax, 0x28(%rsp)
jmp 0x48e63
movq 0x28(%rsp), %rdi
movq 0x4e141(%rip), %rsi     # 0x96fb0
callq 0x83b0
jmp 0x48e76
jmp 0x48e78
leaq 0x278(%rsp), %rdi
callq 0x4e870
leaq 0x2a0(%rsp), %rdi
callq 0x4e4e0
leaq 0x2b8(%rsp), %rdi
callq 0x4e4e0
addq $0x2f8, %rsp            # imm = 0x2F8
retq
leaq 0x278(%rsp), %rdi
callq 0x4e870
leaq 0x2a0(%rsp), %rdi
callq 0x4e4e0
leaq 0x2b8(%rsp), %rdi
callq 0x4e4e0
movq 0x298(%rsp), %rdi
callq 0x8730
nopl (%rax,%rax)