// File: schneebergerlab[P]GameteBinning/asPollinator_1.0.cpp
// Function: get_options(int, char**, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>*, bool*, double*, double*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*)
bool get_options(int                  argc, 
                 char*                argv[],
                 string*              filemark,
                 string*              filesize,
                 vector<string>*      filepoll,
                 bool*                correction,
                 double*              lodcutoff,
                 double*              minCOscore,
                 string*              outprefix)
{
    int  ic;
    bool markf   = false;
    bool pollf   = false;
    int  pollnum = 0; // number of pollen files given
    // log cmdline
    cout << "   CMDline: ";
    ic = 0;
    while(ic < argc)
    {
        cout << argv[ic] << " ";
        ic ++;
    }
    cout << endl;
    // get values
    ic = 1;    
    while (ic < argc) 
    {
        string optstr = (string)argv[ic];
        if(optstr.compare("--marker") == 0)
        {
            ic ++;
            *filemark = (string)argv[ic];
            ifstream fp;
            fp.open((*filemark).c_str(), ios::in);
            if(fp.good())
            {
                fp.close();
                cout << "   Info: marker file provided: "    << *filemark << endl;
            }
            else
            {
                cout << "   Error: cannot open marker file " << *filemark << endl;
                return false;
            }
        }
        else
        if(optstr.compare("--corr") == 0)
        {
            *correction = true;
            cout << "   Info: correcting markers asked. " << endl;
        }
        else
        if(optstr.compare("--lod") == 0)
        {
            ic ++;
            *lodcutoff = atof(argv[ic]);
            cout << "   Info: lod cutoff provided to build conections: " << *lodcutoff << endl;
        } 
        else
        if(optstr.compare("--ims") == 0)
        {
            ic ++;
            *minCOscore = (double)atof(argv[ic]);
            if(*minCOscore>=0.5)
            {
                cout << "   Info: minimum score of candidate co events provided: "   << *minCOscore << endl;
            }
            else
            {
                cout << "   Error: minimum score of candidate co events too small: " << *minCOscore << endl;
                return false;
            }
        }                
        else       
        if(optstr.compare("--pollen") == 0)
        {
            ic ++;
            cout << "   Info: list of pollen variant files provided: "    << argv[ic] << endl;            
            ifstream fp;
            fp.open(argv[ic], ios::in);
            if(fp.good())
            {
                while(fp.good())
                {
                    string line("");
                    getline(fp, line);
                    if(line.size()==0 || line[0]=='#') continue;
                    pollnum ++;
                    ifstream ithfp;
                    ithfp.open(line.c_str(), ios::in);                    
                    if(ithfp.good())
                    {
                        (*filepoll).push_back(line);
                        ithfp.close();
                    }else
                    {
                        cout << "   Error: cannot open " << pollnum  << "th "  << "pollen file "  << line    << endl;
                    }                  
                }
                fp.close();
                cout << "   Info: No. pollen file collected/provided: " << (*filepoll).size() << "/" << pollnum << endl;
            }
            else
            {
                cout << "   Error: cannot open pollen-sample list file " << argv[ic] << endl;
                return false;
            }
        }
        else       
        if(optstr.compare("--size") == 0)
        {
            ic ++;
            ifstream fp;
            *filesize = (string)argv[ic];
            fp.open(argv[ic], ios::in);
            if(fp.good())
            {
                cout << "   Info: contig size file provided: "    << argv[ic] << endl;            
            }
            else
            {
                cout << "   Error: contig size file not found: "  << argv[ic] << endl;            
                return false;
            }
            fp.close();
        }        
        else
        if(optstr.compare("-o") == 0)
        {
            ic ++;
            *outprefix = (string)argv[ic];
            cout << "   Info: output files will be labeled with \""    << *outprefix << "\"" << endl;
        }        
        else
        {
            cout << "   Warning: option " << argv[ic] << " was not recognized and ignored."  << endl;
        }
        // next option
        ic ++;
    }
    // check necessary files
    return true;
}

