// File: /workspace/github_cpp_makefile_star2_O1/schneebergerlab[P]DrLink/sample_molecule.cpp
// Function: sample_molecule(int, char**)
bool sample_molecule(int argc, char* argv[])
{
    std::stringstream usage;
    usage.str("");
    if(argc < 8)
    {
        usage << endl;
        usage << "   Given sets of molecule size distributions and molecule info, "                         
              << endl;
        usage << "   this function samples molecules according to intersection of molecule sizes"           
              << endl;        
        const char *buildString = __DATE__", " __TIME__;
        usage << "   (compiled on " << buildString << ")"                                                   
              << endl << endl;
        usage << "   Usage: DrLink resample msize1.txt,msize2.txt[,...] mole1.gz,mole2.gz[,...] read1,read2[,...] labels outprefix srand-sleep-int" 
              << endl << endl;
        usage << "\twhere "                                                         << endl;
        usage << "\tmsize*.txt:   molecule size distribution of pools"              << endl;
        usage << "\tmole*.gz  :   molecule meta info corresponding to molecule size of pools from DrLink molecule"  
              << endl;
        usage << "\tread*     :   mean molecule read coverage in raw data"          << endl;
        usage << "\tlabels    :   sample-specific label of output files"            << endl;
        usage << "\toutprefix :   general label of output files"                    << endl;
        cout  << usage.str() << endl;
        return false;
    }
    double startT   = clock(); 
    int srandsleep  = atoi(argv[7]); 
    cout << "   Info: sleeping " << srandsleep << " seconds to get various srand seeds. " << endl;
    sleep(srandsleep);
    string lenfiles = (string)argv[2];
    vector<string> lenfileinfo = split_string(lenfiles, ',');
    if(lenfileinfo.size()<2)
    {
        cout << "   Error: only one file given. No need to sample!" << endl;
        return false;
    }
    string molfiles = (string)argv[3];
    vector<string> molfileinfo = split_string(molfiles, ',');
    if(molfileinfo.size()<2)
    {
        cout << "   Error: only one file given. No need to sample!" << endl;
        return false;
    }    
    if(lenfileinfo.size() != molfileinfo.size())
    {
        cout << "   Error: molecule-size file-number does not matach molecule-meta-info file-number. " << endl;
        return false;
    }
    //
    vector<string> labels = split_string((string)argv[5], ',');
    string out_prefix     = string(argv[6]);       
    // 1. read number of molecule-size distributions in pools
    map<int, unsigned long> mNum_intersec;
    map<int, map<int, unsigned long> > mNum_individ;
    vector<string>::iterator lfitr;
    vector<string>::iterator lfitr_end;
    lfitr     = lenfileinfo.begin();
    lfitr_end = lenfileinfo.end();
    int i = -1;
    while(lfitr != lfitr_end)
    {
        string msfile = *lfitr;
        map<int, unsigned long> mNum;
        if(!(read_msize_dist(msfile, &mNum, &mNum_intersec)))
        {
            cout << "   Error: failed in reading molecule size distribution. " << endl;
            return false;
        }
        i ++;
        //
        mNum_individ.insert(std::pair<int, map<int, unsigned long> >(i, mNum) );
        //
        lfitr ++;
    }
    // 2. get sampling ratio with respecitve to a specific molecule size for each pool
    map<int, map<int, double> > mNum_individ_sratio;
    lfitr     = lenfileinfo.begin();
    lfitr_end = lenfileinfo.end();
    i = -1;
    while(lfitr != lfitr_end)
    {
        map<int, double> msratio;
        //
        i ++;
        map<int, unsigned long> mNum = mNum_individ[i];
        map<int, unsigned long>::iterator lenitr;
        map<int, unsigned long>::iterator lenitr_end;
        lenitr     = mNum.begin();
        lenitr_end = mNum.end();
        while(lenitr != lenitr_end)
        {
            int key           = (*lenitr).first;
            unsigned long num = (*lenitr).second;
            assert( mNum_intersec.find(key) != mNum_intersec.end() );
            if(num == 0) num  = 1;
            double sratio     = mNum_intersec[key]*1.0/num;
            sratio = sratio*0.96;
            
            // scaling - 2018-09-25: to get C substantially sampled while keeping around 6 million molecules
            if(labels[i].compare("B") == 0) 
            {
                sratio = sratio*(6000000.0/7016664.0);
            }else
            if(labels[i].compare("C") == 0)
            {
                sratio = sratio*(6000000.0/6949772.0);
            }else
            if(labels[i].compare("D") == 0) 
            {
                sratio = sratio*(6000000.0/7273738.0);
            }else
            if(labels[i].compare("E") == 0) 
            {
                sratio = sratio*(6000000.0/7101105.0);
            }else
            if(labels[i].compare("P") == 0) 
            {
                sratio = sratio*(6000000.0/6682080.0); // 6882080
            }else ;
            //
               
            msratio.insert(std::pair<int, double>(key, sratio)); // to make D sampled
            lenitr ++;
        }
        //
        mNum_individ_sratio.insert(std::pair<int, map<int, double> >(i, msratio));      
        //
        lfitr ++; 
    }
    // check
    if(true)
    {
        lfitr     = lenfileinfo.begin();
        lfitr_end = lenfileinfo.end();
        i = -1;   
        while(lfitr != lfitr_end)     
        {
            i ++;
            map<int, unsigned long> mNum = mNum_individ[i];
            map<int, double>     msratio = mNum_individ_sratio[i];
            cout << "   Check: file " << lenfileinfo[i] << endl << endl;
            if(labels[i].compare("D") == 0) 
            {
                cout << "   Info: all length ratio decreased by 0.04 to get D a random molecule number. " << endl;
            }
            map<int, double>::iterator sritr;
            map<int, double>::iterator sritr_end;
            sritr     = msratio.begin();
            sritr_end = msratio.end();
            while(sritr != sritr_end)
            {
                int key = (*sritr).first;
                cout << "      " 
                     << (*sritr).first 
                     << "\t" << (*sritr).second 
                     << " from " 
                     << mNum_intersec[key] 
                     << "/" 
                     << mNum[key] 
                     << endl;
                sritr ++;
            }
            lfitr ++;
        }
    }
    // 3. get sampling ratio with respecitve to a specific molecule base coverage for each pool
    
    // 4. sample molecules
    // read ratio
    vector<string> readratiostr = split_string((string)argv[4], ',');
    vector<double> readratio; // ratio of reads to keep
    double minmrc = 1;
    vector<string>::iterator rritr;
    vector<string>::iterator rritr_end;
    rritr     = readratiostr.begin();
    rritr_end = readratiostr.end();
    while(rritr != rritr_end)
    {
        double rr = atof((*rritr).c_str());
        readratio.push_back(rr);
        if(minmrc > rr) minmrc = rr;
        rritr ++;
    }
    vector<double>::iterator rr2itr     = readratio.begin();
    vector<double>::iterator rr2itr_end = readratio.end();
    while(rr2itr != rr2itr_end)
    {
        (*rr2itr) = 1.0 - ((*rr2itr) - minmrc)/(*rr2itr);
        rr2itr ++;
    }
    // molecule
    vector<string>::iterator mfitr;
    vector<string>::iterator mfitr_end;
    mfitr     = molfileinfo.begin();
    mfitr_end = molfileinfo.end();
    i = -1;
    while(mfitr != mfitr_end)
    {
        i ++;
        double this_readratio       = readratio[i];
            // special - caution!
            if(labels[i].compare("B") == 0) 
            {
                this_readratio = this_readratio*0.95*0.83643;
            }else
            if(labels[i].compare("C") == 0)
            {
                this_readratio = this_readratio*1.00*0.788091;
            }else
            if(labels[i].compare("D") == 0) 
            {
                this_readratio = this_readratio*0.92*44.0/49.0;
            }else
            if(labels[i].compare("E") == 0) 
            {
                this_readratio = this_readratio*1.00;
            }else
            if(labels[i].compare("P") == 0) 
            {
                this_readratio = this_readratio*0.92*44.0/49.0;
            }else ;
        string molfile              = molfileinfo[i];
        string ilabel               = labels[i];
        map<int,    double> msratio = mNum_individ_sratio[i];    
        //    
        map<string, unsigned long> molecule_cov;
        map<int,    unsigned long> molecule_len;
        map<int,    unsigned long> molecule_len_sum;                 
        map<int,    unsigned long> molecule_read_num;
        map<int,    unsigned long> molecule_read_num_sum;
        map<string,           int> barcode_molecule_cnt;
        if(molfile.compare("skip") != 0)
        {
            if(!sampling_molecule(molfile, 
                                this_readratio,
                                out_prefix + "_" + ilabel, 
                                msratio, 
                                &molecule_cov,
                                &molecule_len,
                                &molecule_len_sum,                      
                                &molecule_read_num,
                                &molecule_read_num_sum,
                                &barcode_molecule_cnt))
            {
                return false;
            }  
            if(!write_sampled_molecule_stat(molecule_cov, 
                                            molecule_len, 
                                            molecule_len_sum, 
                                            molecule_read_num,
                                            molecule_read_num_sum,
                                            barcode_molecule_cnt,
                                            out_prefix + "_" + ilabel))
            {
                return false;
            }
        }
        mfitr ++;  
    }  
        
    double finishT= clock();
    cout << "   Time consumed: " << (finishT-startT)/1000000 << " seconds" << endl << endl;    
    return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x6b8, %rsp            # imm = 0x6B8
movq %rsi, %r15
movl %edi, %ebx
leaq 0x500(%rsp), %rdi
callq 0x4240
leaq 0x30(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x18b1e(%rip), %rdx     # 0x3eb22
leaq 0x20(%rsp), %rdi
movq %rdx, %rsi
callq 0x5384
leaq 0x518(%rsp), %r14
leaq 0x20(%rsp), %rsi
movq %r14, %rdi
callq 0x4490
movq 0x20(%rsp), %rdi
cmpq %r12, %rdi
je 0x2603d
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x4340
cmpl $0x7, %ebx
jg 0x263dc
leaq 0x510(%rsp), %rbx
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
leaq 0x17f4c(%rip), %rsi     # 0x3dfc8
movl $0x40, %edx
movq %rbx, %rdi
callq 0x43a0
movq 0x510(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
leaq 0x17f4d(%rip), %rsi     # 0x3e009
movl $0x4e, %edx
movq %rbx, %rdi
callq 0x43a0
movq 0x510(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
leaq 0x17bcf(%rip), %rsi     # 0x3dccb
movl $0x10, %edx
movq %rbx, %rdi
callq 0x43a0
leaq 0x17f48(%rip), %rsi     # 0x3e058
movl $0x15, %edx
movq %rbx, %rdi
callq 0x43a0
leaq 0x1821c(%rip), %rsi     # 0x3e340
movl $0x1, %edx
movq %rbx, %rdi
callq 0x43a0
movq 0x510(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %r15, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
leaq 0x17ee0(%rip), %rsi     # 0x3e06e
movl $0x80, %edx
movq %rbx, %rdi
callq 0x43a0
movq 0x510(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %r15, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
leaq 0x17b35(%rip), %rsi     # 0x3dd2d
movl $0x7, %edx
movq %rbx, %rdi
callq 0x43a0
movq 0x510(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
leaq 0x17eb7(%rip), %rsi     # 0x3e0ef
movl $0x32, %edx
movq %rbx, %rdi
callq 0x43a0
movq 0x510(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
leaq 0x17eaa(%rip), %rsi     # 0x3e122
movl $0x5e, %edx
movq %rbx, %rdi
callq 0x43a0
movq 0x510(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
leaq 0x17ec9(%rip), %rsi     # 0x3e181
movl $0x36, %edx
movq %rbx, %rdi
callq 0x43a0
movq 0x510(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
leaq 0x17ec0(%rip), %rsi     # 0x3e1b8
movl $0x34, %edx
movq %rbx, %rdi
callq 0x43a0
movq 0x510(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
leaq 0x17eb5(%rip), %rsi     # 0x3e1ed
movl $0x2c, %edx
movq %rbx, %rdi
callq 0x43a0
movq 0x510(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
leaq 0x20(%rsp), %rdi
movq %r14, %rsi
callq 0x44f0
movq 0x20(%rsp), %rsi
movq 0x28(%rsp), %rdx
movq 0x25c39(%rip), %rdi     # 0x4bfc8
callq 0x43a0
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
movq 0x20(%rsp), %rdi
cmpq %r12, %rdi
je 0x263d5
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x4340
xorl %ebx, %ebx
jmp 0x277f1
callq 0x4200
movq %rax, %rbx
movq 0x38(%r15), %rdi
callq 0x44d0
movl %eax, %ebp
movq 0x25bd2(%rip), %rdi     # 0x4bfc8
leaq 0x17e1d(%rip), %rsi     # 0x3e21a
movl $0x12, %edx
callq 0x43a0
movq 0x25bba(%rip), %rdi     # 0x4bfc8
movl %ebp, %esi
callq 0x4580
movq %rax, %r14
leaq 0x17e0e(%rip), %rsi     # 0x3e22d
movl $0x25, %edx
movq %rax, %rdi
callq 0x43a0
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %r14, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
movl %ebp, %edi
callq 0x4270
movq 0x10(%r15), %rsi
leaq 0x360(%rsp), %rdi
leaq 0x20(%rsp), %rdx
callq 0x5346
leaq 0x20(%rsp), %rdx
movb $0x2c, (%rdx)
leaq 0xc8(%rsp), %rdi
leaq 0x360(%rsp), %rsi
callq 0x36b7c
movq 0xd0(%rsp), %rax
subq 0xc8(%rsp), %rax
cmpq $0x20, %rax
ja 0x264f0
movq 0x25b1e(%rip), %rbx     # 0x4bfc8
leaq 0x17da2(%rip), %rsi     # 0x3e253
movl $0x31, %edx
movq %rbx, %rdi
callq 0x43a0
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq 0x25aec(%rip), %rdi     # 0x4bfc8
callq 0x4030
movq %rax, %rdi
callq 0x4220
xorl %ebx, %ebx
jmp 0x277c3
movq 0x18(%r15), %rsi
leaq 0x340(%rsp), %rdi
leaq 0x20(%rsp), %rdx
callq 0x5346
leaq 0x20(%rsp), %rdx
movb $0x2c, (%rdx)
leaq 0x1a0(%rsp), %rdi
leaq 0x340(%rsp), %rsi
callq 0x36b7c
movq 0x1a8(%rsp), %rax
subq 0x1a0(%rsp), %rax
cmpq $0x21, %rax
jae 0x2654a
movl $0x31, %edx
leaq 0x17d0e(%rip), %rsi     # 0x3e253
jmp 0x267c1
movq 0xd0(%rsp), %rcx
subq 0xc8(%rsp), %rcx
cmpq %rax, %rcx
jne 0x267b5
movq 0x28(%r15), %rsi
leaq 0x20(%rsp), %rdi
leaq 0x380(%rsp), %rdx
callq 0x5346
leaq 0x3b0(%rsp), %rdx
movb $0x2c, (%rdx)
leaq 0xb0(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x36b7c
movq 0x20(%rsp), %rdi
cmpq %r12, %rdi
je 0x265ad
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x4340
movq %r15, 0x290(%rsp)
movq 0x30(%r15), %rsi
leaq 0x238(%rsp), %rdi
leaq 0x20(%rsp), %rdx
callq 0x5346
cvtsi2sd %rbx, %xmm0
movsd %xmm0, 0x288(%rsp)
leaq 0x388(%rsp), %r15
xorl %r13d, %r13d
movl %r13d, (%r15)
movq %r13, 0x8(%r15)
movq %r15, 0x10(%r15)
movq %r15, 0x18(%r15)
movq %r13, 0x20(%r15)
leaq 0x3b8(%rsp), %rax
movl %r13d, (%rax)
movq %r13, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %r13, 0x20(%rax)
movq 0xc8(%rsp), %rbx
movq 0xd0(%rsp), %r14
movl $0xffffffff, 0xc(%rsp)  # imm = 0xFFFFFFFF
leaq 0x150(%rsp), %r12
cmpq %r14, %rbx
je 0x26802
leaq 0x70(%rsp), %rax
movq %rax, 0x60(%rsp)
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
addq %rsi, %rdx
leaq 0x60(%rsp), %rdi
callq 0xda32
movl $0x0, 0x158(%rsp)
movq %r13, 0x160(%rsp)
leaq 0x158(%rsp), %rax
movq %rax, 0x168(%rsp)
movq %rax, 0x170(%rsp)
movq %r13, 0x178(%rsp)
leaq 0x228(%rsp), %rax
movq %rax, 0x218(%rsp)
movq 0x60(%rsp), %rsi
movq 0x68(%rsp), %rdx
addq %rsi, %rdx
leaq 0x218(%rsp), %rdi
callq 0xda32
leaq 0x218(%rsp), %rdi
movq %r12, %rsi
leaq 0x380(%rsp), %rdx
callq 0x27cef
movl %eax, %ebp
movq 0x218(%rsp), %rdi
leaq 0x228(%rsp), %rax
cmpq %rax, %rdi
je 0x266f5
movq 0x228(%rsp), %rsi
incq %rsi
callq 0x4340
testb %bpl, %bpl
je 0x26737
movl 0xc(%rsp), %eax
incl %eax
movl %eax, 0xc(%rsp)
movl %eax, 0x20(%rsp)
leaq 0x28(%rsp), %rdi
movq %r12, %rsi
callq 0xd482
leaq 0x3b0(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x2adf0
leaq 0x28(%rsp), %rdi
callq 0xd8f4
addq $0x20, %rbx
jmp 0x26781
movl $0x38, %edx
movq 0x25885(%rip), %rdi     # 0x4bfc8
leaq 0x17b90(%rip), %rsi     # 0x3e2da
callq 0x43a0
movq 0x25872(%rip), %rcx     # 0x4bfc8
movq (%rcx), %rax
movq -0x18(%rax), %rdi
addq %rcx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq 0x25854(%rip), %rdi     # 0x4bfc8
callq 0x4030
movq %rax, %rdi
callq 0x4220
movq %r12, %rdi
callq 0xd8f4
movq 0x60(%rsp), %rdi
leaq 0x70(%rsp), %rax
cmpq %rax, %rdi
je 0x267a5
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x4340
testb %bpl, %bpl
jne 0x26632
xorl %ebx, %ebx
jmp 0x2774d
movl $0x54, %edx
leaq 0x17ac4(%rip), %rsi     # 0x3e285
movq 0x25800(%rip), %rbx     # 0x4bfc8
movq %rbx, %rdi
callq 0x43a0
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq 0x257da(%rip), %rdi     # 0x4bfc8
callq 0x4030
movq %rax, %rdi
callq 0x4220
xorl %ebx, %ebx
jmp 0x27795
movl $0x0, 0x158(%rsp)
xorl %eax, %eax
movq %rax, 0x160(%rsp)
leaq 0x158(%rsp), %rcx
movq %rcx, 0x168(%rsp)
movq %rcx, 0x170(%rsp)
movq %rax, 0x178(%rsp)
movq 0xc8(%rsp), %r12
movq 0xd0(%rsp), %rax
movl $0xffffffff, 0xc(%rsp)  # imm = 0xFFFFFFFF
movq %rax, 0xf8(%rsp)
cmpq %rax, %r12
je 0x26b25
leaq 0x60(%rsp), %r13
leaq 0x20(%rsp), %rbx
leaq 0x17b08(%rip), %r14     # 0x3e379
movq %r12, 0x58(%rsp)
movl $0x0, 0x68(%rsp)
xorl %ecx, %ecx
movq %rcx, 0x70(%rsp)
leaq 0x68(%rsp), %rax
movq %rax, 0x78(%rsp)
movq %rax, 0x80(%rsp)
movq %rcx, 0x88(%rsp)
incl 0xc(%rsp)
leaq 0x3b0(%rsp), %rdi
leaq 0xc(%rsp), %rsi
callq 0x2a9b4
leaq 0x120(%rsp), %rdi
movq %rax, %rsi
callq 0xd482
movq 0x138(%rsp), %r12
leaq 0x128(%rsp), %rax
cmpq %rax, %r12
je 0x26aca
movl 0x20(%r12), %eax
movl %eax, 0x258(%rsp)
movq 0x390(%rsp), %rdx
movq %r15, %rcx
testq %rdx, %rdx
je 0x26914
movq %r15, %rcx
xorl %esi, %esi
cmpl %eax, 0x20(%rdx)
setl %sil
cmovgeq %rdx, %rcx
movq 0x10(%rdx,%rsi,8), %rdx
testq %rdx, %rdx
jne 0x268fd
movq %r15, %rdx
cmpq %r15, %rcx
je 0x26926
cmpl 0x20(%rcx), %eax
cmovlq %r15, %rcx
movq %rcx, %rdx
cmpq %r15, %rdx
je 0x27826
movq 0x28(%r12), %rbp
leaq 0x380(%rsp), %rdi
leaq 0x258(%rsp), %rsi
callq 0xcf10
cmpq $0x1, %rbp
adcq $0x0, %rbp
movsd (%rax), %xmm0
movsd 0x14783(%rip), %xmm1    # 0x3b0e0
unpcklps %xmm1, %xmm0            # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
movapd 0x14788(%rip), %xmm2    # 0x3b0f0
subpd %xmm2, %xmm0
movapd %xmm0, %xmm3
unpckhpd %xmm0, %xmm3            # xmm3 = xmm3[1],xmm0[1]
addsd %xmm0, %xmm3
movq %rbp, %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
divsd %xmm1, %xmm3
mulsd 0x175bb(%rip), %xmm3    # 0x3df58
movapd %xmm3, 0x10(%rsp)
movslq 0xc(%rsp), %rdi
shlq $0x5, %rdi
addq 0xb0(%rsp), %rdi
movq %r14, %rsi
callq 0x4100
testl %eax, %eax
je 0x26a50
movslq 0xc(%rsp), %rdi
shlq $0x5, %rdi
addq 0xb0(%rsp), %rdi
leaq 0x1520a(%rip), %rsi     # 0x3bbe6
callq 0x4100
testl %eax, %eax
je 0x26a60
movslq 0xc(%rsp), %rdi
shlq $0x5, %rdi
addq 0xb0(%rsp), %rdi
leaq 0x1797e(%rip), %rsi     # 0x3e37b
callq 0x4100
testl %eax, %eax
je 0x26a70
movslq 0xc(%rsp), %rdi
shlq $0x5, %rdi
addq 0xb0(%rsp), %rdi
leaq 0x1795f(%rip), %rsi     # 0x3e37d
callq 0x4100
testl %eax, %eax
je 0x26a80
movslq 0xc(%rsp), %rdi
shlq $0x5, %rdi
addq 0xb0(%rsp), %rdi
leaq 0x17dcc(%rip), %rsi     # 0x3e80b
callq 0x4100
testl %eax, %eax
je 0x26a90
movapd 0x10(%rsp), %xmm0
jmp 0x26a9e
movapd 0x10(%rsp), %xmm0
mulsd 0x17522(%rip), %xmm0    # 0x3df80
jmp 0x26a9e
movapd 0x10(%rsp), %xmm0
mulsd 0x1750a(%rip), %xmm0    # 0x3df78
jmp 0x26a9e
movapd 0x10(%rsp), %xmm0
mulsd 0x174f2(%rip), %xmm0    # 0x3df70
jmp 0x26a9e
movapd 0x10(%rsp), %xmm0
mulsd 0x174da(%rip), %xmm0    # 0x3df68
jmp 0x26a9e
movapd 0x10(%rsp), %xmm0
mulsd 0x174c2(%rip), %xmm0    # 0x3df60
movl 0x258(%rsp), %eax
movl %eax, 0x20(%rsp)
movsd %xmm0, 0x28(%rsp)
movq %r13, %rdi
movq %rbx, %rsi
callq 0x2b14e
movq %r12, %rdi
callq 0x4230
movq %rax, %r12
jmp 0x268cd
movl 0xc(%rsp), %eax
movl %eax, 0x20(%rsp)
leaq 0x28(%rsp), %rdi
movq %r13, %rsi
callq 0x2aba8
movq 0x58(%rsp), %r12
leaq 0x150(%rsp), %rdi
movq %rbx, %rsi
callq 0x2b298
leaq 0x28(%rsp), %rdi
callq 0x2ab58
addq $0x20, %r12
leaq 0x120(%rsp), %rdi
callq 0xd8f4
movq %r13, %rdi
callq 0x2ab58
cmpq 0xf8(%rsp), %r12
jne 0x26871
movq 0xc8(%rsp), %r15
movq 0xd0(%rsp), %rax
movl $0xffffffff, 0xc(%rsp)  # imm = 0xFFFFFFFF
movq %rax, 0x58(%rsp)
cmpq %rax, %r15
je 0x26dd3
leaq 0xc(%rsp), %r12
leaq 0x20(%rsp), %r13
leaq 0x380(%rsp), %rbx
leaq 0x120(%rsp), %r14
leaq 0x18206(%rip), %rbp     # 0x3ed72
incl 0xc(%rsp)
leaq 0x3b0(%rsp), %rdi
movq %r12, %rsi
callq 0x2a9b4
movq %r13, %rdi
movq %rax, %rsi
callq 0xd482
leaq 0x150(%rsp), %rdi
movq %r12, %rsi
callq 0x2aa18
leaq 0x60(%rsp), %rdi
movq %rax, %rsi
callq 0x2aba8
movq %r15, 0x10(%rsp)
movl $0xf, %edx
movq 0x2540f(%rip), %rdi     # 0x4bfc8
leaq 0x177bf(%rip), %rsi     # 0x3e37f
callq 0x43a0
movslq 0xc(%rsp), %rax
movq 0xc8(%rsp), %rcx
shlq $0x5, %rax
movq (%rcx,%rax), %rsi
movq 0x8(%rcx,%rax), %rdx
movq 0x253e2(%rip), %rdi     # 0x4bfc8
callq 0x43a0
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %r15, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %r15, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
movslq 0xc(%rsp), %rdi
shlq $0x5, %rdi
addq 0xb0(%rsp), %rdi
leaq 0x17724(%rip), %rsi     # 0x3e37b
callq 0x4100
testl %eax, %eax
jne 0x26caa
movl $0x4f, %edx
movq 0x2535c(%rip), %rdi     # 0x4bfc8
leaq 0x1771c(%rip), %rsi     # 0x3e38f
callq 0x43a0
movq 0x25349(%rip), %rcx     # 0x4bfc8
movq (%rcx), %rax
movq -0x18(%rax), %rdi
addq %rcx, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq 0x2532b(%rip), %rdi     # 0x4bfc8
callq 0x4030
movq %rax, %rdi
callq 0x4220
movq 0x78(%rsp), %r12
leaq 0x68(%rsp), %rax
cmpq %rax, %r12
je 0x26da8
movl 0x20(%r12), %eax
movl %eax, 0x120(%rsp)
movl $0x6, %edx
movq 0x252f3(%rip), %rdi     # 0x4bfc8
leaq 0x156ab(%rip), %rsi     # 0x3c387
callq 0x43a0
movl 0x20(%r12), %esi
movq 0x252db(%rip), %rdi     # 0x4bfc8
callq 0x4580
movq %rax, %r15
movl $0x1, %edx
movq %rax, %rdi
leaq 0x17e1d(%rip), %rsi     # 0x3eb21
callq 0x43a0
movsd 0x28(%r12), %xmm0
movq %r15, %rdi
callq 0x4510
movq %rax, %r15
movl $0x6, %edx
movq %rax, %rdi
leaq 0x178bc(%rip), %rsi     # 0x3e5e6
callq 0x43a0
movq %rbx, %rdi
movq %r14, %rsi
callq 0xcf10
movq (%rax), %rsi
movq %r15, %rdi
callq 0x4210
movq %rax, %r15
movl $0x1, %edx
movq %rax, %rdi
movq %rbp, %rsi
callq 0x43a0
movq %r13, %rdi
movq %r14, %rsi
callq 0xcf10
movq (%rax), %rsi
movq %r15, %rdi
callq 0x4210
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x4310
movsbl %al, %esi
movq %r15, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x4220
movq %r12, %rdi
callq 0x4230
movq %rax, %r12
jmp 0x26caf
movq 0x10(%rsp), %r15
addq $0x20, %r15
leaq 0x60(%rsp), %rdi
callq 0x2ab58
movq %r13, %rdi
callq 0xd8f4
cmpq 0x58(%rsp), %r15
leaq 0xc(%rsp), %r12
jne 0x26b6c
movq 0x290(%rsp), %rax
movq 0x20(%rax), %rsi
leaq 0x20(%rsp), %rdi
leaq 0x60(%rsp), %rdx
callq 0x5346
leaq 0x120(%rsp), %rdx
movb $0x2c, (%rdx)
leaq 0x328(%rsp), %rdi
leaq 0x20(%rsp), %rsi
leaq 0x30(%rsp), %rbx
callq 0x36b7c
movq 0x20(%rsp), %rdi
cmpq %rbx, %rdi
je 0x26e27
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x4340
xorpd %xmm0, %xmm0
movapd %xmm0, 0xe0(%rsp)
movq $0x0, 0xf0(%rsp)
movq 0x328(%rsp), %r15
movq 0x330(%rsp), %r12
movsd 0x17130(%rip), %xmm0    # 0x3df88
cmpq %r12, %r15
je 0x26ec8
movsd %xmm0, 0x10(%rsp)
leaq 0xe0(%rsp), %rbx
leaq 0x20(%rsp), %r14
movq (%r15), %rdi
callq 0x43f0
movsd %xmm0, 0x20(%rsp)
movq 0xe8(%rsp), %rsi
cmpq 0xf0(%rsp), %rsi
je 0x26ea2
movsd %xmm0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0xe8(%rsp)
jmp 0x26ead
movq %rbx, %rdi
movq %r14, %rdx
callq 0x2b596
movsd 0x20(%rsp), %xmm0
minsd 0x10(%rsp), %xmm0
addq $0x20, %r15
movsd %xmm0, 0x10(%rsp)
cmpq %r12, %r15
jne 0x26e70
movq 0xe0(%rsp), %rax
movq 0xe8(%rsp), %rcx
cmpq %rcx, %rax
je 0x26f0a
movsd 0x170a3(%rip), %xmm1    # 0x3df88
movsd (%rax), %xmm2
movapd %xmm2, %xmm3
subsd %xmm0, %xmm3
divsd %xmm2, %xmm3
movapd %xmm1, %xmm2
subsd %xmm3, %xmm2
movsd %xmm2, (%rax)
addq $0x8, %rax
cmpq %rcx, %rax
jne 0x26ee5
movq 0x1a0(%rsp), %rax
movq %rax, 0x58(%rsp)
movq 0x1a8(%rsp), %rax
movq %rax, 0xf8(%rsp)
leaq 0xc(%rsp), %rax
movl $0xffffffff, (%rax)     # imm = 0xFFFFFFFF
leaq 0x1e8(%rsp), %r14
leaq 0x1c8(%rsp), %r13
xorl %r12d, %r12d
leaq 0x90(%rsp), %r15
movq 0x58(%rsp), %rax
cmpq 0xf8(%rsp), %rax
sete %bl
je 0x276aa
movslq 0xc(%rsp), %rax
leaq 0x1(%rax), %rdi
movl %edi, 0xc(%rsp)
movq 0xe0(%rsp), %rcx
movsd 0x8(%rcx,%rax,8), %xmm0
movsd %xmm0, 0x10(%rsp)
shlq $0x5, %rdi
addq 0xb0(%rsp), %rdi
leaq 0x173e2(%rip), %rsi     # 0x3e379
callq 0x4100
testl %eax, %eax
je 0x2704c
movslq 0xc(%rsp), %rdi
shlq $0x5, %rdi
addq 0xb0(%rsp), %rdi
leaq 0x14c2a(%rip), %rsi     # 0x3bbe6
callq 0x4100
testl %eax, %eax
je 0x27064
movslq 0xc(%rsp), %rdi
shlq $0x5, %rdi
addq 0xb0(%rsp), %rdi
leaq 0x1739a(%rip), %rsi     # 0x3e37b
callq 0x4100
testl %eax, %eax
je 0x2702c
movslq 0xc(%rsp), %rdi
shlq $0x5, %rdi
addq 0xb0(%rsp), %rdi
leaq 0x1737b(%rip), %rsi     # 0x3e37d
callq 0x4100
testl %eax, %eax
je 0x27078
movslq 0xc(%rsp), %rdi
shlq $0x5, %rdi
addq 0xb0(%rsp), %rdi
leaq 0x177e8(%rip), %rsi     # 0x3e80b
callq 0x4100
testl %eax, %eax
jne 0x27078
movsd 0x10(%rsp), %xmm0
mulsd 0x16f56(%rip), %xmm0    # 0x3df90
mulsd 0x16f56(%rip), %xmm0    # 0x3df98
divsd 0x16f56(%rip), %xmm0    # 0x3dfa0
jmp 0x27072
movsd 0x10(%rsp), %xmm0
mulsd 0x16f56(%rip), %xmm0    # 0x3dfb0
mulsd 0x16f56(%rip), %xmm0    # 0x3dfb8
jmp 0x27072
movsd 0x10(%rsp), %xmm0
mulsd 0x16f36(%rip), %xmm0    # 0x3dfa8
movsd %xmm0, 0x10(%rsp)
movslq 0xc(%rsp), %rax
movq 0x1a0(%rsp), %rcx
shlq $0x5, %rax
leaq 0x190(%rsp), %rdx
movq %rdx, 0x180(%rsp)
movq (%rcx,%rax), %rsi
movq 0x8(%rcx,%rax), %rdx
addq %rsi, %rdx
leaq 0x180(%rsp), %rdi
callq 0xda32
movslq 0xc(%rsp), %rax
movq 0xb0(%rsp), %rcx
shlq $0x5, %rax
leaq 0x110(%rsp), %rdx
movq %rdx, 0x100(%rsp)
movq (%rcx,%rax), %rsi
movq 0x8(%rcx,%rax), %rdx
addq %rsi, %rdx
leaq 0x100(%rsp), %rdi
callq 0xda32
leaq 0x150(%rsp), %rdi
leaq 0xc(%rsp), %rsi
callq 0x2aa18
leaq 0x20(%rsp), %rdi
movq %rax, %rsi
callq 0x2aba8
movl %r12d, 0x68(%rsp)
movq %r12, 0x70(%rsp)
leaq 0x68(%rsp), %rax
movq %rax, 0x78(%rsp)
movq %rax, 0x80(%rsp)
movq %r12, 0x88(%rsp)
movl %r12d, 0x128(%rsp)
movq %r12, 0x130(%rsp)
leaq 0x128(%rsp), %rax
movq %rax, 0x138(%rsp)
movq %rax, 0x140(%rsp)
movq %r12, 0x148(%rsp)
movl %r12d, 0x260(%rsp)
movq %r12, 0x268(%rsp)
leaq 0x260(%rsp), %rax
movq %rax, 0x270(%rsp)
movq %rax, 0x278(%rsp)
movq %r12, 0x280(%rsp)
movl %r12d, 0x300(%rsp)
movq %r12, 0x308(%rsp)
leaq 0x300(%rsp), %rax
movq %rax, 0x310(%rsp)
movq %rax, 0x318(%rsp)
movq %r12, 0x320(%rsp)
movl %r12d, 0x2d0(%rsp)
movq %r12, 0x2d8(%rsp)
leaq 0x2d0(%rsp), %rax
movq %rax, 0x2e0(%rsp)
movq %rax, 0x2e8(%rsp)
movq %r12, 0x2f0(%rsp)
movl %r12d, 0x2a0(%rsp)
movq %r12, 0x2a8(%rsp)
leaq 0x2a0(%rsp), %rax
movq %rax, 0x2b0(%rsp)
movq %rax, 0x2b8(%rsp)
movq %r12, 0x2c0(%rsp)
leaq 0x180(%rsp), %rdi
leaq 0x171b1(%rip), %rsi     # 0x3e3df
callq 0x4100
testl %eax, %eax
je 0x275f3
leaq 0x208(%rsp), %rax
movq %rax, 0x1f8(%rsp)
movq 0x180(%rsp), %rsi
movq 0x188(%rsp), %rdx
addq %rsi, %rdx
leaq 0x1f8(%rsp), %rdi
callq 0xda32
leaq 0xa0(%rsp), %rax
movq %rax, 0x90(%rsp)
movq 0x238(%rsp), %rsi
movq 0x240(%rsp), %rdx
addq %rsi, %rdx
movq %r15, %rbp
movq %r15, %rdi
callq 0xda32
movq %rbp, %rdi
leaq 0x14834(%rip), %rsi     # 0x3bad7
callq 0x45e0
movq 0x100(%rsp), %rsi
movq 0x108(%rsp), %rdx
movq %rbp, %rdi
callq 0x4120
movq %r14, 0x1d8(%rsp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
leaq 0x688(%rsp), %rbp
je 0x272f4
movq %rdx, 0x1d8(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x1e8(%rsp)
jmp 0x272fd
movupd (%rcx), %xmm0
movupd %xmm0, (%r14)
movq 0x8(%rax), %rdx
movq %rdx, 0x1e0(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq %rbp, %rdi
leaq 0x20(%rsp), %rsi
callq 0x2aba8
subq $0x8, %rsp
leaq 0x200(%rsp), %rdi
movsd 0x18(%rsp), %xmm0
leaq 0x1e0(%rsp), %rsi
movq %rbp, %rdx
leaq 0x68(%rsp), %rcx
leaq 0x128(%rsp), %r8
leaq 0x260(%rsp), %r9
leaq 0x2a0(%rsp), %rax
pushq %rax
leaq 0x2d8(%rsp), %rax
pushq %rax
leaq 0x310(%rsp), %rax
pushq %rax
callq 0x280ee
addq $0x20, %rsp
movq %rbp, %rdi
movl %eax, %ebp
callq 0x2ab58
movq 0x1d8(%rsp), %rdi
cmpq %r14, %rdi
je 0x273a2
movq 0x1e8(%rsp), %rsi
incq %rsi
callq 0x4340
movq 0x90(%rsp), %rdi
leaq 0xa0(%rsp), %rax
cmpq %rax, %rdi
je 0x273c7
movq 0xa0(%rsp), %rsi
incq %rsi
callq 0x4340
movq 0x1f8(%rsp), %rdi
leaq 0x208(%rsp), %rax
cmpq %rax, %rdi
je 0x273ec
movq 0x208(%rsp), %rsi
incq %rsi
callq 0x4340
testb %bpl, %bpl
je 0x275fe
leaq 0x4d0(%rsp), %rdi
leaq 0x60(%rsp), %rsi
callq 0xd1f6
leaq 0x4a0(%rsp), %rdi
leaq 0x120(%rsp), %rsi
callq 0xd482
leaq 0x470(%rsp), %rdi
leaq 0x258(%rsp), %rsi
callq 0xd482
leaq 0x440(%rsp), %rdi
leaq 0x2f8(%rsp), %rsi
callq 0xd482
leaq 0x410(%rsp), %rdi
leaq 0x2c8(%rsp), %rsi
callq 0xd482
leaq 0x3e0(%rsp), %rdi
leaq 0x298(%rsp), %rsi
callq 0xd656
leaq 0xa0(%rsp), %rax
movq %rax, 0x90(%rsp)
movq 0x238(%rsp), %rsi
movq 0x240(%rsp), %rdx
addq %rsi, %rdx
movq %r15, %rbp
movq %r15, %rdi
callq 0xda32
movq %rbp, %rdi
leaq 0x1462f(%rip), %rsi     # 0x3bad7
callq 0x45e0
movq 0x100(%rsp), %rsi
movq 0x108(%rsp), %rdx
movq %rbp, %rdi
callq 0x4120
movq %r13, 0x1b8(%rsp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x274f1
movq %rdx, 0x1b8(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x1c8(%rsp)
jmp 0x274fb
movupd (%rcx), %xmm0
movupd %xmm0, (%r13)
movq 0x8(%rax), %rdx
movq %rdx, 0x1c0(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
subq $0x8, %rsp
leaq 0x4d8(%rsp), %rdi
leaq 0x4a8(%rsp), %rsi
leaq 0x478(%rsp), %rdx
leaq 0x448(%rsp), %rcx
leaq 0x418(%rsp), %r8
leaq 0x3e8(%rsp), %r9
leaq 0x1c0(%rsp), %rax
pushq %rax
callq 0x29891
addq $0x10, %rsp
movl %eax, %ebp
movq 0x1b8(%rsp), %rdi
cmpq %r13, %rdi
je 0x2757b
movq 0x1c8(%rsp), %rsi
incq %rsi
callq 0x4340
movq 0x90(%rsp), %rdi
leaq 0xa0(%rsp), %rax
cmpq %rax, %rdi
je 0x275a0
movq 0xa0(%rsp), %rsi
incq %rsi
callq 0x4340
leaq 0x3e0(%rsp), %rdi
callq 0xd8e0
leaq 0x410(%rsp), %rdi
callq 0xd8f4
leaq 0x440(%rsp), %rdi
callq 0xd8f4
leaq 0x470(%rsp), %rdi
callq 0xd8f4
leaq 0x4a0(%rsp), %rdi
callq 0xd8f4
leaq 0x4d0(%rsp), %rdi
callq 0xd908
testb %bpl, %bpl
je 0x275fe
addq $0x20, 0x58(%rsp)
movb $0x1, %bpl
jmp 0x27600
xorl %ebp, %ebp
leaq 0x298(%rsp), %rdi
callq 0xd8e0
leaq 0x2c8(%rsp), %rdi
callq 0xd8f4
leaq 0x2f8(%rsp), %rdi
callq 0xd8f4
leaq 0x258(%rsp), %rdi
callq 0xd8f4
leaq 0x120(%rsp), %rdi
callq 0xd8f4
leaq 0x60(%rsp), %rdi
callq 0xd908
leaq 0x20(%rsp), %rdi
callq 0x2ab58
movq 0x100(%rsp), %rdi
leaq 0x110(%rsp), %rax
cmpq %rax, %rdi
je 0x2767a
movq 0x110(%rsp), %rsi
incq %rsi
callq 0x4340
movq 0x180(%rsp), %rdi
leaq 0x190(%rsp), %rax
cmpq %rax, %rdi
je 0x2769f
movq 0x190(%rsp), %rsi
incq %rsi
callq 0x4340
testb %bpl, %bpl
jne 0x26f4d
jmp 0x27716
callq 0x4200
movq %rax, %r14
movq 0x2490f(%rip), %rdi     # 0x4bfc8
leaq 0x12c85(%rip), %rsi     # 0x3a345
movl $0x12, %edx
callq 0x43a0
xorps %xmm0, %xmm0
cvtsi2sd %r14, %xmm0
subsd 0x288(%rsp), %xmm0
divsd 0x12925(%rip), %xmm0    # 0x3a008
movq 0x248de(%rip), %rdi     # 0x4bfc8
callq 0x4510
movq %rax, %r14
leaq 0x12c5f(%rip), %rsi     # 0x3a358
movl $0x8, %edx
movq %rax, %rdi
callq 0x43a0
movq %r14, %rdi
callq 0x41a0
movq %rax, %rdi
callq 0x41a0
movq 0xe0(%rsp), %rdi
testq %rdi, %rdi
je 0x27733
movq 0xf0(%rsp), %rsi
subq %rdi, %rsi
callq 0x4340
leaq 0x328(%rsp), %rdi
callq 0x6aa2
leaq 0x150(%rsp), %rdi
callq 0x2ad40
leaq 0x3b0(%rsp), %rdi
callq 0x2ad98
leaq 0x380(%rsp), %rdi
callq 0xd8f4
leaq 0x248(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x27788
movq 0x248(%rsp), %rsi
incq %rsi
callq 0x4340
leaq 0xb0(%rsp), %rdi
callq 0x6aa2
leaq 0x1a0(%rsp), %rdi
callq 0x6aa2
leaq 0x350(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x277c3
movq 0x350(%rsp), %rsi
incq %rsi
callq 0x4340
leaq 0xc8(%rsp), %rdi
callq 0x6aa2
leaq 0x370(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x277f1
movq 0x370(%rsp), %rsi
incq %rsi
callq 0x4340
movq 0x247a0(%rip), %rsi     # 0x4bf98
leaq 0x500(%rsp), %rdi
callq 0x4260
leaq 0x580(%rsp), %rdi
callq 0x4140
movl %ebx, %eax
addq $0x6b8, %rsp            # imm = 0x6B8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x16ae6(%rip), %rdi     # 0x3e313
leaq 0x16b0e(%rip), %rsi     # 0x3e342
leaq 0x16b1b(%rip), %rcx     # 0x3e356
movl $0xa1, %edx
callq 0x41f0
movq %rax, %r15
movq 0x20(%rsp), %rdi
cmpq %rbx, %rdi
je 0x27c15
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x4340
jmp 0x27c15
jmp 0x27b74
movq %rax, %r15
jmp 0x27c5d
movq %rax, %r15
movq 0x20(%rsp), %rdi
cmpq %r12, %rdi
je 0x27c6a
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x4340
jmp 0x27c6a
jmp 0x27aa8
jmp 0x27a77
movq %rax, %r15
movq 0x1b8(%rsp), %rdi
cmpq %r13, %rdi
je 0x278c9
movq 0x1c8(%rsp), %rsi
incq %rsi
callq 0x4340
jmp 0x278c9
jmp 0x278c6
movq %rax, %r15
movq 0x90(%rsp), %rdi
leaq 0xa0(%rsp), %rax
cmpq %rax, %rdi
je 0x278f3
movq 0xa0(%rsp), %rsi
incq %rsi
callq 0x4340
jmp 0x278f3
movq %rax, %r15
leaq 0x3e0(%rsp), %rdi
callq 0xd8e0
jmp 0x27905
movq %rax, %r15
leaq 0x410(%rsp), %rdi
callq 0xd8f4
leaq 0x440(%rsp), %rdi
callq 0xd8f4
leaq 0x470(%rsp), %rdi
callq 0xd8f4
leaq 0x4a0(%rsp), %rdi
callq 0xd8f4
leaq 0x4d0(%rsp), %rdi
callq 0xd908
jmp 0x279fe
movq %rax, %r15
jmp 0x27912
movq %rax, %r15
jmp 0x2791f
movq %rax, %r15
jmp 0x2792c
movq %rax, %r15
jmp 0x27939
jmp 0x27a77
movq %rax, %r15
jmp 0x27c77
jmp 0x27b65
jmp 0x27973
movq %rax, %r15
jmp 0x279af
movq %rax, %r15
jmp 0x279d4
movq %rax, %r15
leaq 0x688(%rsp), %rdi
callq 0x2ab58
jmp 0x27992
movq %rax, %r15
movq 0x1d8(%rsp), %rdi
cmpq %r14, %rdi
je 0x279af
movq 0x1e8(%rsp), %rsi
incq %rsi
callq 0x4340
movq 0x90(%rsp), %rdi
leaq 0xa0(%rsp), %rax
cmpq %rax, %rdi
je 0x279d4
movq 0xa0(%rsp), %rsi
incq %rsi
callq 0x4340
movq 0x1f8(%rsp), %rdi
leaq 0x208(%rsp), %rax
cmpq %rax, %rdi
je 0x279fe
movq 0x208(%rsp), %rsi
incq %rsi
callq 0x4340
jmp 0x279fe
movq %rax, %r15
leaq 0x298(%rsp), %rdi
callq 0xd8e0
leaq 0x2c8(%rsp), %rdi
callq 0xd8f4
leaq 0x2f8(%rsp), %rdi
callq 0xd8f4
leaq 0x258(%rsp), %rdi
callq 0xd8f4
leaq 0x120(%rsp), %rdi
callq 0xd8f4
leaq 0x60(%rsp), %rdi
callq 0xd908
leaq 0x20(%rsp), %rdi
callq 0x2ab58
jmp 0x27aec
movq %rax, %r15
leaq 0x28(%rsp), %rdi
callq 0xd8f4
jmp 0x27ba7
jmp 0x27ba4
movq %rax, %r15
jmp 0x27b11
movq %rax, %r15
jmp 0x27b36
jmp 0x27bf6
movq %rax, %r15
jmp 0x27ca5
jmp 0x27bf6
movq %rax, %r15
leaq 0x28(%rsp), %rdi
callq 0x2ab58
jmp 0x27bdd
jmp 0x27bda
movq %rax, %r15
jmp 0x27c6a
movq %rax, %r15
jmp 0x27c22
movq %rax, %r15
movq 0x218(%rsp), %rdi
leaq 0x228(%rsp), %rax
cmpq %rax, %rdi
je 0x27ba7
movq 0x228(%rsp), %rsi
incq %rsi
callq 0x4340
jmp 0x27ba7
movq %rax, %r15
movq 0x100(%rsp), %rdi
leaq 0x110(%rsp), %rax
cmpq %rax, %rdi
je 0x27b11
movq 0x110(%rsp), %rsi
incq %rsi
callq 0x4340
movq 0x180(%rsp), %rdi
leaq 0x190(%rsp), %rax
cmpq %rax, %rdi
je 0x27b36
movq 0x190(%rsp), %rsi
incq %rsi
callq 0x4340
movq 0xe0(%rsp), %rdi
testq %rdi, %rdi
je 0x27b53
movq 0xf0(%rsp), %rsi
subq %rdi, %rsi
callq 0x4340
leaq 0x328(%rsp), %rdi
callq 0x6aa2
jmp 0x27c15
movq %rax, %r15
jmp 0x27c98
jmp 0x27b89
jmp 0x27bf6
movq %rax, %r15
jmp 0x27c15
movq %rax, %r15
jmp 0x27c0b
movq %rax, %r15
jmp 0x27bea
movq %rax, %r15
movq 0x20(%rsp), %rdi
cmpq %r12, %rdi
je 0x27cc6
movq 0x30(%rsp), %rsi
jmp 0x27cbe
movq %rax, %r15
leaq 0x150(%rsp), %rdi
callq 0xd8f4
movq 0x60(%rsp), %rdi
leaq 0x70(%rsp), %rax
cmpq %rax, %rdi
je 0x27c22
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x4340
jmp 0x27c22
jmp 0x27bf6
jmp 0x27bf6
jmp 0x27bfe
jmp 0x27bda
movq %rax, %r15
leaq 0x120(%rsp), %rdi
callq 0xd8f4
leaq 0x60(%rsp), %rdi
callq 0x2ab58
jmp 0x27c15
movq %rax, %r15
jmp 0x27cc6
movq %rax, %r15
leaq 0x60(%rsp), %rdi
callq 0x2ab58
leaq 0x20(%rsp), %rdi
callq 0xd8f4
leaq 0x150(%rsp), %rdi
callq 0x2ad40
leaq 0x3b0(%rsp), %rdi
callq 0x2ad98
leaq 0x380(%rsp), %rdi
callq 0xd8f4
leaq 0x248(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x27c5d
movq 0x248(%rsp), %rsi
incq %rsi
callq 0x4340
leaq 0xb0(%rsp), %rdi
callq 0x6aa2
leaq 0x1a0(%rsp), %rdi
callq 0x6aa2
leaq 0x350(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x27c98
movq 0x350(%rsp), %rsi
incq %rsi
callq 0x4340
leaq 0xc8(%rsp), %rdi
callq 0x6aa2
leaq 0x370(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x27cc6
movq 0x370(%rsp), %rsi
incq %rsi
callq 0x4340
movq 0x242cb(%rip), %rsi     # 0x4bf98
leaq 0x500(%rsp), %rdi
callq 0x4260
leaq 0x580(%rsp), %rdi
callq 0x4140
movq %r15, %rdi
callq 0x45a0