LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/aalto-speech[P]ftk/src/Bigrams.cc
// Function: Bigrams::get_backpointers(MultiStringFactorGraph const&, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::set<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::less<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::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::set<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::less<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>>>>>>>&, unsigned int)
void
Bigrams::get_backpointers(const MultiStringFactorGraph &msfg,
                          map<string, set<string> > &backpointers,
                          unsigned int minlen)
{
    backpointers.clear();
    for (auto it = msfg.string_end_nodes.begin(); it != msfg.string_end_nodes.end(); ++it) {
        set<string> factors;
        msfg.collect_factors(it->first, factors);
        for (auto fit = factors.begin(); fit != factors.end(); ++fit) {
            if ((*fit).length() < minlen) continue;
            backpointers[*fit].insert(it->first);
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movl %edx, %r14d
movq %rsi, %rbx
movq %rdi, %r15
movq %rsi, %rdi
callq 0x240c6
movq 0x50(%r15), %rax
movq %r15, -0x38(%rbp)
leaq 0x40(%r15), %rcx
movq %rcx, -0x30(%rbp)
cmpq %rcx, %rax
je 0x2350f
leaq -0x68(%rbp), %r12
movl %r14d, %r15d
leaq -0x70(%rbp), %r14
movl $0x0, -0x68(%rbp)
xorl %ecx, %ecx
movq %rcx, -0x60(%rbp)
movq %r12, -0x58(%rbp)
movq %r12, -0x50(%rbp)
movq %rcx, -0x48(%rbp)
movq %rax, -0x40(%rbp)
leaq 0x20(%rax), %r13
movq -0x38(%rbp), %rdi
movq %r13, %rsi
movq %r14, %rdx
callq 0x12fa4
movq -0x58(%rbp), %r14
cmpq %r12, %r14
je 0x234f0
cmpq %r15, 0x28(%r14)
jb 0x234e0
leaq 0x20(%r14), %rsi
movq %rbx, %rdi
callq 0x23b1c
movq %rax, %rdi
movq %r13, %rsi
callq 0x13fba
movq %r14, %rdi
callq 0x4410
movq %rax, %r14
cmpq %r12, %rax
jne 0x234c3
leaq -0x70(%rbp), %r14
movq %r14, %rdi
callq 0x5c7a
movq -0x40(%rbp), %rdi
callq 0x4410
cmpq -0x30(%rbp), %rax
jne 0x2348a
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x23520
movq %rax, %rbx
leaq -0x70(%rbp), %rdi
callq 0x5c7a
movq %rbx, %rdi
callq 0x4650
// File: /workspace/github_cpp_makefile_star2_O3/aalto-speech[P]ftk/src/Bigrams.cc
// Function: Bigrams::init_candidates_freq(unsigned int, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, double, 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, double>>> const&, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, double, 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, double>>>&, std::set<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::less<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&)
int
Bigrams::init_candidates_freq(unsigned int n_candidates,
                              const map<string, flt_type> &unigram_stats,
                              map<string, flt_type> &candidates,
                              const set<string> &stoplist)
{
    vector<pair<string, flt_type> > sorted_stats;
    Unigrams::sort_vocab(unigram_stats, sorted_stats, false);

    for (auto it = sorted_stats.begin(); it != sorted_stats.end(); ++it) {
        if (stoplist.find(it->first) != stoplist.end()) continue;
        candidates[it->first] = 0.0;
        if (candidates.size() >= n_candidates) break;
    }

    return candidates.size();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %r14
movq %rdx, %rbx
movq %rsi, %rax
movl %edi, %r12d
xorps %xmm0, %xmm0
leaq -0x40(%rbp), %rsi
movaps %xmm0, (%rsi)
movq $0x0, 0x10(%rsi)
movq %rax, %rdi
xorl %edx, %edx
callq 0x1dc30
movq -0x40(%rbp), %r15
cmpq -0x38(%rbp), %r15
je 0x235b0
leaq 0x8(%r14), %r13
movl %r12d, %r12d
movq %r14, %rdi
movq %r15, %rsi
callq 0x10c22
cmpq %r13, %rax
jne 0x235a6
movq %rbx, %rdi
movq %r15, %rsi
callq 0x1af86
movq $0x0, (%rax)
cmpq %r12, 0x28(%rbx)
jae 0x235b0
addq $0x28, %r15
cmpq -0x38(%rbp), %r15
jne 0x2357e
movl 0x28(%rbx), %ebx
leaq -0x40(%rbp), %rdi
callq 0x1fbf4
movl %ebx, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x235d1
jmp 0x235d1
movq %rax, %rbx
leaq -0x40(%rbp), %rdi
callq 0x1fbf4
movq %rbx, %rdi
callq 0x4650
nop
// File: /workspace/github_cpp_makefile_star2_O3/ELD[P]HackAssembler/src/parser.cpp
// Function: hack::Parser::Parser(std::istream&)
Parser::Parser(std::istream& file) : _file(file)
    {
        _pc = -1;
        _mem = 16;
        _currentCommand = "";
        _fileHead = _file.tellg();
        _lCommand.assign("\\((.*)\\)", std::regex_constants::icase);
        _aCommand.assign("\\@([\\w*|\\d*]*).*", std::regex_constants::icase);
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r13
movq %rsi, (%rdi)
leaq 0x8(%rdi), %rbx
leaq 0x18(%rdi), %rbp
movq %rbp, 0x8(%rdi)
movq $0x0, 0x10(%rdi)
movb $0x0, 0x18(%rdi)
leaq 0x28(%rdi), %r14
movl $0x10, %r12d
movl %r12d, 0x28(%rdi)
addq $0x30, %rdi
callq 0x55d0
xorps %xmm0, %xmm0
movups %xmm0, 0x38(%r13)
leaq 0x48(%r13), %r15
movl %r12d, 0x48(%r13)
leaq 0x50(%r13), %rdi
callq 0x55d0
xorps %xmm0, %xmm0
movups %xmm0, 0x58(%r13)
leaq 0x78(%r13), %r12
movq %r12, %rdi
callq 0x1701c
movabsq $0x10ffffffff, %rax     # imm = 0x10FFFFFFFF
movq %rax, 0x70(%r13)
movq 0x10(%r13), %rdx
leaq 0x107ca(%rip), %rcx     # 0x181e0
movq %rbx, %rdi
xorl %esi, %esi
xorl %r8d, %r8d
callq 0x5460
movq (%r13), %rdi
callq 0x5510
movq %rax, 0x68(%r13)
leaq 0x10731(%rip), %rsi     # 0x18168
leaq 0x10732(%rip), %rdx     # 0x18170
movq %r14, %rdi
movl $0x1, %ecx
callq 0x91ee
leaq 0x1071f(%rip), %rsi     # 0x18171
leaq 0x10728(%rip), %rdx     # 0x18181
movq %r15, %rdi
movl $0x1, %ecx
callq 0x91ee
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x7a7c
movq %rax, %r13
jmp 0x7a87
movq %rax, %r13
movq %r12, %rdi
callq 0x7124
movq %r15, %rdi
callq 0x7104
movq %r14, %rdi
callq 0x7104
movq (%rbx), %rdi
cmpq %rbp, %rdi
je 0x7aab
movq (%rbp), %rsi
incq %rsi
callq 0x52c0
movq %r13, %rdi
callq 0x5530
nop
// File: /workspace/github_cpp_makefile_star2_O3/ELD[P]HackAssembler/src/parser.cpp
// Function: hack::Parser::commandType() const
COMMAND_TYPE Parser::commandType() const
    {
        if (std::regex_match(_currentCommand, _lCommand)) {
            return L_COMMAND;
        } else if (std::regex_match(_currentCommand, _aCommand)) {
            return A_COMMAND;
        }

        return C_COMMAND;
    }

// Assembly:
pushq %rbp
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x28(%rdi), %rcx
movq 0x8(%rdi), %rdi
movq 0x10(%rbx), %rsi
addq %rdi, %rsi
xorps %xmm0, %xmm0
movq %rsp, %rdx
movaps %xmm0, 0x10(%rdx)
movaps %xmm0, (%rdx)
xorl %r8d, %r8d
callq 0x143f9
movl %eax, %ebp
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x7ce3
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x52c0
xorl %eax, %eax
testb %bpl, %bpl
jne 0x7d30
leaq 0x48(%rbx), %rcx
movq 0x8(%rbx), %rdi
movq 0x10(%rbx), %rsi
addq %rdi, %rsi
xorps %xmm0, %xmm0
movq %rsp, %rdx
movaps %xmm0, 0x10(%rdx)
movaps %xmm0, (%rdx)
xorl %r8d, %r8d
callq 0x143f9
movl %eax, %ebx
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x7d26
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x52c0
movzbl %bl, %ecx
movl $0x2, %eax
subl %ecx, %eax
addq $0x28, %rsp
popq %rbx
popq %rbp
retq
jmp 0x7d39
movq %rax, %rbx
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x7d52
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x52c0
movq %rbx, %rdi
callq 0x5530
// File: /workspace/github_cpp_makefile_star2_O3/ELD[P]HackAssembler/src/parser.cpp
// Function: hack::Parser::trimCommand(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&)
void Parser::trimCommand(std::string& commandToTrim)
    {
        if (commandToTrim.size() > 0) {
            auto firstPos = commandToTrim.find_first_not_of(' ');
            auto lastPos = commandToTrim.find_last_not_of(' ');
            commandToTrim = commandToTrim.substr(firstPos, (lastPos - firstPos + 1));

            commandToTrim.erase(std::remove(commandToTrim.begin(), commandToTrim.end(), '\r'), commandToTrim.end());
        }
    }

// Assembly:
cmpq $0x0, 0x8(%rsi)
je 0x7dff
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rsi, %rbx
movq %rsi, %rdi
movl $0x20, %esi
xorl %edx, %edx
callq 0x5280
movq %rax, %r14
movq %rbx, %rdi
movl $0x20, %esi
movq $-0x1, %rdx
callq 0x51f0
subq %r14, %rax
leaq 0x1(%rax), %rcx
movq %rsp, %r15
movq %r15, %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x52f0
movq %rbx, %rdi
movq %r15, %rsi
callq 0x5370
movq (%r15), %rdi
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x7dd4
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x52c0
movq (%rbx), %rdi
movq 0x8(%rbx), %rsi
addq %rdi, %rsi
movq %rsp, %rdx
movb $0xd, (%rdx)
callq 0x16b01
movq %rax, %rcx
subq (%rbx), %rcx
movq %rcx, 0x8(%rbx)
movb $0x0, (%rax)
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/ELD[P]HackAssembler/src/parser.cpp
// Function: hack::Parser::getSymbol[abi:cxx11]()
std::string Parser::getSymbol()
    {
        if (commandType() == A_COMMAND) {
            auto first = _currentCommand.find_first_not_of("@");
            return _currentCommand.substr(first);
        } else if (commandType() == L_COMMAND) {
            auto first = _currentCommand.find_first_not_of("(");
            auto second = _currentCommand.find_last_not_of(")");
            return _currentCommand.substr(first, second - first + 1);
        }

        return "";
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x7c9e
cmpl $0x1, %eax
jne 0x7f0e
addq $0x8, %r14
leaq 0x102a0(%rip), %rsi     # 0x1818d
movl $0x1, %ecx
movq %r14, %rdi
xorl %edx, %edx
callq 0x54e0
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
movq $-0x1, %rcx
jmp 0x7f7d
movq %r14, %rdi
callq 0x7c9e
testl %eax, %eax
je 0x7f35
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
leaq 0x102b8(%rip), %rdx     # 0x181e0
movq %rbx, %rdi
movq %rdx, %rsi
callq 0x72ac
jmp 0x7f82
addq $0x8, %r14
leaq 0x1024f(%rip), %rsi     # 0x1818f
movl $0x1, %ecx
movq %r14, %rdi
xorl %edx, %edx
callq 0x54e0
movq %rax, %r15
leaq 0x10ae9(%rip), %rsi     # 0x18a42
movl $0x1, %ecx
movq %r14, %rdi
movq $-0x1, %rdx
callq 0x5480
subq %r15, %rax
leaq 0x1(%rax), %rcx
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x52f0
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/ELD[P]HackAssembler/src/parser.cpp
// Function: hack::Parser::getDestBits[abi:cxx11]()
std::string Parser::getDestBits()
    {
        if (commandType() != C_COMMAND) {
            return "";
        }


        auto index = _currentCommand.find("=");

        if (index == std::string::npos) {
            return DestTable::lookup[""];
        }

        auto dest = _currentCommand.substr(0, index);

        return DestTable::lookup[dest];
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x7c9e
cmpl $0x2, %eax
jne 0x8013
addq $0x8, %r14
leaq 0x101de(%rip), %rsi     # 0x18191
movl $0x1, %ecx
movq %r14, %rdi
xorl %edx, %edx
callq 0x5520
cmpq $-0x1, %rax
je 0x802e
movq %rsp, %r15
movq %r15, %rdi
movq %r14, %rsi
xorl %edx, %edx
movq %rax, %rcx
callq 0x52f0
leaq 0x1a746(%rip), %rdi     # 0x22728
movq %r15, %rsi
callq 0x8dde
leaq 0x10(%rbx), %rcx
movq %rcx, (%rbx)
movq (%rax), %rsi
movq 0x8(%rax), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x7216
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
jne 0x807a
jmp 0x8087
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
leaq 0x101bf(%rip), %rdx     # 0x181e0
movq %rbx, %rdi
movq %rdx, %rsi
callq 0x72ac
jmp 0x8087
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x101a2(%rip), %rdx     # 0x181e0
movq %rsp, %rdi
movq %rdx, %rsi
callq 0x72ac
leaq 0x1a6d8(%rip), %rdi     # 0x22728
movq %rsp, %rsi
callq 0x8d62
leaq 0x10(%rbx), %rcx
movq %rcx, (%rbx)
movq (%rax), %rsi
movq 0x8(%rax), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x7216
movq (%rsp), %rdi
cmpq %r14, %rdi
je 0x8087
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x52c0
movq %rbx, %rax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
jmp 0x80c5
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r14, %rdi
jne 0x80b8
jmp 0x80c5
movq %rax, %rbx
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x80c5
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x52c0
movq %rbx, %rdi
callq 0x5530
nop
// File: /workspace/github_cpp_makefile_star2_O3/ELD[P]HackAssembler/src/parser.cpp
// Function: hack::Parser::getJumpBits[abi:cxx11]()
std::string Parser::getJumpBits()
    {
        if (commandType() != C_COMMAND) {
            return "";
        }

        auto semiColonPos = _currentCommand.find(";");

        if (semiColonPos == std::string::npos) {
            return JumpTable::lookup[""];
        }

        auto jump = _currentCommand.substr(semiColonPos + 1);

        return JumpTable::lookup[jump];
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x7c9e
cmpl $0x2, %eax
jne 0x83a3
addq $0x8, %r14
leaq 0xfe58(%rip), %rsi      # 0x18193
movl $0x1, %ecx
movq %r14, %rdi
xorl %edx, %edx
callq 0x5520
cmpq $-0x1, %rax
je 0x83be
incq %rax
movq %rsp, %r15
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
movq $-0x1, %rcx
callq 0x52f0
leaq 0x1a46e(%rip), %rdi     # 0x227e0
movq %r15, %rsi
callq 0x8dde
leaq 0x10(%rbx), %rcx
movq %rcx, (%rbx)
movq (%rax), %rsi
movq 0x8(%rax), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x7216
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
jne 0x840a
jmp 0x8417
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
leaq 0xfe2f(%rip), %rdx      # 0x181e0
movq %rbx, %rdi
movq %rdx, %rsi
callq 0x72ac
jmp 0x8417
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0xfe12(%rip), %rdx      # 0x181e0
movq %rsp, %rdi
movq %rdx, %rsi
callq 0x72ac
leaq 0x1a400(%rip), %rdi     # 0x227e0
movq %rsp, %rsi
callq 0x8d62
leaq 0x10(%rbx), %rcx
movq %rcx, (%rbx)
movq (%rax), %rsi
movq 0x8(%rax), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x7216
movq (%rsp), %rdi
cmpq %r14, %rdi
je 0x8417
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x52c0
movq %rbx, %rax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
jmp 0x8455
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r14, %rdi
jne 0x8448
jmp 0x8455
movq %rax, %rbx
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x8455
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x52c0
movq %rbx, %rdi
callq 0x5530
nop
// File: /workspace/github_cpp_makefile_star2_O3/ELD[P]HackAssembler/src/parser.cpp
// Function: hack::Parser::collectLabels()
void Parser::collectLabels()
    {
        while (advance()) {
            if (commandType() == L_COMMAND) {
                if (_symbols.contains(getSymbol())) {
                    continue;
                }

                _symbols.addSymbol(getSymbol(), _pc);
            }
        }

        rewind();
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
callq 0x7ac8
testb %al, %al
je 0x8548
leaq 0x78(%rbx), %r14
leaq 0x10(%rsp), %r12
movq %rsp, %r15
movq %rbx, %rdi
callq 0x7c9e
testl %eax, %eax
jne 0x853c
movq %r15, %rdi
movq %rbx, %rsi
callq 0x7eca
movq %r14, %rdi
movq %r15, %rsi
callq 0x173b6
movl %eax, %ebp
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x8508
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x52c0
testb %bpl, %bpl
jne 0x853c
movq %r15, %rdi
movq %rbx, %rsi
callq 0x7eca
movl 0x70(%rbx), %edx
movq %r14, %rdi
movq %r15, %rsi
callq 0x17332
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x853c
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x52c0
movq %rbx, %rdi
callq 0x7ac8
testb %al, %al
jne 0x84ce
movq %rbx, %rdi
callq 0x8482
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0x855f
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x8578
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x52c0
movq %rbx, %rdi
callq 0x5530
// File: /workspace/github_cpp_makefile_star2_O3/Thomas1995[P]Rentz/src/bots/bot.cpp
// Function: Bot::Init(int, int)
void Bot::Init(int index, int players) {
	debug("Getting initialized\n");

	this->index = index;
	this->playersCount = players;
	scores.resize(players, 0);

	if(games.empty())
	for(int i = 1; i <= MinigameCount; ++i)
		games.push_back(static_cast<Minigame>(i));
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebp
movl %esi, %r14d
movq %rdi, %rbx
movq 0xfbaa(%rip), %r15      # 0x12fd0
movq (%r15), %rcx
leaq 0x9c46(%rip), %rdi      # 0xd076
pushq $0x14
popq %rsi
pushq $0x1
popq %rdx
callq 0x33e0
movq (%r15), %rdi
callq 0x32b0
movl %r14d, 0xc(%rbx)
movl %ebp, 0x8(%rbx)
leaq 0x38(%rbx), %rdi
movslq %ebp, %rsi
leaq 0x4(%rsp), %rdx
andl $0x0, (%rdx)
callq 0x43ca
movq 0x68(%rbx), %rax
cmpq 0x70(%rbx), %rax
jne 0x349d
leaq 0x68(%rbx), %r14
pushq $0x1
popq %rbp
movq %rsp, %r15
movl %ebp, (%rsp)
movq 0x70(%rbx), %rsi
cmpq 0x78(%rbx), %rsi
je 0x348b
movl %ebp, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x70(%rbx)
jmp 0x3496
movq %r14, %rdi
movq %r15, %rdx
callq 0x4fc0
incl %ebp
cmpl $0x8, %ebp
jne 0x3472
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/Thomas1995[P]Rentz/src/bots/bot.cpp
// Function: Bot::PlayCard()
Card Bot::PlayCard() {
	// Play a card and erase it from your hand

	//TODO: Remove this line
	dumpInfo();

  Card use = onPlayCard();
  hand.erase(find(hand.begin(), hand.end(), use)); //TODO: Check if card in hand
  return use;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x34a8
movq (%rbx), %rax
movq %r14, %rdi
movq %rbx, %rsi
callq *0x30(%rax)
movq 0x50(%rbx), %rdi
movq 0x58(%rbx), %rsi
movq %r14, %rdx
callq 0x52ee
addq $0x8, %rax
movq 0x58(%rbx), %rdx
cmpq %rdx, %rax
je 0x37d5
movq %rdx, %rcx
subq %rax, %rcx
sarq $0x3, %rcx
testq %rcx, %rcx
jle 0x37d5
incq %rcx
movb 0x4(%rax), %dl
movb %dl, -0x4(%rax)
movl (%rax), %edx
movl %edx, -0x8(%rax)
addq $0x8, %rax
decq %rcx
cmpq $0x1, %rcx
ja 0x37b9
movq 0x58(%rbx), %rdx
addq $-0x8, %rdx
movq %rdx, 0x58(%rbx)
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/Thomas1995[P]Rentz/src/bots/bot.cpp
// Function: Bot::ChooseMinigame()
Minigame Bot::ChooseMinigame() {
	// Choose a minigame
	Minigame game = onChooseMinigame();
	auto it = find(games.begin(), games.end(), game);

	assert(it != games.end());

	games.erase(it); //TODO: Check if game in games

	return game;
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movq (%rdi), %rax
callq *0x18(%rax)
leaq 0xc(%rsp), %rdx
movl %eax, (%rdx)
movq 0x68(%rbx), %rdi
movq 0x70(%rbx), %rsi
callq 0x5249
movq 0x70(%rbx), %rdx
cmpq %rdx, %rax
je 0x4235
leaq 0x4(%rax), %rsi
cmpq %rdx, %rsi
je 0x4223
subq %rsi, %rdx
movq %rax, %rdi
callq 0x3380
movq 0x70(%rbx), %rdx
addq $-0x4, %rdx
movq %rdx, 0x70(%rbx)
movl 0xc(%rsp), %eax
addq $0x10, %rsp
popq %rbx
retq
leaq 0x8ee1(%rip), %rdi      # 0xd11d
leaq 0x8eec(%rip), %rsi      # 0xd12f
leaq 0x8eed(%rip), %rcx      # 0xd137
movl $0x39, %edx
callq 0x3160
// File: /workspace/github_cpp_makefile_star2_O3/Thomas1995[P]Rentz/src/bots/bot.cpp
// Function: Bot::RoundEnd(std::vector<int, std::allocator<int>>)
void Bot::RoundEnd(std::vector<int> scores) {
	// Round ended; empty your hand, update scores

	hand.clear();
	cardsOnTable.clear();
	this->scores = scores;

	onRoundEnd();
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq 0x50(%rdi), %rax
cmpq %rax, 0x58(%rdi)
je 0x4272
movq %rax, 0x58(%rbx)
movq 0x80(%rbx), %rax
cmpq %rax, 0x88(%rbx)
je 0x4289
movq %rax, 0x88(%rbx)
leaq 0x38(%rbx), %rdi
callq 0x44fa
movq (%rbx), %rax
movq %rbx, %rdi
popq %rbx
jmpq *0x38(%rax)
// File: /workspace/github_cpp_makefile_star2_O3/Thomas1995[P]Rentz/src/util/card.cpp
// Function: Card::to_string[abi:cxx11]() const
std::string Card::to_string() const {
    std::string s;

    switch(value) {
        case 10: s += "10"; break;
        case 11: s += "J"; break;
        case 12: s += "Q"; break;
        case 13: s += "K"; break;
        case 14: s += "A"; break;
        default: s += (char)(value + '0'); break;
    }

    s += suite;

    return s;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x10(%rdi), %r15
movq %r15, (%rdi)
movq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
movl (%rsi), %eax
leal -0xa(%rax), %ecx
cmpl $0x5, %ecx
jae 0x571a
movl %ecx, %eax
leaq 0x7b2f(%rip), %rcx      # 0xd238
movslq (%rcx,%rax,4), %rsi
addq %rcx, %rsi
movq %rbx, %rdi
callq 0x33d0
jmp 0x5727
addb $0x30, %al
movsbl %al, %esi
movq %rbx, %rdi
callq 0x31d0
movsbl 0x4(%r14), %esi
movq %rbx, %rdi
callq 0x31d0
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
movq (%rbx), %rdi
cmpq %r15, %rdi
je 0x5753
movq (%r15), %rsi
incq %rsi
callq 0x3240
movq %r14, %rdi
callq 0x33a0
nop
// File: /workspace/github_cpp_makefile_star2_O3/Thomas1995[P]Rentz/src/util/card.cpp
// Function: Card::suiteIndex() const
int Card::suiteIndex() const {
  for(int i = 0; i < 4; ++i) {
    if(suites[i] == suite)
      return i;
  }
  assert(false);
}

// Assembly:
movb 0x4(%rdi), %cl
xorl %eax, %eax
leaq 0x7976(%rip), %rdx      # 0xd230
cmpb %cl, (%rax,%rdx)
je 0x58e8
incq %rax
cmpq $0x4, %rax
jne 0x58ba
pushq %rax
leaq 0x7931(%rip), %rdi      # 0xd201
leaq 0x7930(%rip), %rsi      # 0xd207
leaq 0x7932(%rip), %rcx      # 0xd210
movl $0x3f, %edx
callq 0x3160
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Thomas1995[P]Rentz/src/util/card.cpp
// Function: Card::encode() const
uint8_t Card::encode() const {
  uint8_t ret = value;
  //the last 4 bits represent the value
  ret |= suiteIndex() << 4;
  //the next 2 bits represent the suite
  return ret;
}

// Assembly:
pushq %rbx
movl (%rdi), %ebx
callq 0x58ae
shll $0x4, %eax
orl %ebx, %eax
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Thomas1995[P]Rentz/src/util/card.cpp
// Function: Card::getAllCards()
std::vector<Card> Card::getAllCards() {
      std::vector<Card> allCards;

      for(int i=lowestCard;i<=14;++i)
          for(char j=0;j<4;++j)
            allCards.push_back(Card(i, Card::suites[(int)j]));

      return allCards;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movl 0xd8fb(%rip), %ebp      # 0x13218
cmpl $0xe, %ebp
jg 0x595b
leaq 0x7907(%rip), %r15      # 0xd230
leaq 0x8(%rsp), %r14
xorl %r12d, %r12d
movsbl (%r12,%r15), %edx
movq %r14, %rdi
movl %ebp, %esi
callq 0x53e0
movq %rbx, %rdi
movq %r14, %rsi
callq 0x59f8
incq %r12
cmpq $0x4, %r12
jne 0x5931
incl %ebp
cmpl $0xf, %ebp
jne 0x592e
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x5982
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
callq 0x3240
movq %r14, %rdi
callq 0x33a0
// File: /workspace/github_cpp_makefile_star2_O3/Thomas1995[P]Rentz/src/./event.h
// Function: event::init(unsigned char*)
void init(uint8_t *ptr) {
    assert(ptr[0] == FLAG);
    //first FLAG should mark the frame's beginning
    
    ++ptr;

    type = getInt(ptr);
    ptr += 4;
    len = getInt(ptr);
    ptr += 4;

    data = new uint8_t[len];
    uint8_t * at = (uint8_t *)ptr;

    for(size_t i = 0; i < len; ++i) {
      data[i] = *at;
      ++at;
    }

    assert(*at == FLAG);
    //last FLAG should mark the frame's end
  }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
cmpb $0x7e, (%rsi)
jne 0x5fda
movq %rsi, %rbx
movq %rdi, %r14
movl 0x1(%rsi), %eax
bswapl %eax
movl %eax, (%rdi)
movl 0x5(%rsi), %ebp
movl %ebp, %edi
bswapl %edi
movq %rdi, 0x8(%r14)
addq $0x9, %rbx
callq 0x3030
movq %rax, 0x10(%r14)
testl %ebp, %ebp
je 0x5fd0
xorl %eax, %eax
movb (%rbx,%rax), %cl
movq 0x10(%r14), %rdx
movb %cl, (%rdx,%rax)
incq %rax
cmpq 0x8(%r14), %rax
jb 0x5fba
addq %rax, %rbx
cmpb $0x7e, (%rbx)
jne 0x5ff9
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x73ac(%rip), %rdi      # 0xd38d
leaq 0x73b4(%rip), %rsi      # 0xd39c
leaq 0x73b7(%rip), %rcx      # 0xd3a6
movl $0x70, %edx
callq 0x3160
leaq 0x73c2(%rip), %rdi      # 0xd3c2
leaq 0x7395(%rip), %rsi      # 0xd39c
leaq 0x7398(%rip), %rcx      # 0xd3a6
movl $0x82, %edx
callq 0x3160
// File: /workspace/github_cpp_makefile_star2_O3/Thomas1995[P]Rentz/src/client.cpp
// Function: addOptions(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::unordered_map<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::hash<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>, std::equal_to<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::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, 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&)
bool
addOptions(std::vector<std::string> &args,
    std::unordered_map<std::string, std::string> &opts,
    const std::string &opt_name,
    const std::vector<std::string> &aliases) {

  std::string s = args.back();

  if(!in(s, aliases))
    return false;

  args.pop_back();

  if(args.empty())
    return false;

  opts[opt_name] = args.back();

  args.pop_back();
  return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, %r12
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq 0x8(%rdi), %rax
leaq 0x18(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq -0x20(%rax), %rsi
movq -0x18(%rax), %rdx
addq %rsi, %rdx
leaq 0x8(%rsp), %r13
movq %r13, %rdi
callq 0x47f4
movq (%r12), %rdi
movq 0x8(%r12), %rsi
movq %r13, %rdx
callq 0xc267
cmpq 0x8(%r12), %rax
je 0x6402
movq 0x8(%rbx), %rax
leaq -0x20(%rax), %r12
movq %r12, 0x8(%rbx)
movq -0x20(%rax), %rdi
addq $-0x10, %rax
cmpq %rax, %rdi
je 0x63bb
movq (%rax), %rsi
incq %rsi
callq 0x3240
movq 0x8(%rbx), %r12
cmpq %r12, (%rbx)
je 0x6402
movq %r15, %rdi
movq %r14, %rsi
callq 0xc38e
addq $-0x20, %r12
movq %rax, %rdi
movq %r12, %rsi
callq 0x3130
movq 0x8(%rbx), %rax
leaq -0x20(%rax), %rcx
movq %rcx, 0x8(%rbx)
movq -0x20(%rax), %rdi
addq $-0x10, %rax
movb $0x1, %bl
cmpq %rax, %rdi
je 0x6404
movq (%rax), %rsi
incq %rsi
callq 0x3240
jmp 0x6404
xorl %ebx, %ebx
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x641b
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x3240
movl %ebx, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x6446
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x3240
movq %rbx, %rdi
callq 0x33a0
// File: /workspace/github_cpp_makefile_star2_O3/Thomas1995[P]Rentz/src/client.cpp
// Function: Client::handshake(char*)
void handshake(char *name) {

    event e = readEvent();
    assert(e.type = event::EType::HANDSHAKE);
    uint8_t playerCount = e.data[0];
    e.free();

    e.len = strlen(name);
    e.data = reinterpret_cast<uint8_t *>(name);

    e.send(sfd);


    e = readEvent();
    assert(e.type == event::EType::SEND_INIT);
    assert(e.len == 4);

    index = ntohl(*(reinterpret_cast<uint32_t *>(e.data)));

    e.free();
    e.len = 0;
    e.data = NULL;
    e.send(sfd);

    printf("Our index is %d\n", index);

    //Initialize bot
    bot->Init(index, playerCount);
  }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x38, %rsp
movq %rsi, %r15
movq %rdi, %rbx
movq %rsp, %r14
movq %r14, %rdi
movq %rbx, %rsi
callq 0x5e92
movl $0x9, (%r14)
movq 0x10(%r14), %rdi
movzbl (%rdi), %ebp
callq 0x32f0
movq %r15, %rdi
callq 0x30f0
movq %rax, 0x8(%r14)
movq %r15, 0x10(%r14)
movl 0x201c(%rbx), %esi
movq %r14, %rdi
callq 0x80fe
leaq 0x20(%rsp), %r15
movq %r15, %rdi
movq %rbx, %rsi
callq 0x5e92
movq 0x10(%r15), %rax
movq %rax, 0x10(%r14)
movups (%r15), %xmm0
movaps %xmm0, (%r14)
cmpl $0x8, (%r14)
jne 0x805b
cmpq $0x4, 0x8(%rsp)
jne 0x807a
leaq 0x8(%rsp), %r14
movq 0x8(%r14), %rdi
movl (%rdi), %eax
bswapl %eax
movl %eax, 0x2020(%rbx)
callq 0x32f0
xorps %xmm0, %xmm0
movups %xmm0, (%r14)
movl 0x201c(%rbx), %esi
movq %rsp, %rdi
callq 0x80fe
movl 0x2020(%rbx), %esi
leaq 0x5759(%rip), %rdi      # 0xd78e
xorl %eax, %eax
callq 0x3050
movq 0x2028(%rbx), %rdi
movl 0x2020(%rbx), %esi
movl %ebp, %edx
callq 0x3410
addq $0x38, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x56ff(%rip), %rdi      # 0xd761
leaq 0x56ce(%rip), %rsi      # 0xd737
leaq 0x56d2(%rip), %rcx      # 0xd742
movl $0xfa, %edx
callq 0x3160
leaq 0x5702(%rip), %rdi      # 0xd783
leaq 0x56af(%rip), %rsi      # 0xd737
leaq 0x56b3(%rip), %rcx      # 0xd742
movl $0xfb, %edx
callq 0x3160
nop
// File: /workspace/github_cpp_makefile_star2_O3/Thomas1995[P]Rentz/src/./event.h
// Function: event::getCards()
std::vector<Card> getCards() {
		std::vector<Card> cards;

		for(uint32_t i = 0; i < len; ++i)
      cards.emplace_back(data[i]);

		return cards;
  }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
cmpq $0x0, 0x8(%rsi)
je 0x80d6
movq %rsi, %r14
movl $0x1, %ebp
xorl %esi, %esi
addq 0x10(%r14), %rsi
movq %rbx, %rdi
callq 0xbebe
movl %ebp, %esi
incl %ebp
cmpq %rsi, 0x8(%r14)
ja 0x80c0
movq %rbx, %rax
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %r14
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x80f5
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
callq 0x3240
movq %r14, %rdi
callq 0x33a0
nop
// File: /workspace/github_cpp_makefile_star2_O3/tonymugen[P]sampleSNPs/sampleSNPs.cpp
// Function: parseCL(int&, char**, std::unordered_map<char, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::hash<char>, std::equal_to<char>, std::allocator<std::pair<char const, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>&)
void parseCL(int &argc, char **argv, unordered_map<char, string> &cli){
	// set to true after encountering a flag token (the character after the dash)
	bool val = false;
	// store the token value here
	char curFlag;

	for (int iArg = 1; iArg < argc; iArg++) {
		const char *pchar = argv[iArg];

		if (pchar[0] == '-') { // encountered the dash, look for the token after it
			if (!pchar[1]) {
				cerr << "WARNING: forgot character after dash. Ignoring." << endl;
				continue;
			}
			// what follows the dash?
			val     = true;
			curFlag = pchar[1];

		} else {
			if (val) {
				val = false;
				cli[curFlag] = pchar;
			} else {
				cerr << "WARNING: command line value " << pchar << " ignored because it is not preceded by a flag" << endl;
			}

		}

	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, 0x10(%rsp)
cmpl $0x2, (%rdi)
jl 0x5075
movq %rsi, %rbx
movq %rdi, %r12
movl $0x1, %r14d
xorl %ebp, %ebp
movq (%rbx,%r14,8), %r13
cmpb $0x2d, (%r13)
jne 0x4f69
movb 0x1(%r13), %al
testb %al, %al
je 0x5023
movb %al, 0xf(%rsp)
movb $0x1, %bpl
jmp 0x5065
testb $0x1, %bpl
je 0x4fb3
movq 0x10(%rsp), %rdi
leaq 0xf(%rsp), %rsi
callq 0x7818
movq %rax, %rbp
movq %r12, %r15
movq %rbx, %r12
movq 0x8(%rax), %rbx
movq %r13, %rdi
callq 0x4120
movq %rbp, %rdi
xorl %ebp, %ebp
xorl %esi, %esi
movq %rbx, %rdx
movq %r12, %rbx
movq %r15, %r12
movq %r13, %rcx
movq %rax, %r8
callq 0x4430
jmp 0x5065
movl $0x1c, %edx
movq 0x1b031(%rip), %r15     # 0x1fff0
movq %r15, %rdi
leaq 0x1306b(%rip), %rsi     # 0x18034
callq 0x42f0
movq %r13, %rdi
callq 0x4120
movq %r15, %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0x42f0
movl $0x2d, %edx
movq %r15, %rdi
leaq 0x1305e(%rip), %rsi     # 0x18051
callq 0x42f0
movq (%r15), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x4290
movsbl %al, %esi
movq %r15, %rdi
callq 0x4040
movq %rax, %rdi
callq 0x41b0
xorl %ebp, %ebp
jmp 0x5065
movl $0x2f, %edx
movq 0x1afc1(%rip), %r15     # 0x1fff0
movq %r15, %rdi
leaq 0x12fcb(%rip), %rsi     # 0x18004
callq 0x42f0
movq (%r15), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x4290
movsbl %al, %esi
movq %r15, %rdi
callq 0x4040
movq %rax, %rdi
callq 0x41b0
incq %r14
movslq (%r12), %rax
cmpq %rax, %r14
jl 0x4f46
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/tonymugen[P]sampleSNPs/varfiles.cpp
// Function: sampFiles::GbinFileI::_numLines()
uint64_t GbinFileI::_numLines(){

    if (_varFile.is_open()) {
        _varFile.close();
    }
    try {
        _varFile.open(_fileName.c_str(), ios::in | ios::binary | ios::ate);
		if (!_varFile.is_open()) {
			cerr << "ERROR: failed to open file " << _fileName << " for input" << endl;
			exit(2);
		}

    } catch (system_error &error) {
        cerr << "ERROR: cannot open binary file " << _fileName << " for input: " << error.code().message() << flush;
        perror(" ");
        exit(1);

    }
    size_t Ntot = _varFile.tellg();
    _varFile.close();
    if (Ntot % (_elemSize*_nCols)) {
        throw string("Number of elements not divisible by row size");
    }
    return Ntot/(_elemSize*_nCols);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
leaq 0x8(%rdi), %r14
leaq 0x88(%rdi), %r15
movq %r15, %rdi
callq 0x40a0
testb %al, %al
je 0x7bcb
movq %r14, %rdi
callq 0x4060
movq 0x218(%rbx), %rsi
movq %r14, %rdi
movl $0xe, %edx
callq 0x4270
movq %r15, %rdi
callq 0x40a0
testb %al, %al
je 0x7c24
movq %r14, %rdi
callq 0x44c0
movq %rax, %r15
movq %r14, %rdi
callq 0x4060
movq 0x238(%rbx), %rcx
imulq 0x240(%rbx), %rcx
movq %r15, %rax
xorl %edx, %edx
divq %rcx
testq %rdx, %rdx
jne 0x7c7f
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq 0x183c5(%rip), %rdi     # 0x1fff0
leaq 0x1091e(%rip), %rsi     # 0x18550
movl $0x1b, %edx
callq 0x42f0
movq 0x218(%rbx), %rsi
movq 0x220(%rbx), %rdx
movq 0x1839f(%rip), %rdi     # 0x1fff0
callq 0x42f0
movq %rax, %r14
leaq 0x1090c(%rip), %rsi     # 0x1856c
movl $0xa, %edx
movq %rax, %rdi
callq 0x42f0
movq %r14, %rdi
callq 0x4130
movl $0x2, %edi
callq 0x4320
movl $0x20, %edi
callq 0x4140
movq %rax, %rbx
addq $0x10, %rax
movq %rax, (%rbx)
leaq 0x108fd(%rip), %rsi     # 0x18597
leaq 0x10922(%rip), %rdx     # 0x185c3
movq %rbx, %rdi
callq 0x7b0a
leaq 0x17c10(%rip), %rsi     # 0x1f8c0
movq 0x18309(%rip), %rdx     # 0x1ffc0
movq %rbx, %rdi
callq 0x44b0
movq %rax, %r14
movq %rbx, %rdi
callq 0x41f0
jmp 0x7d8b
movq %rax, %r14
cmpl $0x1, %edx
jne 0x7d8b
movq %r14, %rdi
callq 0x4110
movq %rax, %r14
movq 0x18303(%rip), %rdi     # 0x1fff0
leaq 0x10883(%rip), %rsi     # 0x18577
movl $0x1f, %edx
callq 0x42f0
movq 0x218(%rbx), %rsi
movq 0x220(%rbx), %rdx
movq 0x182dd(%rip), %rdi     # 0x1fff0
callq 0x42f0
movq %rax, %rbx
leaq 0x10cdb(%rip), %rsi     # 0x189fd
movl $0xc, %edx
movq %rax, %rdi
callq 0x42f0
movq 0x18(%r14), %rsi
movl 0x10(%r14), %edx
movq (%rsi), %rax
movq %rsp, %rdi
callq *0x20(%rax)
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x42f0
movq %rax, %rdi
callq 0x41b0
movq %rsp, %rdi
callq 0x4571
movq %rax, %r14
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x7d86
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42d0
jmp 0x7d86
jmp 0x7d83
movq %rax, %r14
callq 0x4480
movq %r14, %rdi
callq 0x44e0
movq %rax, %rdi
callq 0x76d8
nop
// File: /workspace/github_cpp_makefile_star2_O3/tonymugen[P]sampleSNPs/varfiles.cpp
// Function: sampFiles::GbinFileI::open()
void GbinFileI::open(){
    if (_varFile.is_open()) {
        _varFile.close();
    }
    try {
        _varFile.open(_fileName.c_str(), ios::in | ios::binary);
		if (!_varFile.is_open()) {
			cerr << "ERROR: failed to open file " << _fileName << " for input" << endl;
			exit(2);
		}

    } catch (system_error &error) {
        cerr << "ERROR: cannot open binary file " << _fileName << " for input: " << error.code().message() << flush;
        perror(" ");
        exit(1);
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
leaq 0x8(%rdi), %r15
leaq 0x88(%rdi), %r14
movq %r14, %rdi
callq 0x40a0
testb %al, %al
je 0x7deb
movq %r15, %rdi
callq 0x4060
movq 0x218(%rbx), %rsi
movq %r15, %rdi
movl $0xc, %edx
callq 0x4270
movq %r14, %rdi
callq 0x40a0
testb %al, %al
je 0x7e15
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq 0x181d4(%rip), %rdi     # 0x1fff0
leaq 0x1072d(%rip), %rsi     # 0x18550
movl $0x1b, %edx
callq 0x42f0
movq 0x218(%rbx), %rsi
movq 0x220(%rbx), %rdx
movq 0x181ae(%rip), %rdi     # 0x1fff0
callq 0x42f0
movq %rax, %r14
leaq 0x1071b(%rip), %rsi     # 0x1856c
movl $0xa, %edx
movq %rax, %rdi
callq 0x42f0
movq %r14, %rdi
callq 0x4130
movl $0x2, %edi
callq 0x4320
movq %rax, %r14
cmpl $0x1, %edx
jne 0x7f2c
movq %r14, %rdi
callq 0x4110
movq %rax, %r14
movq 0x18162(%rip), %rdi     # 0x1fff0
leaq 0x106e2(%rip), %rsi     # 0x18577
movl $0x1f, %edx
callq 0x42f0
movq 0x218(%rbx), %rsi
movq 0x220(%rbx), %rdx
movq 0x1813c(%rip), %rdi     # 0x1fff0
callq 0x42f0
movq %rax, %rbx
leaq 0x10b3a(%rip), %rsi     # 0x189fd
movl $0xc, %edx
movq %rax, %rdi
callq 0x42f0
movq 0x18(%r14), %rsi
movl 0x10(%r14), %edx
movq (%rsi), %rax
movq %rsp, %rdi
callq *0x20(%rax)
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x42f0
movq %rax, %rdi
callq 0x41b0
movq %rsp, %rdi
callq 0x458b
movq %rax, %r14
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x7f27
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42d0
jmp 0x7f27
jmp 0x7f24
movq %rax, %r14
callq 0x4480
movq %r14, %rdi
callq 0x44e0
movq %rax, %rdi
callq 0x76d8
// File: /workspace/github_cpp_makefile_star2_O3/tonymugen[P]sampleSNPs/varfiles.cpp
// Function: sampFiles::GbinFileO::open()
void GbinFileO::open(){
    if (_varFile.is_open()) {
        _varFile.close();
    }
    try {
        _varFile.open(_fileName.c_str(), ios::out | ios::binary);
		if (!_varFile.is_open()) {
			cerr << "ERROR: failed to open file " << _fileName << " for output" << endl;
			exit(2);
		}

    } catch (system_error &error) {
        cerr << "ERROR: cannot open binary file " << _fileName << " for output: " << error.code().message() << flush;
        perror(" ");
        exit(1);

    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
leaq 0x8(%rdi), %r15
leaq 0x88(%rdi), %r14
movq %r14, %rdi
callq 0x40a0
testb %al, %al
je 0x89c1
movq %r15, %rdi
callq 0x4060
movq 0x218(%rbx), %rsi
movq %r15, %rdi
movl $0x14, %edx
callq 0x4270
movq %r14, %rdi
callq 0x40a0
testb %al, %al
je 0x89eb
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq 0x175fe(%rip), %rdi     # 0x1fff0
leaq 0xfb57(%rip), %rsi      # 0x18550
movl $0x1b, %edx
callq 0x42f0
movq 0x218(%rbx), %rsi
movq 0x220(%rbx), %rdx
movq 0x175d8(%rip), %rdi     # 0x1fff0
callq 0x42f0
movq %rax, %r14
leaq 0xfcbb(%rip), %rsi      # 0x186e2
movl $0xb, %edx
movq %rax, %rdi
callq 0x42f0
movq %r14, %rdi
callq 0x4130
movl $0x2, %edi
callq 0x4320
movq %rax, %r14
cmpl $0x1, %edx
jne 0x8b02
movq %r14, %rdi
callq 0x4110
movq %rax, %r14
movq 0x1758c(%rip), %rdi     # 0x1fff0
leaq 0xfb0c(%rip), %rsi      # 0x18577
movl $0x1f, %edx
callq 0x42f0
movq 0x218(%rbx), %rsi
movq 0x220(%rbx), %rdx
movq 0x17566(%rip), %rdi     # 0x1fff0
callq 0x42f0
movq %rax, %rbx
leaq 0xfc55(%rip), %rsi      # 0x186ee
movl $0xd, %edx
movq %rax, %rdi
callq 0x42f0
movq 0x18(%r14), %rsi
movl 0x10(%r14), %edx
movq (%rsi), %rax
movq %rsp, %rdi
callq *0x20(%rax)
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x42f0
movq %rax, %rdi
callq 0x41b0
movq %rsp, %rdi
callq 0x460d
movq %rax, %r14
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x8afd
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42d0
jmp 0x8afd
jmp 0x8afa
movq %rax, %r14
callq 0x4480
movq %r14, %rdi
callq 0x44e0
movq %rax, %rdi
callq 0x76d8
// File: /workspace/github_cpp_makefile_star2_O3/tonymugen[P]sampleSNPs/varfiles.cpp
// Function: sampFiles::BedFile::BedFile(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
BedFile::BedFile(const string &stubName) : GbinFile(), _fileStub{stubName} {
	_fileName = _fileStub + ".bed";
    _bimFile.exceptions(fstream::badbit);
	_famFile.exceptions(fstream::badbit);
    // _elemSize is set to sizeof(char) in the GbinFile default constructor
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r13
movq %rdi, %rbx
callq 0x7648
leaq 0x228(%rbx), %rax
movq %rax, 0x218(%rbx)
xorl %eax, %eax
movq %rax, 0x220(%rbx)
movb $0x0, 0x228(%rbx)
movq %rax, 0x238(%rbx)
movq $0x1, 0x240(%rbx)
leaq 0x16c62(%rip), %rax     # 0x1f8e0
movq %rax, (%rbx)
leaq 0x248(%rbx), %r14
movq %r14, %rdi
callq 0x4310
leaq 0x458(%rbx), %r15
movq %r15, %rdi
callq 0x4310
leaq 0x668(%rbx), %r12
leaq 0x678(%rbx), %rax
movq %rax, (%rsp)
movq %rax, 0x668(%rbx)
movq (%r13), %rsi
movq 0x8(%r13), %rdx
addq %rsi, %rdx
movq %r12, %rdi
callq 0x76e4
leaq 0x18(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq 0x668(%rbx), %rsi
movq 0x670(%rbx), %rdx
addq %rsi, %rdx
leaq 0x8(%rsp), %rdi
callq 0x76e4
leaq 0xfa37(%rip), %rsi      # 0x1872d
leaq 0x8(%rsp), %rdi
callq 0x4530
leaq 0x218(%rbx), %rdi
leaq 0x8(%rsp), %r13
movq %r13, %rsi
callq 0x4330
movq (%r13), %rdi
cmpq %rbp, %rdi
je 0x8d2a
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x42d0
movq (%r15), %rax
movq -0x18(%rax), %rax
leaq (%r15,%rax), %rdi
movl $0x1, 0x1c(%r15,%rax)
movl 0x20(%r15,%rax), %esi
callq 0x44a0
movq (%r14), %rax
movq -0x18(%rax), %rax
leaq (%r14,%rax), %rdi
movl $0x1, 0x1c(%r14,%rax)
movl 0x20(%r14,%rax), %esi
callq 0x44a0
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r13
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x8da5
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x42d0
jmp 0x8da5
jmp 0x8da2
movq %rax, %r13
jmp 0x8dbe
movq %rax, %r13
jmp 0x8dc6
movq %rax, %r13
jmp 0x8dce
movq %rax, %r13
movq (%r12), %rdi
cmpq (%rsp), %rdi
je 0x8dbe
movq (%rsp), %rax
movq (%rax), %rsi
incq %rsi
callq 0x42d0
movq %r15, %rdi
callq 0x4090
movq %r14, %rdi
callq 0x4090
movq %rbx, %rdi
callq 0x167b6
movq %r13, %rdi
callq 0x44e0
// File: /workspace/github_cpp_makefile_star2_O3/tonymugen[P]sampleSNPs/varfiles.cpp
// Function: sampFiles::BedFile::~BedFile()
BedFile::~BedFile(){
    if (_bimFile.is_open()) {
        _bimFile.close();
    }
    if (_famFile.is_open()) {
        _famFile.close();
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
leaq 0x16af3(%rip), %rax     # 0x1f8e0
movq %rax, (%rdi)
leaq 0x458(%rdi), %r14
addq $0x4d8, %rdi            # imm = 0x4D8
callq 0x40a0
testb %al, %al
je 0x8e0f
movq %r14, %rdi
callq 0x4060
leaq 0x248(%rbx), %r15
leaq 0x2c8(%rbx), %rdi
callq 0x40a0
testb %al, %al
je 0x8e2e
movq %r15, %rdi
callq 0x4060
movq 0x668(%rbx), %rdi
leaq 0x678(%rbx), %rax
cmpq %rax, %rdi
je 0x8e4c
movq (%rax), %rsi
incq %rsi
callq 0x42d0
movq %r14, %rdi
callq 0x4090
movq %r15, %rdi
callq 0x4090
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x167b6
movq %rax, %rdi
callq 0x76d8
nop
// File: /workspace/github_cpp_makefile_star2_O3/tonymugen[P]sampleSNPs/varfiles.cpp
// Function: sampFiles::BedFile::close()
void BedFile::close(){
    if (_varFile.is_open()) {
        _varFile.close();
    }
    if (_bimFile.is_open()) {
        _bimFile.close();
    }
    if (_famFile.is_open()) {
        _famFile.close();
    }
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
addq $0x88, %rdi
callq 0x40a0
testb %al, %al
je 0x8e8f
leaq 0x8(%rbx), %rdi
callq 0x4060
leaq 0x4d8(%rbx), %rdi
callq 0x40a0
testb %al, %al
je 0x8eab
leaq 0x458(%rbx), %rdi
callq 0x4060
leaq 0x2c8(%rbx), %rdi
callq 0x40a0
testb %al, %al
je 0x8ecb
addq $0x248, %rbx            # imm = 0x248
movq %rbx, %rdi
popq %rbx
jmp 0x4060
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/tonymugen[P]sampleSNPs/varfiles.cpp
// Function: sampFiles::GtxtFileI::open()
void GtxtFileI::open(){
    if (_varFile.is_open()) {
        _varFile.close();
    }
    try {
        _varFile.open(_fileName.c_str(), ios::in);
		if (!_varFile.is_open()) {
			cerr << "ERROR: failed to open file " << _fileName << " for input" << endl;
			exit(2);
		}

    } catch (system_error &error) {
        cerr << "ERROR: cannot open text file " << _fileName << " for input: " << error.code().message() << flush;
        perror(" ");
        exit(1);

    }

}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
leaq 0x8(%rdi), %r15
leaq 0x88(%rdi), %r14
movq %r14, %rdi
callq 0x40a0
testb %al, %al
je 0x10bf3
movq %r15, %rdi
callq 0x4060
movq 0x218(%rbx), %rsi
movq %r15, %rdi
movl $0x8, %edx
callq 0x4270
movq %r14, %rdi
callq 0x40a0
testb %al, %al
je 0x10c1d
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq 0xf3cc(%rip), %rdi      # 0x1fff0
leaq 0x7925(%rip), %rsi      # 0x18550
movl $0x1b, %edx
callq 0x42f0
movq 0x218(%rbx), %rsi
movq 0x220(%rbx), %rdx
movq 0xf3a6(%rip), %rdi      # 0x1fff0
callq 0x42f0
movq %rax, %r14
leaq 0x7913(%rip), %rsi      # 0x1856c
movl $0xa, %edx
movq %rax, %rdi
callq 0x42f0
movq %r14, %rdi
callq 0x4130
movl $0x2, %edi
callq 0x4320
movq %rax, %r14
cmpl $0x1, %edx
jne 0x10d34
movq %r14, %rdi
callq 0x4110
movq %rax, %r14
movq 0xf35a(%rip), %rdi      # 0x1fff0
leaq 0x7f16(%rip), %rsi      # 0x18bb3
movl $0x1d, %edx
callq 0x42f0
movq 0x218(%rbx), %rsi
movq 0x220(%rbx), %rdx
movq 0xf334(%rip), %rdi      # 0x1fff0
callq 0x42f0
movq %rax, %rbx
leaq 0x7d32(%rip), %rsi      # 0x189fd
movl $0xc, %edx
movq %rax, %rdi
callq 0x42f0
movq 0x18(%r14), %rsi
movl 0x10(%r14), %edx
movq (%rsi), %rax
movq %rsp, %rdi
callq *0x20(%rax)
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x42f0
movq %rax, %rdi
callq 0x41b0
movq %rsp, %rdi
callq 0x4897
movq %rax, %r14
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x10d2f
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42d0
jmp 0x10d2f
jmp 0x10d2c
movq %rax, %r14
callq 0x4480
movq %r14, %rdi
callq 0x44e0
movq %rax, %rdi
callq 0x76d8