LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/brashi[P]PetFera/src/animal/reptil/reptil.cpp
// Function: Reptil::setPele()
bool Reptil::setPele() {
    string s;
    cout << endl << "Qual o tipo de pele do réptil? (S/N): " << endl;
    cout << "C - carapaça" << endl;
    cout << "E - escama" << endl;
    cout << "P - placa" << endl;
    getline(cin, s);

    switch(toupper(s[0])) {
        case 'C':
            this->pele = Carapaca;
            break;
        case 'E':
            this->pele = Escama;
            break;
        case 'P':
            this->pele = Placa;
            break;
        default:
            return false;
            break;
    }

    return true;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
movq $0x0, -0x8(%r15)
movb $0x0, (%r15)
movq 0xf820(%rip), %rdi      # 0x2dfd0
movq (%rdi), %rax
addq -0x18(%rax), %rdi
movl $0xa, %esi
callq 0x6280
movsbl %al, %esi
movq 0xf805(%rip), %rdi      # 0x2dfd0
callq 0x6030
movq %rax, %rdi
callq 0x61c0
movq %rax, %r14
leaq 0x509d(%rip), %rsi      # 0x2387f
movl $0x27, %edx
movq %rax, %rdi
callq 0x6310
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x6280
movsbl %al, %esi
movq %r14, %rdi
callq 0x6030
movq %rax, %rdi
callq 0x61c0
movq 0xf7b3(%rip), %r14      # 0x2dfd0
leaq 0x5083(%rip), %rsi      # 0x238a7
movl $0xd, %edx
movq %r14, %rdi
callq 0x6310
movq (%r14), %rax
addq -0x18(%rax), %r14
movq %r14, %rdi
movl $0xa, %esi
callq 0x6280
movsbl %al, %esi
movq 0xf781(%rip), %rdi      # 0x2dfd0
callq 0x6030
movq %rax, %rdi
callq 0x61c0
movq 0xf76d(%rip), %r14      # 0x2dfd0
leaq 0x504b(%rip), %rsi      # 0x238b5
movl $0xa, %edx
movq %r14, %rdi
callq 0x6310
movq (%r14), %rax
addq -0x18(%rax), %r14
movq %r14, %rdi
movl $0xa, %esi
callq 0x6280
movsbl %al, %esi
movq 0xf73b(%rip), %rdi      # 0x2dfd0
callq 0x6030
movq %rax, %rdi
callq 0x61c0
movq 0xf727(%rip), %r14      # 0x2dfd0
leaq 0x5010(%rip), %rsi      # 0x238c0
movl $0x9, %edx
movq %r14, %rdi
callq 0x6310
movq (%r14), %rax
addq -0x18(%rax), %r14
movq %r14, %rdi
movl $0xa, %esi
callq 0x6280
movsbl %al, %esi
movq 0xf6f5(%rip), %rdi      # 0x2dfd0
callq 0x6030
movq %rax, %rdi
callq 0x61c0
movq 0xf6f1(%rip), %rdi      # 0x2dfe0
movq (%rdi), %rax
addq -0x18(%rax), %rdi
movl $0xa, %esi
callq 0x6280
movsbl %al, %edx
movq 0xf6d6(%rip), %rdi      # 0x2dfe0
movq %rsp, %rsi
callq 0x6480
movq (%rsp), %r14
movsbl (%r14), %edi
callq 0x6490
cmpl $0x43, %eax
je 0x1e939
cmpl $0x45, %eax
je 0x1e935
cmpl $0x50, %eax
jne 0x1e948
movl $0x1, %eax
jmp 0x1e93e
xorl %eax, %eax
jmp 0x1e93e
movl $0x2, %eax
movl %eax, 0x8c(%rbx)
movb $0x1, %bl
jmp 0x1e94a
xorl %ebx, %ebx
cmpq %r15, %r14
je 0x1e95f
movq 0x10(%rsp), %rsi
incq %rsi
movq %r14, %rdi
callq 0x62b0
movl %ebx, %eax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x1e984
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x62b0
movq %rbx, %rdi
callq 0x6460
// File: /workspace/github_cpp_makefile_star2_O1/brashi[P]PetFera/src/animal/anfibio/anfibio.cpp
// Function: Anfibio::setCauda()
bool Anfibio::setCauda() {
    string s;
    cout << endl << "Anfíbio possui cauda? (S/N): " << endl;
    getline(cin, s);

    if(toupper(s[0]) == 'S')
        this->cauda = true;
    else if(toupper(s[0]) == 'N')
        this->cauda = false;
    else
        return false;

    return true;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
movq $0x0, -0x8(%r15)
movb $0x0, (%r15)
movq 0xeab4(%rip), %rdi      # 0x2dfd0
movq (%rdi), %rax
addq -0x18(%rax), %rdi
movl $0xa, %esi
callq 0x6280
movsbl %al, %esi
movq 0xea99(%rip), %rdi      # 0x2dfd0
callq 0x6030
movq %rax, %rdi
callq 0x61c0
movq %rax, %r14
leaq 0x43ad(%rip), %rsi      # 0x238fb
movl $0x1e, %edx
movq %rax, %rdi
callq 0x6310
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x6280
movsbl %al, %esi
movq %r14, %rdi
callq 0x6030
movq %rax, %rdi
callq 0x61c0
movq 0xea57(%rip), %rdi      # 0x2dfe0
movq (%rdi), %rax
addq -0x18(%rax), %rdi
movl $0xa, %esi
callq 0x6280
movsbl %al, %edx
movq 0xea3c(%rip), %rdi      # 0x2dfe0
movq %rsp, %rsi
callq 0x6480
movq (%rsp), %r14
movsbl (%r14), %edi
callq 0x6490
cmpl $0x4e, %eax
je 0x1f5c9
movb $0x1, %cl
cmpl $0x53, %eax
je 0x1f5cb
xorl %ebx, %ebx
jmp 0x1f5d3
xorl %ecx, %ecx
movb %cl, 0x89(%rbx)
movb $0x1, %bl
cmpq %r15, %r14
je 0x1f5e8
movq 0x10(%rsp), %rsi
incq %rsi
movq %r14, %rdi
callq 0x62b0
movl %ebx, %eax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x1f60d
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x62b0
movq %rbx, %rdi
callq 0x6460
nop
// File: /workspace/github_cpp_makefile_star2_O1/brashi[P]PetFera/src/animal/anfibio/anfibio.cpp
// Function: Anfibio::setPata()
bool Anfibio::setPata() {
    string s;
    cout << endl << "Anfíbio possui pata? (S/N): " << endl;
    getline(cin, s);

    if(toupper(s[0]) == 'S')
        this->pata = true;
    else if(toupper(s[0]) == 'N')
        this->pata = false;
    else
        return false;

    return true;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
movq $0x0, -0x8(%r15)
movb $0x0, (%r15)
movq 0xe982(%rip), %rdi      # 0x2dfd0
movq (%rdi), %rax
addq -0x18(%rax), %rdi
movl $0xa, %esi
callq 0x6280
movsbl %al, %esi
movq 0xe967(%rip), %rdi      # 0x2dfd0
callq 0x6030
movq %rax, %rdi
callq 0x61c0
movq %rax, %r14
leaq 0x429a(%rip), %rsi      # 0x2391a
movl $0x1d, %edx
movq %rax, %rdi
callq 0x6310
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x6280
movsbl %al, %esi
movq %r14, %rdi
callq 0x6030
movq %rax, %rdi
callq 0x61c0
movq 0xe925(%rip), %rdi      # 0x2dfe0
movq (%rdi), %rax
addq -0x18(%rax), %rdi
movl $0xa, %esi
callq 0x6280
movsbl %al, %edx
movq 0xe90a(%rip), %rdi      # 0x2dfe0
movq %rsp, %rsi
callq 0x6480
movq (%rsp), %r14
movsbl (%r14), %edi
callq 0x6490
cmpl $0x4e, %eax
je 0x1f6fb
movb $0x1, %cl
cmpl $0x53, %eax
je 0x1f6fd
xorl %ebx, %ebx
jmp 0x1f705
xorl %ecx, %ecx
movb %cl, 0x8a(%rbx)
movb $0x1, %bl
cmpq %r15, %r14
je 0x1f71a
movq 0x10(%rsp), %rsi
incq %rsi
movq %r14, %rdi
callq 0x62b0
movl %ebx, %eax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x1f73f
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x62b0
movq %rbx, %rdi
callq 0x6460
nop
// File: /workspace/github_cpp_makefile_star2_O1/AlanReviews[P]Goblet-of-fire/Control.cc
// Function: Control::drawParticipant(std::vector<Participant, std::allocator<Participant>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void Control::drawParticipant(vector<Participant> candidates, string school) {
    int candidateNum = rand() % candidates.size();
    while (candidates[candidateNum].getSchool() != school) {
        candidateNum = rand() % candidates.size();
    }
    candidates[candidateNum].displayInfo();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %r14
movq %rsi, %rbx
callq 0x2040
cltq
movq 0x8(%rbx), %rcx
subq (%rbx), %rcx
sarq $0x3, %rcx
movabsq $-0x71c71c71c71c71c7, %rdx # imm = 0x8E38E38E38E38E39
imulq %rdx, %rcx
xorl %edx, %edx
divq %rcx
leaq 0x18(%rsp), %rbp
leaq 0x8(%rsp), %r15
movslq %edx, %rax
leaq (%rax,%rax,8), %r12
shlq $0x3, %r12
movq (%rbx), %rsi
addq %r12, %rsi
movq %r15, %rdi
callq 0x33d0
movq 0x10(%rsp), %rdx
movb $0x1, %r13b
cmpq 0x8(%r14), %rdx
jne 0x2469
testq %rdx, %rdx
je 0x2466
movq (%r14), %rsi
movq 0x8(%rsp), %rdi
callq 0x2170
testl %eax, %eax
setne %r13b
jmp 0x2469
xorl %r13d, %r13d
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x2480
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x2160
testb %r13b, %r13b
je 0x24af
callq 0x2040
cltq
movq 0x8(%rbx), %rcx
subq (%rbx), %rcx
sarq $0x3, %rcx
movabsq $-0x71c71c71c71c71c7, %rdx # imm = 0x8E38E38E38E38E39
imulq %rdx, %rcx
xorl %edx, %edx
divq %rcx
jmp 0x2425
addq (%rbx), %r12
movq %r12, %rdi
callq 0x33f4
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/AlanReviews[P]Goblet-of-fire/View.cc
// Function: View::displayMenu(int&)
void View::displayMenu(int& choice)
{
  cout << "Welcome to the Goblet of Fire"<< endl;
  cout << "Remember, when you enter your name, you must participate in the Triwizard Tournament otherwise your magic will be gone" << endl;
  cout << "  1. Enter a participant:" << endl;
  cout << "  2. Draw out:" << endl;
  cout << "  0. Exit" << endl<<endl;

  cout << "Enter your selection: ";
  cin >> choice;
  if (choice == 0)
    return;

  while (choice < 0 || choice > 2) {
    cout << "Enter your selection: ";
    cin >> choice;
  }

}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq 0x2a7a(%rip), %r14      # 0x5fd0
leaq 0xc54(%rip), %rsi       # 0x41b1
movl $0x1d, %edx
movq %r14, %rdi
callq 0x2180
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x2140
movsbl %al, %esi
movq %r14, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20d0
leaq 0xc37(%rip), %rsi       # 0x41cf
movl $0x76, %edx
movq %r14, %rdi
callq 0x2180
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x2140
movsbl %al, %esi
movq %r14, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20d0
leaq 0xc73(%rip), %rsi       # 0x4246
movl $0x19, %edx
movq %r14, %rdi
callq 0x2180
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x2140
movsbl %al, %esi
movq %r14, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20d0
leaq 0xc52(%rip), %rsi       # 0x4260
movl $0xe, %edx
movq %r14, %rdi
callq 0x2180
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x2140
movsbl %al, %esi
movq %r14, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20d0
leaq 0xc26(%rip), %rsi       # 0x426f
movl $0x9, %edx
movq %r14, %rdi
callq 0x2180
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x2140
movsbl %al, %esi
movq %r14, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20d0
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x2140
movsbl %al, %esi
movq %r15, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20d0
leaq 0xbcb(%rip), %rsi       # 0x4279
movl $0x16, %edx
movq %r14, %rdi
callq 0x2180
movq 0x291e(%rip), %rdi      # 0x5fe0
movq %rbx, %rsi
callq 0x20b0
cmpl $0x3, (%rbx)
jb 0x3704
movq 0x28fa(%rip), %r14      # 0x5fd0
leaq 0xb9c(%rip), %r15       # 0x4279
movq 0x28fc(%rip), %r12      # 0x5fe0
movl $0x16, %edx
movq %r14, %rdi
movq %r15, %rsi
callq 0x2180
movq %r12, %rdi
movq %rbx, %rsi
callq 0x20b0
cmpl $0x2, (%rbx)
ja 0x36e4
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./bufferops.h
// Function: buffer::LoadFile(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const*, std::vector<unsigned char, std::allocator<unsigned char>>&)
bool LoadFile(const std::string* path, std::vector<unsigned char>& buffer) {
        std::ifstream file(path->c_str(), std::fstream::binary);

        if (file) {
            std::noskipws(file);

            file.seekg(0, file.end);
            uint64_t len = file.tellg();
            file.seekg(0, file.beg);

            buffer.resize(len, 0u);
            std::copy(std::istream_iterator<unsigned char>(file),
                      std::istream_iterator<unsigned char>(),
                      &buffer[0]);

            file.close();
            return true;
        }

        return false;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x228, %rsp            # imm = 0x228
movq %rsi, %rbx
movq (%rdi), %rsi
leaq 0x20(%rsp), %r14
movq %r14, %rdi
movl $0x4, %edx
callq 0x2340
movq (%r14), %rax
movq -0x18(%rax), %rax
movl 0x40(%rsp,%rax), %ebp
testb $0x5, %bpl
jne 0x27b8
andb $-0x11, 0x39(%rsp,%rax)
leaq 0x20(%rsp), %rdi
xorl %esi, %esi
movl $0x2, %edx
callq 0x2270
leaq 0x20(%rsp), %rdi
callq 0x2310
movq %rax, %r14
leaq 0x20(%rsp), %r15
movq %r15, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x2270
movq %rsp, %rdx
movb $0x0, (%rdx)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3b50
leaq 0x10(%rsp), %rdi
movq %r15, (%rdi)
movb $0x1, 0x9(%rdi)
callq 0x49a2
movq (%rbx), %r14
movq 0x10(%rsp), %rax
movzwl 0x18(%rsp), %ecx
movq %rsp, %rbx
movq %rax, (%rbx)
movw %cx, 0x8(%rbx)
cmpb $0x0, 0x9(%rsp)
je 0x27ae
movb 0x8(%rsp), %al
movb %al, (%r14)
incq %r14
movq %rbx, %rdi
callq 0x49a2
jmp 0x2793
leaq 0x20(%rsp), %rdi
callq 0x2060
testb $0x5, %bpl
sete %bl
leaq 0x20(%rsp), %rdi
callq 0x2070
movl %ebx, %eax
addq $0x228, %rsp            # imm = 0x228
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
jmp 0x27e1
jmp 0x27e1
jmp 0x27e1
jmp 0x27e1
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0x2070
movq %rbx, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./bufferops.h
// Function: buffer::SaveFile(std::vector<unsigned char, std::allocator<unsigned char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const*)
bool SaveFile(const std::vector<unsigned char>& Buffer, const std::string *Path) {
        std::ofstream file(Path->c_str(), std::fstream::binary);
        std::noskipws(file);
        file.write(reinterpret_cast<const char *>(&Buffer[0]), Buffer.size());
        file.close();
        return file ? true : false;
    }

// Assembly:
pushq %r14
pushq %rbx
subq $0x208, %rsp            # imm = 0x208
movq %rdi, %rbx
movq (%rsi), %rsi
leaq 0x8(%rsp), %r14
movq %r14, %rdi
movl $0x4, %edx
callq 0x2210
movq (%r14), %rax
movq -0x18(%rax), %rax
andl $0xffffefff, 0x20(%rsp,%rax) # imm = 0xFFFFEFFF
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
subq %rsi, %rdx
movq %r14, %rdi
callq 0x2250
leaq 0x8(%rsp), %rdi
callq 0x2290
leaq 0x10(%rsp), %rdi
movq -0x8(%rdi), %rax
movq -0x18(%rax), %rax
testb $0x5, 0x28(%rsp,%rax)
sete %bl
movq 0xa759(%rip), %rax      # 0xcfb8
movq (%rax), %rcx
movq 0x18(%rax), %rax
movq %rcx, -0x8(%rdi)
movq -0x18(%rcx), %rcx
movq %rax, 0x8(%rsp,%rcx)
callq 0x21a0
leaq 0x100(%rsp), %rdi
callq 0x2090
movl %ebx, %eax
addq $0x208, %rsp            # imm = 0x208
popq %rbx
popq %r14
retq
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x22b0
movq %rbx, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./arith.h
// Function: arith::ComputeProbabilities(unsigned int*, std::vector<unsigned char, std::allocator<unsigned char>>&, unsigned char)
void ComputeProbabilities(uint32_t* ProbabilityTable, std::vector<unsigned char>& UncompressedBuffer, uint8_t BitShift) {
        memset(ProbabilityTable, 0u, 256*4);
        uint8_t val;

        for (uint32_t i = 0; i < MIN(UncompressedBuffer.size() - 1, UINT32_MAX); i++) {
            val = ((uint8_t) UncompressedBuffer[i] << BitShift) +
                  ((uint8_t) UncompressedBuffer[i + 1] >> (8 - BitShift));
            ProbabilityTable[val]++;
        }
    }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
movl $0x400, %edx            # imm = 0x400
xorl %esi, %esi
callq 0x2110
movq (%r14), %rsi
movq %rsi, %rax
notq %rax
addq 0x8(%r14), %rax
je 0x2917
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
cmpq %rdi, %rax
cmovbq %rax, %rdi
movzbl %bpl, %eax
movl $0x8, %edx
subl %eax, %edx
cmpq $0x1, %rdi
adcq $0x0, %rdi
xorl %r8d, %r8d
movzbl (%rsi,%r8), %r9d
movl %eax, %ecx
shll %cl, %r9d
movzbl 0x1(%rsi,%r8), %r10d
movl %edx, %ecx
shrl %cl, %r10d
incq %r8
addl %r9d, %r10d
movzbl %r10b, %ecx
incl (%rbx,%rcx,4)
cmpq %r8, %rdi
jne 0x28f0
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./arith.h
// Function: arith::ArithmeticMean(unsigned int const*, unsigned long)
double ArithmeticMean(const uint32_t* Data, uint64_t Size) {
        double sum = 0;

        for (uint64_t i = 0; i < Size; i++) {
            sum += double(*(Data+i));
        }

        return sum / (double) Size;
    }

// Assembly:
xorpd %xmm0, %xmm0
testq %rsi, %rsi
je 0x293e
xorl %eax, %eax
movl (%rdi,%rax,4), %ecx
xorps %xmm1, %xmm1
cvtsi2sd %rcx, %xmm1
addsd %xmm1, %xmm0
incq %rax
cmpq %rax, %rsi
jne 0x2927
movq %rsi, %xmm1
punpckldq 0x66c5(%rip), %xmm1 # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1]
subpd 0x66cd(%rip), %xmm1     # 0x9020
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
divsd %xmm2, %xmm0
retq
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./arith.h
// Function: arith::StandardDeviation(unsigned int const*, unsigned long)
double StandardDeviation(const uint32_t* Data, uint64_t Size) {
        double mean = ArithmeticMean(Data, Size);
        double sum = 0;

        for (uint64_t i = 0; i < Size; i++) {
            sum += pow((double(*(Data+i)) - mean), 2);
        }

        return sqrt(sum / ((double) Size - 1));
    }

// Assembly:
xorpd %xmm0, %xmm0
xorpd %xmm1, %xmm1
testq %rsi, %rsi
je 0x298a
xorl %eax, %eax
movl (%rdi,%rax,4), %ecx
xorps %xmm2, %xmm2
cvtsi2sd %rcx, %xmm2
addsd %xmm2, %xmm1
incq %rax
cmpq %rax, %rsi
jne 0x2973
movq %rsi, %xmm3
punpckldq 0x6679(%rip), %xmm3 # xmm3 = xmm3[0],mem[0],xmm3[1],mem[1]
subpd 0x6681(%rip), %xmm3     # 0x9020
movapd %xmm3, %xmm2
unpckhpd %xmm3, %xmm2            # xmm2 = xmm2[1],xmm3[1]
addsd %xmm3, %xmm2
testq %rsi, %rsi
je 0x29d9
divsd %xmm2, %xmm1
xorpd %xmm0, %xmm0
xorl %eax, %eax
movl (%rdi,%rax,4), %ecx
xorps %xmm3, %xmm3
cvtsi2sd %rcx, %xmm3
subsd %xmm1, %xmm3
mulsd %xmm3, %xmm3
addsd %xmm3, %xmm0
incq %rax
cmpq %rax, %rsi
jne 0x29ba
addsd 0x665f(%rip), %xmm2     # 0x9040
divsd %xmm2, %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jb 0x2180
sqrtsd %xmm0, %xmm0
retq
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./arith.h
// Function: arith::CompressBuffer(std::vector<unsigned char, std::allocator<unsigned char>>&, buffer::CodecByteStream&)
CodecStatusCode CompressBuffer(std::vector<unsigned char>& UncompressedBuffer, buffer::CodecByteStream& CompressedBuffer) {
        std::cout << "Initializing Compressor..." << std::endl;
        CodecProbabilityTable ProbabilityTable;
        ProbabilityTable.GenerateTable(UncompressedBuffer);
        CompressBuffer(UncompressedBuffer, ProbabilityTable, CompressedBuffer);
        uint64_t UncompressedBufferSize = UncompressedBuffer.size();
        buffer::EncodeTypeToBuffer<uint64_t>(CompressedBuffer.GetBuffer(), 0, &UncompressedBufferSize);
        ProbabilityTable.EncodeToBuffer(CompressedBuffer.GetBuffer(), 8);
        return Success;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x418, %rsp            # imm = 0x418
movq %rsi, %rbx
movq %rdi, %r14
movq 0x9ef1(%rip), %r15      # 0xcfc8
leaq 0x5fc6(%rip), %rsi      # 0x90a4
movl $0x1a, %edx
movq %r15, %rdi
callq 0x2220
movq (%r15), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq %r15, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2140
leaq 0x10(%rsp), %r15
xorl %r12d, %r12d
movl $0x404, %edx            # imm = 0x404
movq %r15, %rdi
xorl %esi, %esi
callq 0x2110
movq %r15, %rdi
movq %r14, %rsi
callq 0x3d90
movq %r14, %rdi
movq %r15, %rsi
movq %rbx, %rdx
callq 0x29f8
movq 0x8(%r14), %rax
subq (%r14), %rax
movq %rax, 0x8(%rsp)
movb 0x8(%rsp,%r12), %al
movq (%rbx), %rcx
movb %al, (%rcx,%r12)
incq %r12
cmpq $0x8, %r12
jne 0x314e
movl $0x1, %eax
movl $0x8, %ecx
movl $0x4, %edx
movq %rcx, %rsi
movb 0xc(%rsp,%rsi), %dil
movq (%rbx), %r8
movb %dil, (%r8,%rsi)
incq %rsi
decq %rdx
jne 0x3175
incq %rax
addq $0x4, %rcx
cmpq $0x101, %rax            # imm = 0x101
jne 0x316d
xorl %eax, %eax
addq $0x418, %rsp            # imm = 0x418
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./arith.h
// Function: arith::UncompressBuffer(buffer::CodecByteStream&, std::vector<unsigned char, std::allocator<unsigned char>>&)
CodecStatusCode UncompressBuffer(buffer::CodecByteStream& UncompressedBuffer, std::vector<unsigned char>& CompressedBuffer) {
        std::cout << "Initializing Uncompressor..." << std::endl;
        uint64_t UncompressedBufferSize;
        CodecProbabilityTable ProbabilityTable;

        buffer::DecodeTypeFromBuffer<uint64_t>(CompressedBuffer, 0, &UncompressedBufferSize);
        ProbabilityTable.DecodeFromBuffer(CompressedBuffer, 8);

        UncompressBuffer(CompressedBuffer,
                         ProbabilityTable,
                         UncompressedBuffer,
                         UncompressedBufferSize);

        UncompressedBuffer.TruncateOne();

        return Success;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x410, %rsp            # imm = 0x410
movq %rsi, %r14
movq %rdi, %rbx
movq 0x9e06(%rip), %r15      # 0xcfc8
leaq 0x5ef6(%rip), %rsi      # 0x90bf
movl $0x1c, %edx
movq %r15, %rdi
callq 0x2220
movq (%r15), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq %r15, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2140
leaq 0x8(%rsp), %rdi
movl $0x404, %edx            # imm = 0x404
xorl %esi, %esi
callq 0x2110
movq (%r14), %rax
movq (%rax), %rcx
addq $0x8, %rax
movl $0x1, %edx
leaq 0xc(%rsp), %rsi
xorl %edi, %edi
movb (%rax,%rdi), %r8b
movb %r8b, (%rsi,%rdi)
incq %rdi
cmpq $0x4, %rdi
jne 0x3224
incq %rdx
addq $0x4, %rax
addq $0x4, %rsi
cmpq $0x101, %rdx            # imm = 0x101
jne 0x3222
leaq 0x8(%rsp), %rsi
movq %r14, %rdi
movq %rbx, %rdx
callq 0x2cd6
movq (%rbx), %rsi
notq %rsi
addq 0x8(%rbx), %rsi
movq %rbx, %rdi
callq 0x46a8
decq 0x20(%rbx)
movb $0x7, 0x18(%rbx)
xorl %eax, %eax
addq $0x410, %rsp            # imm = 0x410
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./arith.h
// Function: arith::CompressFile(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>> const&)
CodecStatusCode CompressFile(const std::string& InFile, const std::string& OutFile) {
        std::vector<unsigned char> UncompressedBuffer;

        if (buffer::LoadFile(&InFile, UncompressedBuffer)) {
            buffer::CodecByteStream CompressedBuffer(256*4+8);
            arith::CompressBuffer(UncompressedBuffer, CompressedBuffer);
            if (buffer::SaveFile(CompressedBuffer.GetBuffer(), &OutFile)) {
                return Success;
            } else {
                std::cerr << "File Write Error." << std::endl;
                return FileWriteError;
            }
        } else {
            std::cerr << "File Read Error." << std::endl;
            return FileReadError;
        }
    }

// Assembly:
pushq %rbx
subq $0x50, %rsp
movq %rsi, %rbx
xorps %xmm0, %xmm0
movq %rsp, %rsi
movaps %xmm0, (%rsi)
movq $0x0, 0x10(%rsi)
callq 0x26ec
testb %al, %al
je 0x3333
leaq 0x20(%rsp), %rdi
movl $0x408, %esi            # imm = 0x408
callq 0x3ef2
movq %rsp, %rdi
leaq 0x20(%rsp), %rsi
callq 0x30bc
leaq 0x20(%rsp), %rdi
movq %rbx, %rsi
callq 0x27f6
xorl %ebx, %ebx
testb %al, %al
jne 0x3322
movq 0x9d0a(%rip), %rbx      # 0xcfe8
leaq 0x5df7(%rip), %rsi      # 0x90dc
movl $0x11, %edx
movq %rbx, %rdi
callq 0x2220
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq 0x9cd8(%rip), %rdi      # 0xcfe8
callq 0x2030
movl $0x2, %ebx
movq %rax, %rdi
callq 0x2140
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x337e
callq 0x21c0
jmp 0x337e
movq 0x9cae(%rip), %rbx      # 0xcfe8
leaq 0x5dad(%rip), %rsi      # 0x90ee
movl $0x10, %edx
movq %rbx, %rdi
callq 0x2220
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq 0x9c7c(%rip), %rdi      # 0xcfe8
callq 0x2030
movl $0x1, %ebx
movq %rax, %rdi
callq 0x2140
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x338c
callq 0x21c0
movl %ebx, %eax
addq $0x50, %rsp
popq %rbx
retq
jmp 0x33aa
movq %rax, %rbx
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x33ad
callq 0x21c0
jmp 0x33ad
movq %rax, %rbx
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x33bb
callq 0x21c0
movq %rbx, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./arith.h
// Function: arith::UncompressFile(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>> const&)
CodecStatusCode UncompressFile(const std::string& InFile, const std::string& OutFile) {
        std::vector<unsigned char> CompressedBuffer;

        if (buffer::LoadFile(&InFile, CompressedBuffer)) {
            buffer::CodecByteStream UncompressedBuffer(0);
            try {
                arith::UncompressBuffer(UncompressedBuffer, CompressedBuffer);
            } catch (std::exception& e) {
                std::cerr << e.what() << std::endl;
                return BadCompressionStream;
            }

            if (buffer::SaveFile(UncompressedBuffer.GetBuffer(), &OutFile)) {
                return Success;
            } else {
                std::cerr << "File Write Error." << std::endl;
                return FileWriteError;
            }
        } else {
            std::cerr << "File Read Error." << std::endl;
            return FileReadError;
        }
    }

// Assembly:
pushq %rbx
subq $0x50, %rsp
movq %rsi, %rbx
xorps %xmm0, %xmm0
movq %rsp, %rsi
movaps %xmm0, (%rsi)
movq $0x0, 0x10(%rsi)
callq 0x26ec
testb %al, %al
je 0x3471
leaq 0x20(%rsp), %rdi
xorl %esi, %esi
callq 0x3ef2
leaq 0x20(%rsp), %rdi
movq %rsp, %rsi
callq 0x31a9
leaq 0x20(%rsp), %rdi
movq %rbx, %rsi
callq 0x27f6
xorl %ebx, %ebx
testb %al, %al
jne 0x3460
movq 0x9bcc(%rip), %rbx      # 0xcfe8
leaq 0x5cb9(%rip), %rsi      # 0x90dc
movl $0x11, %edx
movq %rbx, %rdi
callq 0x2220
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq 0x9b9a(%rip), %rdi      # 0xcfe8
callq 0x2030
movl $0x2, %ebx
movq %rax, %rdi
callq 0x2140
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x34bc
callq 0x21c0
jmp 0x34bc
movq 0x9b70(%rip), %rbx      # 0xcfe8
leaq 0x5c6f(%rip), %rsi      # 0x90ee
movl $0x10, %edx
movq %rbx, %rdi
callq 0x2220
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq 0x9b3e(%rip), %rdi      # 0xcfe8
callq 0x2030
movl $0x1, %ebx
movq %rax, %rdi
callq 0x2140
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x34ca
callq 0x21c0
movl %ebx, %eax
addq $0x50, %rsp
popq %rbx
retq
movq %rax, %rbx
cmpl $0x1, %edx
jne 0x352a
movq %rbx, %rdi
callq 0x20d0
movq (%rax), %rcx
movq %rax, %rdi
callq *0x10(%rcx)
movq 0x9af6(%rip), %rdi      # 0xcfe8
movq %rax, %rsi
callq 0x21e0
movq %rax, %rdi
callq 0x20e0
movl $0x3, %ebx
callq 0x22f0
jmp 0x3460
jmp 0x3527
movq %rax, %rbx
callq 0x22f0
jmp 0x352a
movq %rax, %rdi
callq 0x3f49
jmp 0x353b
movq %rax, %rbx
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x353e
callq 0x21c0
jmp 0x353e
movq %rax, %rbx
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x354c
callq 0x21c0
movq %rbx, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./huffman.h
// Function: huffman::CompressFile(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>> const&)
CodecStatusCode CompressFile(const std::string& InFile, const std::string& OutFile) {
        std::vector<unsigned char> UncompressedBuffer;

        if (buffer::LoadFile(&InFile, UncompressedBuffer)) {
            buffer::CodecByteStream CompressedBuffer(2+8+256*(1+8));
            CompressBuffer<unsigned char, uint64_t>(UncompressedBuffer, CompressedBuffer);
            if (buffer::SaveFile(CompressedBuffer.GetBuffer(), &OutFile)) {
                return Success;
            } else {
                std::cerr << "File Write Error." << std::endl;
                return FileWriteError;
            }
        } else {
            std::cerr << "File Read Error." << std::endl;
            return FileReadError;
        }
    }

// Assembly:
pushq %rbx
subq $0x50, %rsp
movq %rsi, %rbx
xorps %xmm0, %xmm0
movq %rsp, %rsi
movaps %xmm0, (%rsi)
movq $0x0, 0x10(%rsi)
callq 0x26ec
testb %al, %al
je 0x3605
leaq 0x20(%rsp), %rdi
movl $0x90a, %esi            # imm = 0x90A
callq 0x3ef2
movq %rsp, %rdi
leaq 0x20(%rsp), %rsi
callq 0x3f54
leaq 0x20(%rsp), %rdi
movq %rbx, %rsi
callq 0x27f6
xorl %ebx, %ebx
testb %al, %al
jne 0x35f4
movq 0x9a38(%rip), %rbx      # 0xcfe8
leaq 0x5b25(%rip), %rsi      # 0x90dc
movl $0x11, %edx
movq %rbx, %rdi
callq 0x2220
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq 0x9a06(%rip), %rdi      # 0xcfe8
callq 0x2030
movl $0x2, %ebx
movq %rax, %rdi
callq 0x2140
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x3650
callq 0x21c0
jmp 0x3650
movq 0x99dc(%rip), %rbx      # 0xcfe8
leaq 0x5adb(%rip), %rsi      # 0x90ee
movl $0x10, %edx
movq %rbx, %rdi
callq 0x2220
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq 0x99aa(%rip), %rdi      # 0xcfe8
callq 0x2030
movl $0x1, %ebx
movq %rax, %rdi
callq 0x2140
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x365e
callq 0x21c0
movl %ebx, %eax
addq $0x50, %rsp
popq %rbx
retq
jmp 0x367c
movq %rax, %rbx
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x367f
callq 0x21c0
jmp 0x367f
movq %rax, %rbx
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x368d
callq 0x21c0
movq %rbx, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./huffman.h
// Function: huffman::UncompressFile(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>> const&)
CodecStatusCode UncompressFile(const std::string& InFile, const std::string& OutFile) {
        std::vector<unsigned char> CompressedBuffer;
        std::vector<unsigned char> UncompressedBuffer;

        if (buffer::LoadFile(&InFile, CompressedBuffer)) {
            try {
                UncompressBuffer<unsigned char, uint64_t>(UncompressedBuffer, CompressedBuffer);
            } catch (std::exception& e) {
                std::cerr << e.what() << std::endl;
                return BadCompressionStream;
            }

            if (buffer::SaveFile(UncompressedBuffer, &OutFile)) {
                return Success;
            } else {
                std::cerr << "File Write Error." << std::endl;
                return FileWriteError;
            }
        } else {
            std::cerr << "File Read Error." << std::endl;
            return FileReadError;
        }
    }

// Assembly:
pushq %rbx
subq $0x40, %rsp
movq %rsi, %rbx
xorps %xmm0, %xmm0
leaq 0x20(%rsp), %rsi
movaps %xmm0, (%rsi)
xorl %eax, %eax
movq %rax, 0x10(%rsi)
movq %rax, 0x10(%rsp)
movaps %xmm0, (%rsp)
callq 0x26ec
testb %al, %al
je 0x372f
movq %rsp, %rdi
leaq 0x20(%rsp), %rsi
callq 0x41e7
movq %rsp, %rdi
movq %rbx, %rsi
callq 0x27f6
xorl %ebx, %ebx
testb %al, %al
jne 0x377a
movq 0x98ff(%rip), %rbx      # 0xcfe8
leaq 0x59ec(%rip), %rsi      # 0x90dc
movl $0x11, %edx
movq %rbx, %rdi
callq 0x2220
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq 0x98cd(%rip), %rdi      # 0xcfe8
callq 0x2030
movl $0x2, %ebx
movq %rax, %rdi
callq 0x2140
jmp 0x377a
movq 0x98b2(%rip), %rbx      # 0xcfe8
leaq 0x59b1(%rip), %rsi      # 0x90ee
movl $0x10, %edx
movq %rbx, %rdi
callq 0x2220
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq 0x9880(%rip), %rdi      # 0xcfe8
callq 0x2030
movl $0x1, %ebx
movq %rax, %rdi
callq 0x2140
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x3788
callq 0x21c0
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x3797
callq 0x21c0
movl %ebx, %eax
addq $0x40, %rsp
popq %rbx
retq
movq %rax, %rbx
cmpl $0x1, %edx
jne 0x37f2
movq %rbx, %rdi
callq 0x20d0
movq (%rax), %rcx
movq %rax, %rdi
callq *0x10(%rcx)
movq 0x9829(%rip), %rdi      # 0xcfe8
movq %rax, %rsi
callq 0x21e0
movq %rax, %rdi
callq 0x20e0
movl $0x3, %ebx
callq 0x22f0
jmp 0x377a
jmp 0x37ef
movq %rax, %rbx
callq 0x22f0
jmp 0x37f2
movq %rax, %rdi
callq 0x3f49
movq %rax, %rbx
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x3800
callq 0x21c0
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x380f
callq 0x21c0
movq %rbx, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/codec.cpp
// Function: main
int main(int argc, char* argv[]) {
    if (argc != 6) {
        print_help();
    } else if (strcmp(argv[1], "--algorithm") != 0) {
        print_help();
    } else {
        if (strcmp(argv[3], "--encode") == 0) {
            if (strcmp(argv[2], "arith") == 0) {
                arith::CompressFile(std::string(argv[4]), std::string(argv[5]));
            } else if (strcmp(argv[2], "huffman") == 0) {
                huffman::CompressFile(std::string(argv[4]), std::string(argv[5]));
            } else {
                print_help();
            }
        } else {
            if (strcmp(argv[2], "arith") == 0) {
                arith::UncompressFile(std::string(argv[4]), std::string(argv[5]));
            } else if (strcmp(argv[2], "huffman") == 0) {
                huffman::UncompressFile(std::string(argv[4]), std::string(argv[5]));
            } else {
                print_help();
            }
        }
    }
    exit(0);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x50, %rsp
cmpl $0x6, %edi
jne 0x3af7
movq %rsi, %rbx
movq 0x8(%rsi), %rdi
leaq 0x583c(%rip), %rsi      # 0x91bf
callq 0x2280
testl %eax, %eax
jne 0x3af7
movq 0x18(%rbx), %rdi
leaq 0x5830(%rip), %rsi      # 0x91cb
callq 0x2280
movl %eax, %ebp
movq 0x10(%rbx), %r14
leaq 0x5827(%rip), %rsi      # 0x91d4
movq %r14, %rdi
callq 0x2280
testl %ebp, %ebp
jne 0x39f7
testl %eax, %eax
jne 0x3a39
movq 0x20(%rbx), %rsi
leaq 0x30(%rsp), %rdi
leaq 0xf(%rsp), %rdx
callq 0x20c0
movq 0x28(%rbx), %rsi
leaq 0x10(%rsp), %rdi
leaq 0xe(%rsp), %rdx
callq 0x20c0
leaq 0x30(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x3282
jmp 0x3acf
testl %eax, %eax
jne 0x3a87
movq 0x20(%rbx), %rsi
leaq 0x30(%rsp), %rdi
leaq 0xf(%rsp), %rdx
callq 0x20c0
movq 0x28(%rbx), %rsi
leaq 0x10(%rsp), %rdi
leaq 0xe(%rsp), %rdx
callq 0x20c0
leaq 0x30(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x33c3
jmp 0x3acf
leaq 0x579a(%rip), %rsi      # 0x91da
movq %r14, %rdi
callq 0x2280
testl %eax, %eax
jne 0x3af7
movq 0x20(%rbx), %rsi
leaq 0x30(%rsp), %rdi
leaq 0xf(%rsp), %rdx
callq 0x20c0
movq 0x28(%rbx), %rsi
leaq 0x10(%rsp), %rdi
leaq 0xe(%rsp), %rdx
callq 0x20c0
leaq 0x30(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x3554
jmp 0x3acf
leaq 0x574c(%rip), %rsi      # 0x91da
movq %r14, %rdi
callq 0x2280
testl %eax, %eax
jne 0x3af7
movq 0x20(%rbx), %rsi
leaq 0x30(%rsp), %rdi
leaq 0xf(%rsp), %rdx
callq 0x20c0
movq 0x28(%rbx), %rsi
leaq 0x10(%rsp), %rdi
leaq 0xe(%rsp), %rdx
callq 0x20c0
leaq 0x30(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x3695
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x3ae2
callq 0x21c0
leaq 0x40(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x3afc
callq 0x21c0
jmp 0x3afc
callq 0x3817
xorl %edi, %edi
callq 0x2240
jmp 0x3b0d
jmp 0x3b0d
jmp 0x3b2b
jmp 0x3b2b
jmp 0x3b0d
movq %rax, %rbx
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x3b2e
callq 0x21c0
jmp 0x3b2e
jmp 0x3b45
jmp 0x3b45
jmp 0x3b2b
movq %rax, %rbx
leaq 0x40(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x3b48
callq 0x21c0
jmp 0x3b48
jmp 0x3b45
movq %rax, %rbx
movq %rbx, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./bufferops.h
// Function: buffer::CodecBufferWrapper::CodecBufferWrapper(std::vector<unsigned char, std::allocator<unsigned char>>&, unsigned char)
CodecBufferWrapper(std::vector<unsigned char>& InBuffer, uint8_t Shift) {
            Buffer = InBuffer;
            BitShift = Shift;
            IBitShift = 8u-Shift;
            EffectiveSize = Buffer.size() - (Shift == 0 ? 0 : 1); // If a shift is used, the buffer size effectively decreases by one
        }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebp
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
callq 0x44c8
movb %bpl, 0x18(%rbx)
movb $0x8, %al
subb %bpl, %al
movb %al, 0x19(%rbx)
movq 0x8(%rbx), %rax
cmpb $0x1, %bpl
adcq $-0x1, %rax
subq (%rbx), %rax
movq %rax, 0x20(%rbx)
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %r14
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x3bce
callq 0x21c0
movq %r14, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./bufferops.h
// Function: buffer::CodecByteStream::WriteBitBuffered(unsigned char)
void WriteBitBuffered(uint8_t Bit) {
            WriteBit(Bit);
            Bit ^= 1u;
            while (PendingBits > 0) {
                WriteBit(Bit);
                PendingBits--;
            }
        }

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
callq 0x3cb0
cmpl $0x0, 0x28(%rbx)
jle 0x3c5d
xorb $0x1, %bpl
movzbl %bpl, %ebp
movq %rbx, %rdi
movl %ebp, %esi
callq 0x3cb0
movl 0x28(%rbx), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0x28(%rbx)
cmpl $0x1, %eax
jg 0x3c45
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./bufferops.h
// Function: buffer::CodecByteStream::WriteBit(unsigned char)
void WriteBit(uint8_t Bit) {
            Data[ByteIndex] |= Bit<<IBitIndex;
            if (IBitIndex == 0) {
                ByteIndex++;
                Data.push_back(0u);
                IBitIndex = 7u;
            } else {
                IBitIndex--;
            }
        }

// Assembly:
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movb 0x18(%rdi), %cl
shll %cl, %esi
movq 0x20(%rdi), %rax
movq (%rdi), %rcx
orb %sil, (%rcx,%rax)
movb 0x18(%rdi), %al
testb %al, %al
je 0x3cd3
decb %al
jmp 0x3cfe
incq 0x20(%rbx)
movb $0x0, 0xf(%rsp)
movq 0x8(%rbx), %rsi
cmpq 0x10(%rbx), %rsi
je 0x3cef
movb $0x0, (%rsi)
incq 0x8(%rbx)
jmp 0x3cfc
leaq 0xf(%rsp), %rdx
movq %rbx, %rdi
callq 0x45ba
movb $0x7, %al
movb %al, 0x18(%rbx)
addq $0x10, %rsp
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./arith.h
// Function: arith::CodecProbabilityTable::DecodeFromCount(unsigned long)
std::tuple<uint32_t, uint32_t, uint8_t> DecodeFromCount(uint64_t count) {
            for (uint16_t i = 0; i < 256; i++) {
                if (Frequencies[i+1] > count) {
                    return std::make_tuple(Frequencies[i], Frequencies[i+1], i);
                }
            }
            throw std::runtime_error("Bad Value Encountered In Decode.");
        }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq $-0x1, %rax
cmpq $0xff, %rax
je 0x3d4b
movl 0x8(%rsi,%rax,4), %ecx
incq %rax
cmpq %rdx, %rcx
jbe 0x3d13
movb %al, (%rdi)
movq (%rsi,%rax,4), %xmm0
pshufd $0xe1, %xmm0, %xmm0     # xmm0 = xmm0[1,0,2,3]
movq %xmm0, 0x4(%rdi)
cmpq $0x100, %rax            # imm = 0x100
jae 0x3d4b
movq %rdi, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0x10, %edi
callq 0x20f0
movq %rax, %rbx
leaq 0x549d(%rip), %rsi      # 0x91fc
movq %rax, %rdi
callq 0x20b0
movq 0x9282(%rip), %rsi      # 0xcff0
movq 0x924b(%rip), %rdx      # 0xcfc0
movq %rbx, %rdi
callq 0x2300
movq %rax, %r14
movq %rbx, %rdi
callq 0x2160
movq %r14, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./arith.h
// Function: arith::CodecProbabilityTable::GenerateTable(std::vector<unsigned char, std::allocator<unsigned char>>&)
void GenerateTable(std::vector<unsigned char>& UncompressedBuffer) {
            uint32_t tables[256*8] = {0};
            double deviations[8] = {0};

            for (uint16_t i = 0; i < 8; i++) {
                ComputeProbabilities(&tables[i*256], UncompressedBuffer, (uint8_t) i);
                deviations[i] = StandardDeviation(&tables[i*256], 256);
            }

            uint16_t max = 0u;
            double pmax = 0;

            for (uint16_t i = 0; i < 8; i++) {
                if (deviations[i] > pmax) {
                    pmax = deviations[i];
                    max = i;
                }
            }

            std::copy(tables+256*max, tables+256*(max+1), Frequencies + 1);

            for (uint16_t i = 1; i < 257; i++) {
                Frequencies[i] += Frequencies[i-1];
            }

            BitShift = max;
        }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x2040, %rsp           # imm = 0x2040
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x40(%rsp), %r15
xorl %r12d, %r12d
movl $0x2000, %edx           # imm = 0x2000
movq %r15, %rdi
xorl %esi, %esi
callq 0x2110
xorpd %xmm0, %xmm0
movapd %xmm0, 0x30(%rsp)
movapd %xmm0, 0x20(%rsp)
movapd %xmm0, 0x10(%rsp)
movapd %xmm0, (%rsp)
movq %r12, %rax
shlq $0xa, %rax
leaq (%rsp,%rax), %rdi
addq $0x40, %rdi
movzbl %r12b, %edx
movq %r14, %rsi
callq 0x28a7
xorl %eax, %eax
xorpd %xmm1, %xmm1
movl (%r15,%rax,4), %ecx
xorps %xmm0, %xmm0
cvtsi2sd %rcx, %xmm0
addsd %xmm0, %xmm1
incq %rax
cmpq $0x100, %rax            # imm = 0x100
jne 0x3df8
mulsd 0x5235(%rip), %xmm1     # 0x9050
xorpd %xmm0, %xmm0
xorl %eax, %eax
movl (%r15,%rax,4), %ecx
xorps %xmm2, %xmm2
cvtsi2sd %rcx, %xmm2
subsd %xmm1, %xmm2
mulsd %xmm2, %xmm2
addsd %xmm2, %xmm0
incq %rax
cmpq $0x100, %rax            # imm = 0x100
jne 0x3e21
divsd 0x520c(%rip), %xmm0     # 0x9058
ucomisd 0x520c(%rip), %xmm0     # 0x9060
jb 0x3e5c
sqrtsd %xmm0, %xmm0
jmp 0x3e61
callq 0x2180
movsd %xmm0, (%rsp,%r12,8)
incq %r12
addq $0x400, %r15            # imm = 0x400
cmpq $0x8, %r12
jne 0x3dd7
xorpd %xmm0, %xmm0
xorl %eax, %eax
xorl %ebp, %ebp
movsd (%rsp,%rax,8), %xmm1
ucomisd %xmm0, %xmm1
movl %eax, %ecx
cmovbel %ebp, %ecx
movl %ecx, %ebp
maxsd %xmm0, %xmm1
incq %rax
movapd %xmm1, %xmm0
cmpq $0x8, %rax
jne 0x3e83
movzwl %bp, %eax
shll $0xa, %eax
leaq (%rsp,%rax), %rsi
addq $0x40, %rsi
leaq 0x4(%rbx), %r14
movl $0x400, %edx            # imm = 0x400
movq %r14, %rdi
callq 0x2190
movl (%rbx), %eax
xorl %ecx, %ecx
addl (%r14,%rcx,4), %eax
movl %eax, (%r14,%rcx,4)
incq %rcx
cmpq $0x100, %rcx            # imm = 0x100
jne 0x3ec7
movb %bpl, 0x404(%rbx)
addq $0x2040, %rsp           # imm = 0x2040
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./huffman.h
// Function: huffman::HuffmanTree<unsigned char, unsigned long>::ConstructSymbolTable()
void ConstructSymbolTable() {
            RootNodeIterator<SymbolType, ValueType> RootIterator(this);
            HuffmanNode<SymbolType, ValueType>* RootNode;
            do {
                RootNode = &RootIterator.GetCurrentRootNode();
                //std::cout << "Symbol: " << (int) RootNode->GetSymbol() << std::endl;
                SymbolTable[RootNode->GetSymbol()] = RootIterator.GetCurrentIndex();
            } while (RootIterator++);

        }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rdi, %rbx
leaq 0x10(%rsp), %rdi
movq %rbx, %rsi
callq 0x72fa
leaq 0x18(%rsp), %r15
addq $0x8, %rbx
xorl %r14d, %r14d
leaq 0x40(%rsp), %r12
leaq 0xf(%rsp), %r13
movq 0x10(%rsp), %rsi
movq 0x18(%rsp), %rax
movq 0x28(%rsp), %rcx
movl 0x30(%rsp), %edx
movq (%rsi), %rbp
cmpq %rcx, %rax
setne %sil
testl %edx, %edx
setne %dil
orb %sil, %dil
cmpb $0x1, %dil
jne 0x4ef1
xorl %esi, %esi
movq (%rax), %rdi
xorl %r8d, %r8d
btq %rsi, %rdi
setb %r8b
xorl %edi, %edi
cmpl $0x3f, %esi
leal 0x1(%rsi), %esi
sete %dil
cmovel %r14d, %esi
leaq (%rax,%rdi,8), %rax
movq (%rbp,%r8,8), %rbp
cmpq %rcx, %rax
setne %dil
cmpl %edx, %esi
setne %r8b
orb %dil, %r8b
jne 0x4eb8
movq %r12, %rdi
movq %r15, %rsi
callq 0x794e
movb 0x11(%rbp), %al
movb %al, 0xf(%rsp)
movq %rbx, %rdi
movq %r13, %rsi
callq 0x735a
movq %rax, %rbp
movq %rax, %rdi
callq 0x7756
movq 0x60(%rsp), %rax
movq %rax, 0x20(%rbp)
movups 0x40(%rsp), %xmm0
movups 0x50(%rsp), %xmm1
movups %xmm1, 0x10(%rbp)
movups %xmm0, (%rbp)
movl %r14d, 0x48(%rsp)
movq $0x0, 0x50(%rsp)
movl %r14d, 0x58(%rsp)
leaq 0x10(%rsp), %rdi
xorl %esi, %esi
callq 0x73be
testb %al, %al
jne 0x4e8a
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x4f83
callq 0x21c0
xorl %eax, %eax
movq %rax, 0x18(%rsp)
movl %eax, 0x20(%rsp)
movq %rax, 0x28(%rsp)
movl %eax, 0x30(%rsp)
movq %rax, 0x38(%rsp)
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x4fb5
movq %rax, %rbx
movq 0x40(%rsp), %rsi
testq %rsi, %rsi
je 0x4fb8
leaq 0x40(%rsp), %rdi
callq 0x2360
jmp 0x4fb8
movq %rax, %rdi
callq 0x3f49
movq %rax, %rbx
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x4fe0
callq 0x21c0
xorl %eax, %eax
movq %rax, 0x18(%rsp)
movl %eax, 0x20(%rsp)
movq %rax, 0x28(%rsp)
movl %eax, 0x30(%rsp)
movq %rax, 0x38(%rsp)
movq %rbx, %rdi
callq 0x2320
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./huffman.h
// Function: huffman::RootNodeIterator<unsigned char, unsigned long>::RootNodeIterator(huffman::HuffmanTree<unsigned char, unsigned long>*)
explicit RootNodeIterator(HuffmanTree<SymbolType, ValueType>* ITree) {
            Tree = ITree;
            do {
                Index.push_back(0);
            } while (!(*Tree)[Index].IsRoot());
        }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
leaq 0x8(%rdi), %rbx
xorl %eax, %eax
movq %rax, 0x8(%rdi)
movl %eax, 0x10(%rdi)
movq %rax, 0x18(%rdi)
movl %eax, 0x20(%rdi)
movq %rax, 0x28(%rdi)
movq %rsi, (%rdi)
movq %rbx, %rdi
xorl %esi, %esi
callq 0x74e8
movq (%r14), %rdi
movq %rbx, %rsi
callq 0x7536
cmpb $0x1, 0x10(%rax)
jne 0x731c
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x7756
movq %r14, %rdi
callq 0x2320
movq %rax, %rdi
callq 0x3f49
// File: /workspace/github_cpp_makefile_star2_O1/cristian-bicheru[P]arith/./huffman.h
// Function: huffman::RootNodeIterator<unsigned char, unsigned long>::operator++(int)
bool operator++(int) {
            auto LastLeftBranch = std::find(Index.rbegin(), Index.rend(), false);
            if (LastLeftBranch != Index.rend()) {
                uint64_t LeftBranch = Index.size()-1ull-(LastLeftBranch-Index.rbegin());
                Index.resize(LeftBranch+1ull);
                Index[LeftBranch] = 1;
                while (!(*Tree)[Index].IsRoot()) {
                    Index.push_back(0);
                }
                //this->DumpIndex();
                return true;
            } else {
                return false;
            }

        }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
movq 0x8(%rdi), %rax
movq 0x18(%rdi), %rdx
movl 0x20(%rdi), %edi
leaq 0x7(%rsp), %rcx
movb $0x0, (%rcx)
leaq 0x28(%rsp), %rsi
movq %rdx, (%rsi)
movl %edi, 0x8(%rsi)
leaq 0x18(%rsp), %rdx
movq %rax, (%rdx)
movl $0x0, 0x8(%rdx)
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x7d03
movq 0x8(%rbx), %rcx
movq (%r14), %rax
movl 0x8(%r14), %edx
cmpq %rcx, %rax
setne %sil
testl %edx, %edx
setne %bpl
orb %sil, %bpl
cmpb $0x1, %bpl
jne 0x74d7
leaq 0x8(%rbx), %r14
movl %edx, %edx
movq 0x18(%rbx), %rsi
movl 0x20(%rbx), %edi
movq %rsi, %r8
subq %rcx, %r8
leaq (%rdi,%r8,8), %r12
subq %rax, %rsi
subq %rdx, %rdi
leaq (%rdi,%rsi,8), %r13
movq %r12, %rsi
subq %r13, %rsi
notq %r13
leaq (%r12,%r13), %r15
movq %r14, %rdi
xorl %edx, %edx
callq 0x7c96
leaq (%r12,%r13), %rax
addq $0x3f, %rax
testq %r15, %r15
cmovnsq %r15, %rax
sarq $0x6, %rax
shlq $0x3, %rax
addq 0x8(%rbx), %rax
movabsq $-0x8000000000000000, %rcx # imm = 0x8000000000000000
leaq 0x3f(%rcx), %rdx
andq %r15, %rdx
xorl %esi, %esi
cmpq %rcx, %rdx
setbe %sil
movl $0x1, %edx
movl %r15d, %ecx
shlq %cl, %rdx
orq %rdx, -0x8(%rax,%rsi,8)
movq (%rbx), %rdi
movq %r14, %rsi
callq 0x7536
cmpb $0x0, 0x10(%rax)
jne 0x74d7
movq %r14, %rdi
xorl %esi, %esi
callq 0x74e8
movq (%rbx), %rdi
movq %r14, %rsi
callq 0x7536
cmpb $0x1, 0x10(%rax)
jne 0x74bc
movl %ebp, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq