// File: millanek[P]evo/./process_vcf_annotation_tools.h
// Function: Annotation::getAnnotationPerGeneDetails(std::vector<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>>>>, std::allocator<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>>>>>> const&)
void getAnnotationPerGeneDetails(const std::vector<std::vector<string> >& scaffoldAnnotation) {
        int thisGeneTranscriptCount;
        string previousGeneName = "";
        for (std::vector<string>::size_type i = 0; i != scaffoldAnnotation.size(); i++) {
            std::vector<string> annotLineVec = split(scaffoldAnnotation[i][0], '\t');
            int numDots = (int)std::count(annotLineVec[4].begin(), annotLineVec[4].end(), '.');
            std::string geneName;
            if (numDots == 4)  geneName = geneFromTranscript(annotLineVec[4]);
            else geneName = annotLineVec[4];
            if (previousGeneName == geneName) {
                thisGeneTranscriptCount++;
            } else {
                geneTranscriptCounts[previousGeneName] = thisGeneTranscriptCount;
                thisGeneTranscriptCount = 1;
                previousGeneName = geneName;
            }
            if (i == (scaffoldAnnotation.size()-1)) {   // Add the final gene in the scaffold
                geneTranscriptCounts[previousGeneName] = thisGeneTranscriptCount;
            }
        }
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x130, %rsp            # imm = 0x130
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0xe0(%rbp)
leaq -0x39(%rbp), %rdi
movq %rdi, -0xd8(%rbp)
callq 0xab60
movq -0xd8(%rbp), %rdx
leaq 0xdc9e3(%rip), %rsi     # 0x135edf
leaq -0x38(%rbp), %rdi
callq 0x2d6c0
jmp 0x59507
leaq -0x39(%rbp), %rdi
callq 0xa640
movq $0x0, -0x58(%rbp)
movq -0x58(%rbp), %rax
movq %rax, -0xe8(%rbp)
movq -0x10(%rbp), %rdi
callq 0x409f0
movq %rax, %rcx
movq -0xe8(%rbp), %rax
cmpq %rcx, %rax
je 0x597b4
movq -0x10(%rbp), %rdi
movq -0x58(%rbp), %rsi
callq 0x59850
movq %rax, %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x52960
movq %rax, %rsi
leaq -0x70(%rbp), %rdi
movl $0x9, %edx
callq 0x7bbe0
jmp 0x5956b
leaq -0x70(%rbp), %rdi
movq %rdi, -0x100(%rbp)
movl $0x4, %esi
movq %rsi, -0xf8(%rbp)
callq 0x3d940
movq %rax, %rdi
callq 0xa4f0
movq -0x100(%rbp), %rdi
movq -0xf8(%rbp), %rsi
movq %rax, -0x80(%rbp)
callq 0x3d940
movq %rax, %rdi
callq 0xa330
movq %rax, -0x88(%rbp)
movb $0x2e, -0x89(%rbp)
movq -0x80(%rbp), %rdi
movq -0x88(%rbp), %rsi
leaq -0x89(%rbp), %rdx
callq 0x59870
movq %rax, -0xf0(%rbp)
jmp 0x595dc
movq -0xf0(%rbp), %rax
movl %eax, -0x74(%rbp)
leaq -0xb0(%rbp), %rdi
callq 0xa820
cmpl $0x4, -0x74(%rbp)
jne 0x59695
leaq -0x70(%rbp), %rdi
movl $0x4, %esi
callq 0x3d940
movq %rax, %rsi
leaq -0xd0(%rbp), %rdi
callq 0x598c0
jmp 0x5961b
leaq -0xb0(%rbp), %rdi
leaq -0xd0(%rbp), %rsi
callq 0xa710
leaq -0xd0(%rbp), %rdi
callq 0xac88
jmp 0x596b6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x39(%rbp), %rdi
callq 0xa640
jmp 0x597cf
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x597c6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x597a9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0xb0(%rbp), %rdi
callq 0xac88
jmp 0x597a9
leaq -0x70(%rbp), %rdi
movl $0x4, %esi
callq 0x3d940
movq %rax, %rsi
leaq -0xb0(%rbp), %rdi
callq 0xa060
jmp 0x596b4
jmp 0x596b6
leaq -0x38(%rbp), %rdi
leaq -0xb0(%rbp), %rsi
callq 0x39210
testb $0x1, %al
jne 0x596cc
jmp 0x596d7
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x59727
movq -0xe0(%rbp), %rdi
movl -0x14(%rbp), %eax
movl %eax, -0x10c(%rbp)
addq $0x30, %rdi
leaq -0x38(%rbp), %rsi
callq 0x59b00
movq %rax, -0x108(%rbp)
jmp 0x596fd
movq -0x108(%rbp), %rax
movl -0x10c(%rbp), %ecx
movl %ecx, (%rax)
movl $0x1, -0x14(%rbp)
leaq -0x38(%rbp), %rdi
leaq -0xb0(%rbp), %rsi
callq 0xa060
jmp 0x59725
jmp 0x59727
movq -0x58(%rbp), %rax
movq %rax, -0x118(%rbp)
movq -0x10(%rbp), %rdi
callq 0x409f0
movq %rax, %rcx
movq -0x118(%rbp), %rax
subq $0x1, %rcx
cmpq %rcx, %rax
jne 0x59783
movq -0xe0(%rbp), %rdi
movl -0x14(%rbp), %eax
movl %eax, -0x124(%rbp)
addq $0x30, %rdi
leaq -0x38(%rbp), %rsi
callq 0x59b00
movq %rax, -0x120(%rbp)
jmp 0x59774
movq -0x120(%rbp), %rax
movl -0x124(%rbp), %ecx
movl %ecx, (%rax)
leaq -0xb0(%rbp), %rdi
callq 0xac88
leaq -0x70(%rbp), %rdi
callq 0x3dfa0
movq -0x58(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x58(%rbp)
jmp 0x59518
leaq -0x70(%rbp), %rdi
callq 0x3dfa0
jmp 0x597c6
leaq -0x38(%rbp), %rdi
callq 0xac88
addq $0x130, %rsp            # imm = 0x130
popq %rbp
retq
leaq -0x38(%rbp), %rdi
callq 0xac88
movq -0x48(%rbp), %rdi
callq 0xab50
nopl (%rax,%rax)