// File: schneebergerlab[P]GameteBinning/asPollinator_1.0.cpp
// Function: collect_marker_info(char const*, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::map<unsigned long, ALLELE, std::less<unsigned long>, std::allocator<std::pair<unsigned long const, ALLELE>>>, std::less<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, std::map<unsigned long, ALLELE, std::less<unsigned long>, std::allocator<std::pair<unsigned long const, ALLELE>>>>>>*)
bool collect_marker_info(const char* file, 
                         map<string, map<unsigned long, ALLELE> >* mkr)
{
    // type of markers: snps(, 1-bp deletion and 1-bp insertion)
    cout << "   Info: reading marker info from " << file << endl;
    ifstream ifp;
    ifp.open(file);
    if(!ifp.good())
    {
        return false;
    }
    int num = 0;
    int raw = 0;
    int del = 0;
    int ins = 0;
    bool adjsnp = false; // SNPs directly next to each other
    int    nadj = 0;
    while(ifp.good())
    {
        string line("");
        getline(ifp, line);
        if(line.size()==0 || line[0]=='#') continue;
        
        /* e.g.,
	        ks	1	164393	C	G  -- snp
		ks	1	164413	AC	TA -- twp snps
		ks	1	460940  -	A  -- insertion
		ks	1	468923  T	-  -- deletion
        */
        vector<string> lineinfo = split_string(line, '\t');
        if(lineinfo[3].size() != lineinfo[4].size()) continue; // non-snps
        raw ++;
        
        if(lineinfo[3].size() > 1 && !adjsnp)
        {
            cout << "   Info: snp line will be separated, e.g, " << line << endl;
            cout << "       You will get a total number after reading all marker info. " << endl;
            adjsnp = true;
            nadj ++;
        }
        else
        if(lineinfo[3].size()>1)
        {
            nadj ++;
        }        
        //  split "double/triple/..." snps
        for(int snpi = 0; snpi < lineinfo[3].size(); snpi ++)
        {
            string ref = lineinfo[3].substr(snpi, 1);
            string alt = lineinfo[4].substr(snpi, 1);
            //
            unsigned long pos = strtoul(lineinfo[2].c_str(), NULL, 0);
            pos += snpi;
            std::stringstream sspos;
            sspos.str("");
            sspos << pos;
            //
            string        chrkey     = lineinfo[1];
            string        poskey_str = sspos.str();
            unsigned long poskey     = strtoul(poskey_str.c_str(), NULL, 0);
            string refb              = ref;
            string altb              = alt; // "GA", "G-" or "-A"
            string pollenb           = "N"; // unknown
            //
            map<string, map<unsigned long, ALLELE> >::iterator itr;
            map<string, map<unsigned long, ALLELE> >::iterator itr_end;
            itr     = (*mkr).find(chrkey);
            itr_end = (*mkr).end();
            
            if(itr == itr_end) 
            {
                ALLELE tmpallele;
                tmpallele.refb    = refb;
                tmpallele.altb    = altb;
                tmpallele.pollenb = pollenb;
                map<unsigned long, ALLELE> indMarker;
                indMarker.insert(std::pair<unsigned long, ALLELE>(poskey, tmpallele));
                // new contig
                (*mkr).insert(std::pair<string, map<unsigned long, ALLELE> >(chrkey, indMarker));
                num ++;
            } 
            else
            {
                ALLELE tmpallele;
                tmpallele.refb = refb;
                tmpallele.altb = altb;
                tmpallele.pollenb = pollenb;                
                // contig collected already with new marker position
                (*itr).second.insert(std::pair<unsigned long, ALLELE>(poskey, tmpallele));    
                num ++;                       
            }
            //
            if(alt=="-") del ++;
            if(ref=="-") ins ++;           
        }
    }
    ifp.close();
    cout << "   Info: recording " << num << " (of " << raw << ")" << " markers info done " << endl;  
    cout << "   Info: total number of \"neighboring\" snps: "     << nadj << endl;  
    cout << "   Info: total number of del markers: "              << del  << endl;
    cout << "   Info: total number of ins markers: "              << ins  << endl;
    if(num==0)
    {
        cout << "   Error: no markers found in marker file. " << endl;
        return false;
    }
    return true;
}

// Assembly:
subq $0x8b8, %rsp            # imm = 0x8B8
movq %rdi, 0x8a8(%rsp)
movq %rsi, 0x8a0(%rsp)
movq 0x2ca3a(%rip), %rdi     # 0x38fd8
leaq 0x1fbd0(%rip), %rsi     # 0x2c175
callq 0x3320
movq %rax, %rdi
movq 0x8a8(%rsp), %rsi
callq 0x3320
movq %rax, %rdi
movq 0x2ca04(%rip), %rsi     # 0x38fc8
callq 0x3370
leaq 0x698(%rsp), %rdi
movq %rdi, 0x118(%rsp)
callq 0x33c0
movq 0x118(%rsp), %rdi
movq 0x8a8(%rsp), %rsi
movl $0x8, %edx
callq 0x3200
jmp 0xc5fa
movq 0x698(%rsp), %rax
movq -0x18(%rax), %rax
leaq 0x698(%rsp,%rax), %rdi
callq 0x3520
movb %al, 0x117(%rsp)
jmp 0xc61c
movb 0x117(%rsp), %al
testb $0x1, %al
jne 0xc65a
jmp 0xc629
movb $0x0, 0x8b7(%rsp)
movl $0x1, 0x688(%rsp)
jmp 0xd448
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xd466
movl $0x0, 0x684(%rsp)
movl $0x0, 0x680(%rsp)
movl $0x0, 0x67c(%rsp)
movl $0x0, 0x678(%rsp)
movb $0x0, 0x677(%rsp)
movl $0x0, 0x670(%rsp)
movq 0x698(%rsp), %rax
movq -0x18(%rax), %rax
leaq 0x698(%rsp,%rax), %rdi
callq 0x3520
movb %al, 0x116(%rsp)
jmp 0xc6bb
movb 0x116(%rsp), %al
testb $0x1, %al
jne 0xc6cb
jmp 0xd266
leaq 0x64f(%rsp), %rdi
movq %rdi, 0x108(%rsp)
callq 0x3570
movq 0x108(%rsp), %rdx
leaq 0x1f772(%rip), %rsi     # 0x2be61
leaq 0x650(%rsp), %rdi
callq 0x185e0
jmp 0xc6fe
leaq 0x64f(%rsp), %rdi
callq 0x3390
leaq 0x698(%rsp), %rdi
leaq 0x650(%rsp), %rsi
callq 0x30a0
jmp 0xc722
leaq 0x650(%rsp), %rdi
callq 0x3250
cmpq $0x0, %rax
je 0xc760
xorl %eax, %eax
movl %eax, %esi
leaq 0x650(%rsp), %rdi
callq 0x35f0
movq %rax, 0x100(%rsp)
jmp 0xc750
movq 0x100(%rsp), %rax
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0xc7af
movl $0x2, 0x688(%rsp)
jmp 0xd223
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
leaq 0x64f(%rsp), %rdi
callq 0x3390
jmp 0xd466
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xd254
movb $0x9, 0x62f(%rsp)
leaq 0x630(%rsp), %rdi
leaq 0x650(%rsp), %rsi
leaq 0x62f(%rsp), %rdx
callq 0x2aa50
jmp 0xc7d6
leaq 0x630(%rsp), %rdi
movl $0x3, %esi
callq 0x19580
movq %rax, %rdi
callq 0x3250
movq %rax, 0xf8(%rsp)
leaq 0x630(%rsp), %rdi
movl $0x4, %esi
callq 0x19580
movq %rax, %rdi
callq 0x3250
movq %rax, %rcx
movq 0xf8(%rsp), %rax
cmpq %rcx, %rax
je 0xc832
movl $0x2, 0x688(%rsp)
jmp 0xd216
movl 0x680(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x680(%rsp)
leaq 0x630(%rsp), %rdi
movl $0x3, %esi
callq 0x19580
movq %rax, %rdi
callq 0x3250
cmpq $0x1, %rax
jbe 0xc92e
testb $0x1, 0x677(%rsp)
jne 0xc92e
movq 0x2c75c(%rip), %rdi     # 0x38fd8
leaq 0x1f915(%rip), %rsi     # 0x2c198
callq 0x3320
movq %rax, 0xf0(%rsp)
jmp 0xc892
movq 0xf0(%rsp), %rdi
leaq 0x650(%rsp), %rsi
callq 0x32e0
movq %rax, 0xe8(%rsp)
jmp 0xc8b1
movq 0xe8(%rsp), %rdi
movq 0x2c708(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xc8c7
movq 0x2c70a(%rip), %rdi     # 0x38fd8
leaq 0x1f8ee(%rip), %rsi     # 0x2c1c3
callq 0x3320
movq %rax, 0xe0(%rsp)
jmp 0xc8e4
movq 0xe0(%rsp), %rdi
movq 0x2c6d5(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xc8fa
movb $0x1, 0x677(%rsp)
movl 0x670(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x670(%rsp)
jmp 0xc961
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xd247
leaq 0x630(%rsp), %rdi
movl $0x3, %esi
callq 0x19580
movq %rax, %rdi
callq 0x3250
cmpq $0x1, %rax
jbe 0xc95f
movl 0x670(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x670(%rsp)
jmp 0xc961
movl $0x0, 0x628(%rsp)
movslq 0x628(%rsp), %rax
movq %rax, 0xd8(%rsp)
leaq 0x630(%rsp), %rdi
movl $0x3, %esi
callq 0x19580
movq %rax, %rdi
callq 0x3250
movq %rax, %rcx
movq 0xd8(%rsp), %rax
cmpq %rcx, %rax
jae 0xd20b
leaq 0x630(%rsp), %rdi
movl $0x3, %esi
callq 0x19580
movq %rax, %rsi
movslq 0x628(%rsp), %rdx
leaq 0x608(%rsp), %rdi
movl $0x1, %ecx
callq 0x3350
jmp 0xc9db
leaq 0x630(%rsp), %rdi
movl $0x4, %esi
callq 0x19580
movq %rax, %rsi
movslq 0x628(%rsp), %rdx
leaq 0x5e8(%rsp), %rdi
movl $0x1, %ecx
callq 0x3350
jmp 0xca0c
leaq 0x630(%rsp), %rdi
movl $0x2, %esi
callq 0x19580
movq %rax, %rdi
callq 0x3150
movq %rax, %rdi
xorl %edx, %edx
movl %edx, %esi
callq 0x3110
movq %rax, 0x5e0(%rsp)
movslq 0x628(%rsp), %rcx
movq 0x5e0(%rsp), %rax
addq %rcx, %rax
movq %rax, 0x5e0(%rsp)
leaq 0x458(%rsp), %rdi
callq 0x3260
jmp 0xca64
leaq 0x437(%rsp), %rdi
movq %rdi, 0xd0(%rsp)
callq 0x3570
movq 0xd0(%rsp), %rdx
leaq 0x1f3d9(%rip), %rsi     # 0x2be61
leaq 0x438(%rsp), %rdi
callq 0x185e0
jmp 0xca97
leaq 0x458(%rsp), %rdi
leaq 0x438(%rsp), %rsi
callq 0x33d0
jmp 0xcaae
leaq 0x438(%rsp), %rdi
callq 0x31e0
leaq 0x437(%rsp), %rdi
callq 0x3390
leaq 0x468(%rsp), %rdi
movq 0x5e0(%rsp), %rsi
callq 0x30d0
jmp 0xcadf
leaq 0x630(%rsp), %rdi
movl $0x1, %esi
callq 0x19580
movq %rax, %rsi
leaq 0x410(%rsp), %rdi
callq 0x3160
jmp 0xcb03
leaq 0x3f0(%rsp), %rdi
leaq 0x458(%rsp), %rsi
callq 0x3310
jmp 0xcb1a
leaq 0x3f0(%rsp), %rdi
callq 0x3150
movq %rax, %rdi
xorl %edx, %edx
movl %edx, %esi
callq 0x3110
movq %rax, 0x3e8(%rsp)
leaq 0x3c8(%rsp), %rdi
leaq 0x608(%rsp), %rsi
callq 0x3160
jmp 0xcb52
leaq 0x3a8(%rsp), %rdi
leaq 0x5e8(%rsp), %rsi
callq 0x3160
jmp 0xcb69
leaq 0x387(%rsp), %rdi
movq %rdi, 0xc8(%rsp)
callq 0x3570
movq 0xc8(%rsp), %rdx
leaq 0x1ea1b(%rip), %rsi     # 0x2b5a8
leaq 0x388(%rsp), %rdi
callq 0x185e0
jmp 0xcb9c
leaq 0x387(%rsp), %rdi
callq 0x3390
leaq 0x378(%rsp), %rdi
callq 0x18890
leaq 0x370(%rsp), %rdi
callq 0x18890
movq 0x8a0(%rsp), %rdi
leaq 0x410(%rsp), %rsi
callq 0x18f60
movq %rax, 0xc0(%rsp)
jmp 0xcbe2
movq 0xc0(%rsp), %rax
movq %rax, 0x368(%rsp)
movq 0x368(%rsp), %rax
movq %rax, 0x378(%rsp)
movq 0x8a0(%rsp), %rdi
callq 0x188e0
movq %rax, 0x360(%rsp)
movq 0x360(%rsp), %rax
movq %rax, 0x370(%rsp)
leaq 0x378(%rsp), %rdi
leaq 0x370(%rsp), %rsi
callq 0x18f90
testb $0x1, %al
jne 0xcc45
jmp 0xcf79
leaq 0x300(%rsp), %rdi
movq %rdi, 0xb8(%rsp)
callq 0x1aa50
movq 0xb8(%rsp), %rdi
leaq 0x3c8(%rsp), %rsi
callq 0x3050
jmp 0xcc71
leaq 0x320(%rsp), %rdi
leaq 0x3a8(%rsp), %rsi
callq 0x3050
jmp 0xcc88
leaq 0x340(%rsp), %rdi
leaq 0x388(%rsp), %rsi
callq 0x3050
jmp 0xcc9f
leaq 0x2d0(%rsp), %rdi
callq 0x1aa90
leaq 0x268(%rsp), %rdi
leaq 0x3e8(%rsp), %rsi
leaq 0x300(%rsp), %rdx
callq 0x1aaf0
jmp 0xcccb
leaq 0x2d0(%rsp), %rdi
leaq 0x268(%rsp), %rsi
callq 0x1aaa0
movb %dl, 0xaf(%rsp)
movq %rax, 0xb0(%rsp)
jmp 0xccf1
movb 0xaf(%rsp), %al
movq 0xb0(%rsp), %rcx
movq %rcx, 0x258(%rsp)
movb %al, 0x260(%rsp)
leaq 0x268(%rsp), %rdi
callq 0x1ab30
movq 0x8a0(%rsp), %rax
movq %rax, 0xa0(%rsp)
leaq 0x208(%rsp), %rdi
leaq 0x410(%rsp), %rsi
leaq 0x2d0(%rsp), %rdx
callq 0x1aba0
jmp 0xcd4b
movq 0xa0(%rsp), %rdi
leaq 0x208(%rsp), %rsi
callq 0x1ab50
movb %dl, 0x97(%rsp)
movq %rax, 0x98(%rsp)
jmp 0xcd71
movb 0x97(%rsp), %al
movq 0x98(%rsp), %rcx
movq %rcx, 0x1f8(%rsp)
movb %al, 0x200(%rsp)
leaq 0x208(%rsp), %rdi
callq 0x1ac10
movl 0x684(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x684(%rsp)
leaq 0x2d0(%rsp), %rdi
callq 0x19570
leaq 0x300(%rsp), %rdi
callq 0x1ac40
jmp 0xd0b9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xd1fc
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xd1ef
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xce35
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
leaq 0x438(%rsp), %rdi
callq 0x31e0
leaq 0x437(%rsp), %rdi
callq 0x3390
jmp 0xd1e2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xd1e2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xd1d5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xd1c8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xd1bb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
leaq 0x387(%rsp), %rdi
callq 0x3390
jmp 0xd1ae
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xd1a1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xcf67
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xcf5a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
leaq 0x268(%rsp), %rdi
callq 0x1ab30
jmp 0xcf5a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
leaq 0x208(%rsp), %rdi
callq 0x1ac10
leaq 0x2d0(%rsp), %rdi
callq 0x19570
leaq 0x300(%rsp), %rdi
callq 0x1ac40
jmp 0xd1a1
leaq 0x198(%rsp), %rdi
movq %rdi, 0x88(%rsp)
callq 0x1aa50
movq 0x88(%rsp), %rdi
leaq 0x3c8(%rsp), %rsi
callq 0x3050
jmp 0xcfa5
leaq 0x1b8(%rsp), %rdi
leaq 0x3a8(%rsp), %rsi
callq 0x3050
jmp 0xcfbc
leaq 0x1d8(%rsp), %rdi
leaq 0x388(%rsp), %rsi
callq 0x3050
jmp 0xcfd3
leaq 0x378(%rsp), %rdi
callq 0x18930
addq $0x20, %rax
movq %rax, 0x80(%rsp)
leaq 0x130(%rsp), %rdi
leaq 0x3e8(%rsp), %rsi
leaq 0x198(%rsp), %rdx
callq 0x1aaf0
jmp 0xd00b
movq 0x80(%rsp), %rdi
leaq 0x130(%rsp), %rsi
callq 0x1aaa0
movb %dl, 0x77(%rsp)
movq %rax, 0x78(%rsp)
jmp 0xd02b
movb 0x77(%rsp), %al
movq 0x78(%rsp), %rcx
movq %rcx, 0x120(%rsp)
movb %al, 0x128(%rsp)
leaq 0x130(%rsp), %rdi
callq 0x1ab30
movl 0x684(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x684(%rsp)
leaq 0x198(%rsp), %rdi
callq 0x1ac40
jmp 0xd0b9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
jmp 0xd0a7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x690(%rsp)
movl %eax, 0x68c(%rsp)
leaq 0x130(%rsp), %rdi
callq 0x1ab30
leaq 0x198(%rsp), %rdi
callq 0x1ac40
jmp 0xd1a1
leaq 0x1eb23(%rip), %rsi     # 0x2bbe3
leaq 0x5e8(%rsp), %rdi
callq 0x1ac80
movb %al, 0x76(%rsp)
jmp 0xd0d3
movb 0x76(%rsp), %al
testb $0x1, %al
jne 0xd0dd
jmp 0xd0ee
movl 0x67c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x67c(%rsp)
leaq 0x1eaee(%rip), %rsi     # 0x2bbe3
leaq 0x608(%rsp), %rdi
callq 0x1ac80
movb %al, 0x75(%rsp)
jmp 0xd108
movb 0x75(%rsp), %al
testb $0x1, %al
jne 0xd112
jmp 0xd123
movl 0x678(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x678(%rsp)
leaq 0x388(%rsp), %rdi
callq 0x31e0
leaq 0x3a8(%rsp), %rdi
callq 0x31e0
leaq 0x3c8(%rsp), %rdi
callq 0x31e0
leaq 0x3f0(%rsp), %rdi
callq 0x31e0
leaq 0x410(%rsp), %rdi
callq 0x31e0
leaq 0x458(%rsp), %rdi
callq 0x3280
leaq 0x5e8(%rsp), %rdi
callq 0x31e0
leaq 0x608(%rsp), %rdi
callq 0x31e0
movl 0x628(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x628(%rsp)
jmp 0xc96c
leaq 0x388(%rsp), %rdi
callq 0x31e0
leaq 0x3a8(%rsp), %rdi
callq 0x31e0
leaq 0x3c8(%rsp), %rdi
callq 0x31e0
leaq 0x3f0(%rsp), %rdi
callq 0x31e0
leaq 0x410(%rsp), %rdi
callq 0x31e0
leaq 0x458(%rsp), %rdi
callq 0x3280
leaq 0x5e8(%rsp), %rdi
callq 0x31e0
leaq 0x608(%rsp), %rdi
callq 0x31e0
jmp 0xd247
movl $0x0, 0x688(%rsp)
leaq 0x630(%rsp), %rdi
callq 0x18e80
leaq 0x650(%rsp), %rdi
callq 0x31e0
movl 0x688(%rsp), %eax
testl %eax, %eax
je 0xd242
jmp 0xd23d
jmp 0xc699
jmp 0xc699
leaq 0x630(%rsp), %rdi
callq 0x18e80
leaq 0x650(%rsp), %rdi
callq 0x31e0
jmp 0xd466
leaq 0x698(%rsp), %rdi
callq 0x30b0
jmp 0xd275
movq 0x2bd5c(%rip), %rdi     # 0x38fd8
leaq 0x1ef83(%rip), %rsi     # 0x2c206
callq 0x3320
movq %rax, 0x68(%rsp)
jmp 0xd28f
movq 0x68(%rsp), %rdi
movl 0x684(%rsp), %esi
callq 0x3540
movq %rax, 0x60(%rsp)
jmp 0xd2a7
movq 0x60(%rsp), %rdi
leaq 0x1ef67(%rip), %rsi     # 0x2c21a
callq 0x3320
movq %rax, 0x58(%rsp)
jmp 0xd2bf
movq 0x58(%rsp), %rdi
movl 0x680(%rsp), %esi
callq 0x3540
movq %rax, 0x50(%rsp)
jmp 0xd2d7
movq 0x50(%rsp), %rdi
leaq 0x1ed12(%rip), %rsi     # 0x2bff5
callq 0x3320
movq %rax, 0x48(%rsp)
jmp 0xd2ef
movq 0x48(%rsp), %rdi
leaq 0x1ef25(%rip), %rsi     # 0x2c220
callq 0x3320
movq %rax, 0x40(%rsp)
jmp 0xd307
movq 0x40(%rsp), %rdi
movq 0x2bcb5(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xd31a
movq 0x2bcb7(%rip), %rdi     # 0x38fd8
leaq 0x1ef0c(%rip), %rsi     # 0x2c234
callq 0x3320
movq %rax, 0x38(%rsp)
jmp 0xd334
movq 0x38(%rsp), %rdi
movl 0x670(%rsp), %esi
callq 0x3540
movq %rax, 0x30(%rsp)
jmp 0xd34c
movq 0x30(%rsp), %rdi
movq 0x2bc70(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xd35f
movq 0x2bc72(%rip), %rdi     # 0x38fd8
leaq 0x1eef5(%rip), %rsi     # 0x2c262
callq 0x3320
movq %rax, 0x28(%rsp)
jmp 0xd379
movq 0x28(%rsp), %rdi
movl 0x67c(%rsp), %esi
callq 0x3540
movq %rax, 0x20(%rsp)
jmp 0xd391
movq 0x20(%rsp), %rdi
movq 0x2bc2b(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xd3a4
movq 0x2bc2d(%rip), %rdi     # 0x38fd8
leaq 0x1eed7(%rip), %rsi     # 0x2c289
callq 0x3320
movq %rax, 0x18(%rsp)
jmp 0xd3be
movq 0x18(%rsp), %rdi
movl 0x678(%rsp), %esi
callq 0x3540
movq %rax, 0x10(%rsp)
jmp 0xd3d6
movq 0x10(%rsp), %rdi
movq 0x2bbe6(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xd3e9
cmpl $0x0, 0x684(%rsp)
jne 0xd435
movq 0x2bbde(%rip), %rdi     # 0x38fd8
leaq 0x1eeaf(%rip), %rsi     # 0x2c2b0
callq 0x3320
movq %rax, 0x8(%rsp)
jmp 0xd40d
movq 0x8(%rsp), %rdi
movq 0x2bbaf(%rip), %rsi     # 0x38fc8
callq 0x3370
jmp 0xd420
movb $0x0, 0x8b7(%rsp)
movl $0x1, 0x688(%rsp)
jmp 0xd448
movb $0x1, 0x8b7(%rsp)
movl $0x1, 0x688(%rsp)
leaq 0x698(%rsp), %rdi
callq 0x30e0
movb 0x8b7(%rsp), %al
andb $0x1, %al
addq $0x8b8, %rsp            # imm = 0x8B8
retq
leaq 0x698(%rsp), %rdi
callq 0x30e0
movq 0x690(%rsp), %rdi
callq 0x3560