// Assembly:
subq $0xad8, %rsp            # imm = 0xAD8
movq 0xaf0(%rsp), %rax
movq 0xae8(%rsp), %rax
movq 0xae0(%rsp), %rax
movl %edi, 0xad0(%rsp)
movq %rsi, 0xac8(%rsp)
movq %rdx, 0xac0(%rsp)
movq %rcx, 0xab8(%rsp)
movq %r8, 0xab0(%rsp)
movq %r9, 0xaa8(%rsp)
movb $0x0, 0xaa3(%rsp)
movb $0x0, 0xaa2(%rsp)
movl $0x0, 0xa9c(%rsp)
movq 0x2d9d8(%rip), %rdi     # 0x38fd8
leaq 0x20cd5(%rip), %rsi     # 0x2c2dc
callq 0x3320
movl $0x0, 0xaa4(%rsp)
movl 0xaa4(%rsp), %eax
cmpl 0xad0(%rsp), %eax
jge 0xb669
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
movq 0x2d996(%rip), %rdi     # 0x38fd8
callq 0x3320
movq %rax, %rdi
leaq 0x20579(%rip), %rsi     # 0x2bbca
callq 0x3320
movl 0xaa4(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xaa4(%rsp)
jmp 0xb617
movq 0x2d968(%rip), %rdi     # 0x38fd8
movq 0x2d951(%rip), %rsi     # 0x38fc8
callq 0x3370
movl $0x1, 0xaa4(%rsp)
movl 0xaa4(%rsp), %eax
cmpl 0xad0(%rsp), %eax
jge 0xc55a
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, 0x188(%rsp)
leaq 0xa77(%rsp), %rdi
movq %rdi, 0x190(%rsp)
callq 0x3570
movq 0x188(%rsp), %rsi
movq 0x190(%rsp), %rdx
leaq 0xa78(%rsp), %rdi
callq 0x185e0
jmp 0xb6eb
leaq 0xa77(%rsp), %rdi
callq 0x3390
leaq 0xa78(%rsp), %rdi
leaq 0x20be2(%rip), %rsi     # 0x2c2e9
callq 0x3100
cmpl $0x0, %eax
jne 0xb997
movl 0xaa4(%rsp), %eax
incl %eax
movl %eax, 0xaa4(%rsp)
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, 0x178(%rsp)
leaq 0xa3f(%rsp), %rdi
movq %rdi, 0x180(%rsp)
callq 0x3570
movq 0x178(%rsp), %rsi
movq 0x180(%rsp), %rdx
leaq 0xa40(%rsp), %rdi
callq 0x185e0
jmp 0xb775
movq 0xac0(%rsp), %rdi
leaq 0xa40(%rsp), %rsi
movq %rsi, 0x170(%rsp)
callq 0x33f0
movq 0x170(%rsp), %rdi
callq 0x31e0
leaq 0xa3f(%rsp), %rdi
callq 0x3390
leaq 0x830(%rsp), %rdi
callq 0x33c0
jmp 0xb7bb
movq 0xac0(%rsp), %rdi
callq 0x3150
movq %rax, %rsi
leaq 0x830(%rsp), %rdi
movl $0x8, %edx
callq 0x3200
jmp 0xb7df
movq 0x830(%rsp), %rax
movq -0x18(%rax), %rax
leaq 0x830(%rsp,%rax), %rdi
callq 0x3520
movb %al, 0x16f(%rsp)
jmp 0xb801
movb 0x16f(%rsp), %al
testb $0x1, %al
jne 0xb811
jmp 0xb902
leaq 0x830(%rsp), %rdi
callq 0x30b0
jmp 0xb820
movq 0x2d7b1(%rip), %rdi     # 0x38fd8
leaq 0x20ac4(%rip), %rsi     # 0x2c2f2
callq 0x3320
movq %rax, 0x160(%rsp)
jmp 0xb83d
movq 0x160(%rsp), %rdi
movq 0xac0(%rsp), %rsi
callq 0x32e0
movq %rax, 0x158(%rsp)
jmp 0xb85c
movq 0x158(%rsp), %rdi
movq 0x2d75d(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xb872
jmp 0xb969
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa68(%rsp)
movl %eax, 0xa64(%rsp)
leaq 0xa77(%rsp), %rdi
callq 0x3390
jmp 0xc573
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa68(%rsp)
movl %eax, 0xa64(%rsp)
leaq 0xa3f(%rsp), %rdi
callq 0x3390
jmp 0xc54b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa68(%rsp)
movl %eax, 0xa64(%rsp)
jmp 0xc54b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa68(%rsp)
movl %eax, 0xa64(%rsp)
leaq 0x830(%rsp), %rdi
callq 0x30e0
jmp 0xc54b
movq 0x2d6cf(%rip), %rdi     # 0x38fd8
leaq 0x1fa56(%rip), %rsi     # 0x2b366
callq 0x3320
movq %rax, 0x150(%rsp)
jmp 0xb91f
movq 0x150(%rsp), %rdi
movq 0xac0(%rsp), %rsi
callq 0x32e0
movq %rax, 0x148(%rsp)
jmp 0xb93e
movq 0x148(%rsp), %rdi
movq 0x2d67b(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xb954
movb $0x0, 0xad7(%rsp)
movl $0x1, 0x82c(%rsp)
jmp 0xb974
movl $0x0, 0x82c(%rsp)
leaq 0x830(%rsp), %rdi
callq 0x30e0
movl 0x82c(%rsp), %eax
testl %eax, %eax
jne 0xc52a
jmp 0xb992
jmp 0xc50e
leaq 0xa78(%rsp), %rdi
leaq 0x2096c(%rip), %rsi     # 0x2c312
callq 0x3100
cmpl $0x0, %eax
jne 0xb9f3
movq 0xaa8(%rsp), %rax
movb $0x1, (%rax)
movq 0x2d616(%rip), %rdi     # 0x38fd8
leaq 0x20950(%rip), %rsi     # 0x2c319
callq 0x3320
movq %rax, 0x140(%rsp)
jmp 0xb9d8
movq 0x140(%rsp), %rdi
movq 0x2d5e1(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xb9ee
jmp 0xc50c
leaq 0xa78(%rsp), %rdi
leaq 0x2093b(%rip), %rsi     # 0x2c33d
callq 0x3100
cmpl $0x0, %eax
jne 0xbaa0
movl 0xaa4(%rsp), %eax
incl %eax
movl %eax, 0xaa4(%rsp)
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rdi
callq 0x3410
movq 0xae0(%rsp), %rax
movsd %xmm0, (%rax)
movq 0x2d58c(%rip), %rdi     # 0x38fd8
leaq 0x208f0(%rip), %rsi     # 0x2c343
callq 0x3320
movq %rax, 0x138(%rsp)
jmp 0xba62
movq 0x138(%rsp), %rdi
movq 0xae0(%rsp), %rax
movsd (%rax), %xmm0
callq 0x35a0
movq %rax, 0x130(%rsp)
jmp 0xba85
movq 0x130(%rsp), %rdi
movq 0x2d534(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xba9b
jmp 0xc50a
leaq 0xa78(%rsp), %rdi
leaq 0x208c7(%rip), %rsi     # 0x2c376
callq 0x3100
cmpl $0x0, %eax
jne 0xbbd8
movl 0xaa4(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xaa4(%rsp)
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rdi
callq 0x3410
movq 0xae8(%rsp), %rax
movsd %xmm0, (%rax)
movq 0xae8(%rsp), %rax
movsd (%rax), %xmm0
movsd 0x1f509(%rip), %xmm1    # 0x2b010
ucomisd %xmm1, %xmm0
jb 0xbb65
movq 0x2d4c4(%rip), %rdi     # 0x38fd8
leaq 0x20861(%rip), %rsi     # 0x2c37c
callq 0x3320
movq %rax, 0x128(%rsp)
jmp 0xbb2a
movq 0x128(%rsp), %rdi
movq 0xae8(%rsp), %rax
movsd (%rax), %xmm0
callq 0x35a0
movq %rax, 0x120(%rsp)
jmp 0xbb4d
movq 0x120(%rsp), %rdi
movq 0x2d46c(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xbb63
jmp 0xbbd3
movq 0x2d46c(%rip), %rdi     # 0x38fd8
leaq 0x20842(%rip), %rsi     # 0x2c3b5
callq 0x3320
movq %rax, 0x118(%rsp)
jmp 0xbb82
movq 0x118(%rsp), %rdi
movq 0xae8(%rsp), %rax
movsd (%rax), %xmm0
callq 0x35a0
movq %rax, 0x110(%rsp)
jmp 0xbba5
movq 0x110(%rsp), %rdi
movq 0x2d414(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xbbbb
movb $0x0, 0xad7(%rsp)
movl $0x1, 0x82c(%rsp)
jmp 0xc52a
jmp 0xc508
leaq 0xa78(%rsp), %rdi
leaq 0x20809(%rip), %rsi     # 0x2c3f0
callq 0x3100
cmpl $0x0, %eax
jne 0xc116
movl 0xaa4(%rsp), %eax
incl %eax
movl %eax, 0xaa4(%rsp)
movq 0x2d3cc(%rip), %rdi     # 0x38fd8
leaq 0x207e6(%rip), %rsi     # 0x2c3f9
callq 0x3320
movq %rax, 0x108(%rsp)
jmp 0xbc22
movq 0x108(%rsp), %rdi
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x3320
movq %rax, 0x100(%rsp)
jmp 0xbc4d
movq 0x100(%rsp), %rdi
movq 0x2d36c(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xbc63
leaq 0x620(%rsp), %rdi
callq 0x33c0
jmp 0xbc72
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
leaq 0x620(%rsp), %rdi
movl $0x8, %edx
callq 0x3200
jmp 0xbc9a
movq 0x620(%rsp), %rax
movq -0x18(%rax), %rax
leaq 0x620(%rsp,%rax), %rdi
callq 0x3520
movb %al, 0xff(%rsp)
jmp 0xbcbc
movb 0xff(%rsp), %al
testb $0x1, %al
jne 0xbccc
jmp 0xc063
jmp 0xbcce
movq 0x620(%rsp), %rax
movq -0x18(%rax), %rax
leaq 0x620(%rsp,%rax), %rdi
callq 0x3520
movb %al, 0xfe(%rsp)
jmp 0xbcf0
movb 0xfe(%rsp), %al
testb $0x1, %al
jne 0xbd00
jmp 0xbfbc
leaq 0x5ff(%rsp), %rdi
movq %rdi, 0xf0(%rsp)
callq 0x3570
movq 0xf0(%rsp), %rdx
leaq 0x2013d(%rip), %rsi     # 0x2be61
leaq 0x600(%rsp), %rdi
callq 0x185e0
jmp 0xbd33
leaq 0x5ff(%rsp), %rdi
callq 0x3390
leaq 0x620(%rsp), %rdi
leaq 0x600(%rsp), %rsi
callq 0x30a0
jmp 0xbd57
leaq 0x600(%rsp), %rdi
callq 0x3250
cmpq $0x0, %rax
je 0xbd95
xorl %eax, %eax
movl %eax, %esi
leaq 0x600(%rsp), %rdi
callq 0x35f0
movq %rax, 0xe8(%rsp)
jmp 0xbd85
movq 0xe8(%rsp), %rax
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0xbdfd
movl $0x6, 0x82c(%rsp)
jmp 0xbf86
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa68(%rsp)
movl %eax, 0xa64(%rsp)
jmp 0xc104
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa68(%rsp)
movl %eax, 0xa64(%rsp)
leaq 0x5ff(%rsp), %rdi
callq 0x3390
jmp 0xc104
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa68(%rsp)
movl %eax, 0xa64(%rsp)
jmp 0xbfaa
movl 0xa9c(%rsp), %eax
incl %eax
movl %eax, 0xa9c(%rsp)
leaq 0x3f0(%rsp), %rdi
callq 0x33c0
jmp 0xbe1c
leaq 0x600(%rsp), %rdi
callq 0x3150
movq %rax, %rsi
leaq 0x3f0(%rsp), %rdi
movl $0x8, %edx
callq 0x3200
jmp 0xbe40
movq 0x3f0(%rsp), %rax
movq -0x18(%rax), %rax
leaq 0x3f0(%rsp,%rax), %rdi
callq 0x3520
movb %al, 0xe7(%rsp)
jmp 0xbe62
movb 0xe7(%rsp), %al
testb $0x1, %al
jne 0xbe6f
jmp 0xbec0
movq 0xab0(%rsp), %rdi
leaq 0x600(%rsp), %rsi
callq 0x1acb0
jmp 0xbe86
leaq 0x3f0(%rsp), %rdi
callq 0x30b0
jmp 0xbe95
jmp 0xbf6e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa68(%rsp)
movl %eax, 0xa64(%rsp)
leaq 0x3f0(%rsp), %rdi
callq 0x30e0
jmp 0xbfaa
movq 0x2d111(%rip), %rdi     # 0x38fd8
leaq 0x2055c(%rip), %rsi     # 0x2c42a
callq 0x3320
movq %rax, 0xd8(%rsp)
jmp 0xbedd
movq 0xd8(%rsp), %rdi
movl 0xa9c(%rsp), %esi
callq 0x3540
movq %rax, 0xd0(%rsp)
jmp 0xbefb
movq 0xd0(%rsp), %rdi
leaq 0x1f6a8(%rip), %rsi     # 0x2b5b2
callq 0x3320
movq %rax, 0xc8(%rsp)
jmp 0xbf19
movq 0xc8(%rsp), %rdi
leaq 0x20519(%rip), %rsi     # 0x2c441
callq 0x3320
movq %rax, 0xc0(%rsp)
jmp 0xbf37
movq 0xc0(%rsp), %rdi
leaq 0x600(%rsp), %rsi
callq 0x32e0
movq %rax, 0xb8(%rsp)
jmp 0xbf56
movq 0xb8(%rsp), %rdi
movq 0x2d063(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xbf6c
jmp 0xbf6e
leaq 0x3f0(%rsp), %rdi
callq 0x30e0
movl $0x0, 0x82c(%rsp)
leaq 0x600(%rsp), %rdi
callq 0x31e0
movl 0x82c(%rsp), %eax
testl %eax, %eax
je 0xbfa5
jmp 0xbfa0
jmp 0xbcce
jmp 0xbcce
leaq 0x600(%rsp), %rdi
callq 0x31e0
jmp 0xc104
leaq 0x620(%rsp), %rdi
callq 0x30b0
jmp 0xbfcb
movq 0x2d006(%rip), %rdi     # 0x38fd8
leaq 0x20475(%rip), %rsi     # 0x2c44e
callq 0x3320
movq %rax, 0xb0(%rsp)
jmp 0xbfe8
movq 0xab0(%rsp), %rdi
callq 0x1a930
movq 0xb0(%rsp), %rdi
movq %rax, %rsi
callq 0x30d0
movq %rax, 0xa8(%rsp)
jmp 0xc00f
movq 0xa8(%rsp), %rdi
leaq 0x1ff1f(%rip), %rsi     # 0x2bf3d
callq 0x3320
movq %rax, 0xa0(%rsp)
jmp 0xc02d
movq 0xa0(%rsp), %rdi
movl 0xa9c(%rsp), %esi
callq 0x3540
movq %rax, 0x98(%rsp)
jmp 0xc04b
movq 0x98(%rsp), %rdi
movq 0x2cf6e(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xc061
jmp 0xc0d6
movq 0x2cf6e(%rip), %rdi     # 0x38fd8
leaq 0x2040b(%rip), %rsi     # 0x2c47c
callq 0x3320
movq %rax, 0x90(%rsp)
jmp 0xc080
movq 0x90(%rsp), %rdi
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x3320
movq %rax, 0x88(%rsp)
jmp 0xc0ab
movq 0x88(%rsp), %rdi
movq 0x2cf0e(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xc0c1
movb $0x0, 0xad7(%rsp)
movl $0x1, 0x82c(%rsp)
jmp 0xc0e1
movl $0x0, 0x82c(%rsp)
leaq 0x620(%rsp), %rdi
callq 0x30e0
movl 0x82c(%rsp), %eax
testl %eax, %eax
jne 0xc52a
jmp 0xc0ff
jmp 0xc506
leaq 0x620(%rsp), %rdi
callq 0x30e0
jmp 0xc54b
leaq 0xa78(%rsp), %rdi
leaq 0x20386(%rip), %rsi     # 0x2c4ab
callq 0x3100
cmpl $0x0, %eax
jne 0xc36d
movl 0xaa4(%rsp), %eax
incl %eax
movl %eax, 0xaa4(%rsp)
leaq 0x1e8(%rsp), %rdi
callq 0x33c0
jmp 0xc152
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, 0x78(%rsp)
leaq 0x1c7(%rsp), %rdi
movq %rdi, 0x80(%rsp)
callq 0x3570
movq 0x78(%rsp), %rsi
movq 0x80(%rsp), %rdx
leaq 0x1c8(%rsp), %rdi
callq 0x185e0
jmp 0xc19c
movq 0xab8(%rsp), %rdi
leaq 0x1c8(%rsp), %rsi
movq %rsi, 0x70(%rsp)
callq 0x33f0
movq 0x70(%rsp), %rdi
callq 0x31e0
leaq 0x1c7(%rsp), %rdi
callq 0x3390
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
leaq 0x1e8(%rsp), %rdi
movl $0x8, %edx
callq 0x3200
jmp 0xc1f5
movq 0x1e8(%rsp), %rax
movq -0x18(%rax), %rax
leaq 0x1e8(%rsp,%rax), %rdi
callq 0x3520
movb %al, 0x6f(%rsp)
jmp 0xc214
movb 0x6f(%rsp), %al
testb $0x1, %al
jne 0xc221
jmp 0xc2b7
movq 0x2cdb0(%rip), %rdi     # 0x38fd8
leaq 0x20283(%rip), %rsi     # 0x2c4b2
callq 0x3320
movq %rax, 0x60(%rsp)
jmp 0xc23b
movq 0x60(%rsp), %rdi
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x3320
movq %rax, 0x58(%rsp)
jmp 0xc260
movq 0x58(%rsp), %rdi
movq 0x2cd5c(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xc273
jmp 0xc31e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa68(%rsp)
movl %eax, 0xa64(%rsp)
leaq 0x1c7(%rsp), %rdi
callq 0x3390
jmp 0xc35b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa68(%rsp)
movl %eax, 0xa64(%rsp)
jmp 0xc35b
movq 0x2cd1a(%rip), %rdi     # 0x38fd8
leaq 0x20212(%rip), %rsi     # 0x2c4d7
callq 0x3320
movq %rax, 0x50(%rsp)
jmp 0xc2d1
movq 0x50(%rsp), %rdi
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x3320
movq %rax, 0x48(%rsp)
jmp 0xc2f6
movq 0x48(%rsp), %rdi
movq 0x2ccc6(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xc309
movb $0x0, 0xad7(%rsp)
movl $0x1, 0x82c(%rsp)
jmp 0xc338
leaq 0x1e8(%rsp), %rdi
callq 0x30b0
jmp 0xc32d
movl $0x0, 0x82c(%rsp)
leaq 0x1e8(%rsp), %rdi
callq 0x30e0
movl 0x82c(%rsp), %eax
testl %eax, %eax
jne 0xc52a
jmp 0xc356
jmp 0xc504
leaq 0x1e8(%rsp), %rdi
callq 0x30e0
jmp 0xc54b
leaq 0xa78(%rsp), %rdi
leaq 0x20182(%rip), %rsi     # 0x2c4fe
callq 0x3100
cmpl $0x0, %eax
jne 0xc498
movl 0xaa4(%rsp), %eax
incl %eax
movl %eax, 0xaa4(%rsp)
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, 0x38(%rsp)
leaq 0x19f(%rsp), %rdi
movq %rdi, 0x40(%rsp)
callq 0x3570
movq 0x38(%rsp), %rsi
movq 0x40(%rsp), %rdx
leaq 0x1a0(%rsp), %rdi
callq 0x185e0
jmp 0xc3de
movq 0xaf0(%rsp), %rdi
leaq 0x1a0(%rsp), %rsi
movq %rsi, 0x28(%rsp)
callq 0x33f0
movq 0x28(%rsp), %rdi
callq 0x31e0
leaq 0x19f(%rsp), %rdi
callq 0x3390
movq 0x2cbc2(%rip), %rdi     # 0x38fd8
leaq 0x200e4(%rip), %rsi     # 0x2c501
callq 0x3320
movq %rax, 0x30(%rsp)
jmp 0xc429
movq 0x30(%rsp), %rdi
movq 0xaf0(%rsp), %rsi
callq 0x32e0
movq %rax, 0x20(%rsp)
jmp 0xc442
movq 0x20(%rsp), %rdi
leaq 0x200de(%rip), %rsi     # 0x2c52c
callq 0x3320
movq %rax, 0x18(%rsp)
jmp 0xc45a
movq 0x18(%rsp), %rdi
movq 0x2cb62(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xc46d
jmp 0xc502
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa68(%rsp)
movl %eax, 0xa64(%rsp)
leaq 0x19f(%rsp), %rdi
callq 0x3390
jmp 0xc54b
movq 0x2cb39(%rip), %rdi     # 0x38fd8
leaq 0x20088(%rip), %rsi     # 0x2c52e
callq 0x3320
movq %rax, 0x10(%rsp)
jmp 0xc4b2
movq 0x10(%rsp), %rdi
movq 0xac8(%rsp), %rax
movslq 0xaa4(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x3320
movq %rax, 0x8(%rsp)
jmp 0xc4d7
movq 0x8(%rsp), %rdi
leaq 0x2005f(%rip), %rsi     # 0x2c542
callq 0x3320
movq %rax, (%rsp)
jmp 0xc4ee
movq (%rsp), %rdi
movq 0x2cacf(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xc500
jmp 0xc502
jmp 0xc504
jmp 0xc506
jmp 0xc508
jmp 0xc50a
jmp 0xc50c
jmp 0xc50e
movl 0xaa4(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xaa4(%rsp)
movl $0x0, 0x82c(%rsp)
leaq 0xa78(%rsp), %rdi
callq 0x31e0
movl 0x82c(%rsp), %eax
testl %eax, %eax
je 0xc546
jmp 0xc544
jmp 0xc562
jmp 0xb687
leaq 0xa78(%rsp), %rdi
callq 0x31e0
jmp 0xc573
movb $0x1, 0xad7(%rsp)
movb 0xad7(%rsp), %al
andb $0x1, %al
addq $0xad8, %rsp            # imm = 0xAD8
retq
movq 0xa68(%rsp), %rdi
callq 0x3560