// File: /workspace/github_cpp_makefile_star2_O1/millanek[P]evo/./process_vcf_annotation_tools.h
// Function: BedCoordinateFeatures::loadBedFeatureMap[abi:cxx11](std::basic_ifstream<char, std::char_traits<char>>*&, bool)
std::map<string, std::vector<std::vector<int> > > loadBedFeatureMap(std::ifstream*& bedFile, bool debug) {
        std::map<string, std::vector<std::vector<int> > > BedFeatureMap;
        std::vector<std::vector<int> > BedFeaturesThisScaffold;
        std::vector<int> featureStarts;
        std::vector<int> featureEnds;
        string line;
        string previousScaffold = "";
        //std::cerr << "Loading scaffold: " << currentScaffold << std::endl;
        while (getline(*bedFile, line)) {
            std::vector<string> currentFeature = split(line, '\t');
            if (currentFeature[0] != previousScaffold && previousScaffold != "") {
                if (debug) {
                    std::cerr << "Loading scaffold: " << previousScaffold << std::endl;
                    std::cerr << "Starts: " << std::endl;
                    print_vector(featureStarts, std::cerr);
                    std::cerr << "Ends: " << std::endl;
                    print_vector(featureEnds, std::cerr);
                }
                BedFeaturesThisScaffold.push_back(featureStarts);
                BedFeaturesThisScaffold.push_back(featureEnds);
                BedFeatureMap[previousScaffold] = BedFeaturesThisScaffold;
                BedFeaturesThisScaffold.clear(); featureStarts.clear(); featureEnds.clear();
                // std::cerr << "Loading scaffold: " << currentScaffold << std::endl;
            }
            featureStarts.push_back(atoi(currentFeature[1].c_str()));
            featureEnds.push_back(atoi(currentFeature[2].c_str()));
            // std::cerr << "Loading scaffold: " << currentFeature[0] << "\t" << currentScaffold << std::endl;
            previousScaffold = currentFeature[0];
            //std::cerr << "Loading scaffold: " << currentFeature[0] << "\t" << currentScaffold << std::endl;
        }
        // Final line / final scaffold
        BedFeaturesThisScaffold.push_back(featureStarts);
        BedFeaturesThisScaffold.push_back(featureEnds);
        BedFeatureMap[previousScaffold] = BedFeaturesThisScaffold;
        return BedFeatureMap;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xf8, %rsp
movl %ecx, 0x8c(%rsp)
movq %rdx, %r14
leaq 0x8(%rdi), %rax
movl $0x0, 0x8(%rdi)
xorl %ecx, %ecx
movq %rcx, 0x10(%rdi)
movq %rax, 0x18(%rdi)
movq %rax, 0x20(%rdi)
movq %rdi, 0x48(%rsp)
movq %rcx, 0x28(%rdi)
movq %rcx, 0x60(%rsp)
xorps %xmm0, %xmm0
movaps %xmm0, 0x50(%rsp)
movq %rcx, 0x40(%rsp)
movaps %xmm0, 0x30(%rsp)
movq %rcx, 0x20(%rsp)
movaps %xmm0, 0x10(%rsp)
leaq 0xe8(%rsp), %rax
movq %rax, -0x10(%rax)
movq %rcx, -0x8(%rax)
movb $0x0, (%rax)
leaq 0x78(%rsp), %rax
movq %rax, -0x10(%rax)
leaq 0x87336(%rip), %rdx     # 0xd1c7f
leaq 0x68(%rsp), %rdi
movq %rdx, %rsi
callq 0x28952
leaq 0xd8(%rsp), %r15
leaq 0xc0(%rsp), %rbx
leaq 0x30(%rsp), %r12
leaq 0x10(%rsp), %r13
movq (%r14), %rbp
movq (%rbp), %rax
movq -0x18(%rax), %rdi
addq %rbp, %rdi
movl $0xa, %esi
callq 0x8450
movsbl %al, %edx
movq %rbp, %rdi
movq %r15, %rsi
callq 0x8870
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x4acd0
movq %rbx, %rdi
movq %r15, %rsi
movl $0x9, %edx
callq 0x50624
movq 0xc0(%rsp), %rax
movq 0x8(%rax), %rdx
cmpq 0x70(%rsp), %rdx
jne 0x4a9e9
testq %rdx, %rdx
je 0x4ac3b
movq 0x68(%rsp), %rsi
movq (%rax), %rdi
callq 0x8490
testl %eax, %eax
je 0x4ac3b
leaq 0x68(%rsp), %rdi
leaq 0x8728a(%rip), %rsi     # 0xd1c7f
callq 0x8160
testl %eax, %eax
je 0x4ac3b
cmpb $0x0, 0x8c(%rsp)
je 0x4ab92
movl $0x12, %edx
movq 0xc05cc(%rip), %rdi     # 0x10afe8
leaq 0x8b58d(%rip), %rsi     # 0xd5fb0
callq 0x84e0
movq 0x68(%rsp), %rsi
movq 0x70(%rsp), %rdx
movq 0xc05af(%rip), %rdi     # 0x10afe8
callq 0x84e0
movq %rax, %rbp
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbp, %rdi
movl $0xa, %esi
callq 0x8450
movsbl %al, %esi
movq %rbp, %rdi
callq 0x8040
movq %rax, %rdi
callq 0x8300
movl $0x8, %edx
movq 0xc0574(%rip), %rdi     # 0x10afe8
leaq 0x8b548(%rip), %rsi     # 0xd5fc3
callq 0x84e0
movq 0xc0561(%rip), %rcx     # 0x10afe8
movq (%rcx), %rax
movq -0x18(%rax), %rdi
addq %rcx, %rdi
movl $0xa, %esi
callq 0x8450
movsbl %al, %esi
movq 0xc0543(%rip), %rdi     # 0x10afe8
callq 0x8040
movq %rax, %rdi
callq 0x8300
leaq 0xa8(%rsp), %rdi
movq %r12, %rsi
callq 0x35990
leaq 0xa8(%rsp), %rdi
movq 0xc0517(%rip), %rsi     # 0x10afe8
movl $0x9, %edx
movl $0x1, %ecx
callq 0x415f4
movq 0xa8(%rsp), %rdi
testq %rdi, %rdi
je 0x4aafd
movq 0xb8(%rsp), %rsi
subq %rdi, %rsi
callq 0x8480
movl $0x6, %edx
movq 0xc04df(%rip), %rdi     # 0x10afe8
leaq 0x8b4bc(%rip), %rsi     # 0xd5fcc
callq 0x84e0
movq 0xc04cc(%rip), %rcx     # 0x10afe8
movq (%rcx), %rax
movq -0x18(%rax), %rdi
addq %rcx, %rdi
movl $0xa, %esi
callq 0x8450
movsbl %al, %esi
movq 0xc04ae(%rip), %rdi     # 0x10afe8
callq 0x8040
movq %rax, %rdi
callq 0x8300
leaq 0x90(%rsp), %rdi
movq %r13, %rsi
callq 0x35990
leaq 0x90(%rsp), %rdi
movq 0xc0482(%rip), %rsi     # 0x10afe8
movl $0x9, %edx
movl $0x1, %ecx
callq 0x415f4
movq 0x90(%rsp), %rdi
testq %rdi, %rdi
je 0x4ab92
movq 0xa0(%rsp), %rsi
subq %rdi, %rsi
callq 0x8480
leaq 0x50(%rsp), %rdi
movq %r12, %rsi
callq 0x4ae84
leaq 0x50(%rsp), %rdi
movq %r13, %rsi
callq 0x4ae84
movq 0x48(%rsp), %rdi
leaq 0x68(%rsp), %rsi
callq 0x4aeb0
movq %rax, %rdi
leaq 0x50(%rsp), %rsi
callq 0x4af2c
movq %rbx, %r13
movq %r15, %rbx
movq %r14, %r15
movq 0x50(%rsp), %r12
movq 0x58(%rsp), %r14
cmpq %r12, %r14
je 0x4ac06
movq %r12, %rbp
movq (%rbp), %rdi
testq %rdi, %rdi
je 0x4abf8
movq 0x10(%rbp), %rsi
subq %rdi, %rsi
callq 0x8480
addq $0x18, %rbp
cmpq %r14, %rbp
jne 0x4abe3
movq %r12, 0x58(%rsp)
movq 0x30(%rsp), %rax
cmpq %rax, 0x38(%rsp)
je 0x4ac17
movq %rax, 0x38(%rsp)
movq 0x10(%rsp), %rax
cmpq %rax, 0x18(%rsp)
movq %r15, %r14
movq %rbx, %r15
movq %r13, %rbx
leaq 0x30(%rsp), %r12
leaq 0x10(%rsp), %r13
je 0x4ac3b
movq %rax, 0x18(%rsp)
movq 0xc0(%rsp), %rax
movq 0x20(%rax), %rdi
callq 0x86e0
movl %eax, 0xc(%rsp)
movq 0x38(%rsp), %rsi
cmpq 0x40(%rsp), %rsi
je 0x4ac69
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x38(%rsp)
jmp 0x4ac76
movq %r12, %rdi
leaq 0xc(%rsp), %rdx
callq 0x35b1e
movq 0xc0(%rsp), %rax
movq 0x40(%rax), %rdi
callq 0x86e0
movl %eax, 0xc(%rsp)
movq 0x18(%rsp), %rsi
cmpq 0x20(%rsp), %rsi
je 0x4aca4
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x18(%rsp)
jmp 0x4acb1
movq %r13, %rdi
leaq 0xc(%rsp), %rdx
callq 0x35b1e
movq 0xc0(%rsp), %rsi
leaq 0x68(%rsp), %rdi
callq 0x8270
movq %rbx, %rdi
callq 0x3123c
jmp 0x4a970
leaq 0x50(%rsp), %rdi
leaq 0x30(%rsp), %rsi
callq 0x4ae84
leaq 0x50(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x4ae84
leaq 0x68(%rsp), %rsi
movq 0x48(%rsp), %rdi
callq 0x4aeb0
leaq 0x50(%rsp), %rsi
movq %rax, %rdi
callq 0x4af2c
movq 0x68(%rsp), %rdi
leaq 0x78(%rsp), %rax
cmpq %rax, %rdi
je 0x4ad26
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x8480
movq 0xd8(%rsp), %rdi
leaq 0xe8(%rsp), %rax
cmpq %rax, %rdi
je 0x4ad4b
movq 0xe8(%rsp), %rsi
incq %rsi
callq 0x8480
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x4ad62
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x8480
movq 0x30(%rsp), %rdi
testq %rdi, %rdi
je 0x4ad79
movq 0x40(%rsp), %rsi
subq %rdi, %rsi
callq 0x8480
leaq 0x50(%rsp), %rdi
callq 0x4b0a4
movq 0x48(%rsp), %rax
addq $0xf8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
jmp 0x4ae14
jmp 0x4ade3
movq %rax, %rbx
movq 0x90(%rsp), %rdi
testq %rdi, %rdi
je 0x4adeb
movq 0xa0(%rsp), %rsi
jmp 0x4add3
movq %rax, %rbx
movq 0xa8(%rsp), %rdi
testq %rdi, %rdi
je 0x4adeb
movq 0xb8(%rsp), %rsi
subq %rdi, %rsi
callq 0x8480
jmp 0x4adeb
jmp 0x4ade8
jmp 0x4ade8
jmp 0x4ade3
movq %rax, %rbx
jmp 0x4adf8
movq %rax, %rbx
leaq 0xc0(%rsp), %rdi
callq 0x3123c
movq 0x68(%rsp), %rdi
leaq 0x78(%rsp), %rax
cmpq %rax, %rdi
je 0x4ae14
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x8480
movq 0xd8(%rsp), %rdi
leaq 0xe8(%rsp), %rax
cmpq %rax, %rdi
je 0x4ae39
movq 0xe8(%rsp), %rsi
incq %rsi
callq 0x8480
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x4ae50
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x8480
movq 0x30(%rsp), %rdi
testq %rdi, %rdi
je 0x4ae67
movq 0x40(%rsp), %rsi
subq %rdi, %rsi
callq 0x8480
leaq 0x50(%rsp), %rdi
callq 0x4b0a4
movq 0x48(%rsp), %rdi
callq 0x4b8ae
movq %rbx, %rdi
callq 0x8840
nop