LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/ridgelab[P]Kmer-SSR/src/TaskQueue.cpp
// Function: TaskQueue::toString[abi:cxx11]()
string TaskQueue::toString()
{
	queue<Task*>* new_tasks = new queue<Task*>();

	string output = "TaskQueue: { ";

	sem_wait(&(this->lock));

	Task* front_task = this->tasks->front();
	
	while (!this->tasks->empty())
	{
		if (!front_task->equalTo(this->tasks->front()))
		{
			output += ", ";
		}
		
		output += this->tasks->front()->toString();
		
		new_tasks->push(this->tasks->front());
		this->tasks->pop();
	}

	output += " }";

	queue<Task*>* temp_ptr = this->tasks;
	this->tasks = new_tasks;
	delete temp_ptr;

	sem_post(&(this->lock));

	return output;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r14
movq %rdi, %rbx
pushq $0x50
popq %rdi
callq 0x2180
movq %rax, %r15
movq %rax, %rdi
callq 0x3830
leaq 0x2918(%rip), %rsi      # 0x5ebc
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x2e36
leaq 0x8(%r14), %rdi
movq %rdi, (%rsp)
callq 0x20c0
movq (%r14), %rcx
movq 0x10(%rcx), %rax
movq (%rax), %r13
leaq 0x8(%rsp), %rbp
leaq 0x28f6(%rip), %r12      # 0x5eca
cmpq %rax, 0x30(%rcx)
je 0x3639
movq (%rax), %rsi
movq %r13, %rdi
callq 0x3eee
testb %al, %al
jne 0x35f4
movq %rbx, %rdi
movq %r12, %rsi
callq 0x2280
movq (%r14), %rax
movq 0x10(%rax), %rax
movq (%rax), %rsi
movq %rbp, %rdi
callq 0x3f76
movq %rbx, %rdi
movq %rbp, %rsi
callq 0x2290
movq %rbp, %rdi
callq 0x2080
movq (%r14), %rax
movq 0x10(%rax), %rsi
movq %r15, %rdi
callq 0x3aca
movq (%r14), %rdi
callq 0x3cb6
movq (%r14), %rcx
movq 0x10(%rcx), %rax
jmp 0x35d4
leaq 0x288d(%rip), %rsi      # 0x5ecd
movq %rbx, %rdi
callq 0x2280
movq (%r14), %r12
movq %r15, (%r14)
testq %r12, %r12
je 0x365b
movq %r12, %rdi
callq 0x384c
pushq $0x50
popq %rsi
movq %r12, %rdi
callq 0x2190
movq (%rsp), %rdi
callq 0x2240
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x36a6
jmp 0x36a6
movq %rax, %r14
pushq $0x50
popq %rsi
movq %r15, %rdi
callq 0x2190
jmp 0x36b1
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x2080
jmp 0x36a9
jmp 0x36a6
movq %rax, %r14
movq %rbx, %rdi
callq 0x2080
movq %r14, %rdi
callq 0x2260
nop
// File: /workspace/github_cpp_makefile_star2_O2/ridgelab[P]Kmer-SSR/src/TaskQueue.cpp
// Function: TaskQueue::toJson[abi:cxx11]()
string TaskQueue::toJson()
{
	queue<Task*>* new_tasks = new queue<Task*>();

	string json = "TaskQueue: {";
	
	sem_wait(&(this->lock));
	
	Task* front_task = this->tasks->front();

	if (this->size() != 0)
	{
		json += "\n\t";
		
		while (!this->tasks->empty())
		{
			if (!front_task->equalTo(this->tasks->front()))
			{
				json += ",\n\t";
			}
			
			json += this->tasks->front()->toString();;

			new_tasks->push(this->tasks->front());
			this->tasks->pop();
		}

		json += '\n';
	}
	else
	{
		json += ' ';
	}

	json += '}';

	queue<Task*>* temp_ptr = this->tasks;
	this->tasks = new_tasks;
	delete temp_ptr;
	
	sem_post(&(this->lock));

	return json;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r14
movq %rdi, %rbx
pushq $0x50
popq %rdi
callq 0x2180
movq %rax, %r15
movq %rax, %rdi
callq 0x3830
leaq 0x27e8(%rip), %rsi      # 0x5ed0
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x2e36
leaq 0x8(%r14), %rbp
movq %rbp, %rdi
callq 0x20c0
movq (%r14), %rax
movq 0x10(%rax), %rax
movq (%rax), %r13
movq %r14, %rdi
callq 0x34c2
testl %eax, %eax
je 0x37a7
leaq 0x27bc(%rip), %rsi      # 0x5ede
movq %rbx, %rdi
callq 0x2280
movq %rbp, (%rsp)
leaq 0x8(%rsp), %rbp
leaq 0x27a3(%rip), %r12      # 0x5edd
movq (%r14), %rcx
movq 0x10(%rcx), %rax
cmpq %rax, 0x30(%rcx)
je 0x379f
movq (%rax), %rsi
movq %r13, %rdi
callq 0x3eee
testb %al, %al
jne 0x3761
movq %rbx, %rdi
movq %r12, %rsi
callq 0x2280
movq (%r14), %rax
movq 0x10(%rax), %rax
movq (%rax), %rsi
movq %rbp, %rdi
callq 0x3f76
movq %rbx, %rdi
movq %rbp, %rsi
callq 0x2290
movq %rbp, %rdi
callq 0x2080
movq (%r14), %rax
movq 0x10(%rax), %rsi
movq %r15, %rdi
callq 0x3aca
movq (%r14), %rdi
callq 0x3cb6
jmp 0x373a
movb $0xa, %al
movq (%rsp), %rbp
jmp 0x37a9
movb $0x20, %al
movzbl %al, %esi
movq %rbx, %rdi
callq 0x2130
pushq $0x7d
popq %rsi
movq %rbx, %rdi
callq 0x2130
movq (%r14), %r12
movq %r15, (%r14)
testq %r12, %r12
je 0x37d2
movq %r12, %rdi
callq 0x384c
pushq $0x50
popq %rsi
movq %r12, %rdi
callq 0x2190
movq %rbp, %rdi
callq 0x2240
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x381c
movq %rax, %r14
pushq $0x50
popq %rsi
movq %r15, %rdi
callq 0x2190
jmp 0x3827
jmp 0x381c
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x2080
jmp 0x381f
jmp 0x381c
movq %rax, %r14
movq %rbx, %rdi
callq 0x2080
movq %r14, %rdi
callq 0x2260
nop
// File: /workspace/github_cpp_makefile_star2_O2/ridgelab[P]Kmer-SSR/src/Task.cpp
// Function: Task::Task(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&, unsigned int, unsigned int)
Task::Task(const string &_identifier, const string &_sequence, uint32_t _global_pos, uint32_t _global_seq_length)
{
	this->identifier = _identifier;
	this->sequence = _sequence;
	this->global_pos = _global_pos;
	this->global_seq_length = _global_seq_length;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %r8d, %ebp
movl %ecx, %r14d
movq %rdx, %r12
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
xorl %eax, %eax
movb %al, 0x10(%rdi)
leaq 0x20(%rdi), %r15
leaq 0x30(%rdi), %rcx
movq %rcx, 0x20(%rdi)
andq $0x0, 0x28(%rdi)
movb %al, 0x30(%rdi)
callq 0x20b0
movq %r15, %rdi
movq %r12, %rsi
callq 0x20b0
movl %r14d, 0x40(%rbx)
movl %ebp, 0x44(%rbx)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq %r15, %rdi
callq 0x2080
movq %rbx, %rdi
callq 0x2080
movq %r14, %rdi
callq 0x2260
// File: /workspace/github_cpp_makefile_star2_O2/ridgelab[P]Kmer-SSR/src/Task.cpp
// Function: Task::equalTo(Task*) const
bool Task::equalTo(Task* other) const
{
	if (this->identifier != other->getID())
	{
		return false;
	}
	if (this->sequence != other->getSequence())
	{
		return false;
	}
	if (this->global_pos != other->getGlobalPosition())
	{
		return false;
	}
	if (this->global_seq_length != other->getGlobalSequenceLength())
	{
		return false;
	}

	return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x20, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movq %rsp, %r15
movq %r15, %rdi
callq 0x21d0
movq %r14, %rdi
movq %r15, %rsi
callq 0x4129
movl %eax, %ebp
movq %r15, %rdi
callq 0x2080
testb %bpl, %bpl
jne 0x3f67
leaq 0x20(%r14), %r15
leaq 0x20(%rbx), %rsi
movq %rsp, %r12
movq %r12, %rdi
callq 0x21d0
movq %r15, %rdi
movq %r12, %rsi
callq 0x4129
movl %eax, %ebp
movq %r12, %rdi
callq 0x2080
testb %bpl, %bpl
jne 0x3f67
movl 0x40(%r14), %eax
cmpl 0x40(%rbx), %eax
jne 0x3f67
movl 0x44(%r14), %eax
cmpl 0x44(%rbx), %eax
sete %al
jmp 0x3f69
xorl %eax, %eax
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/dm4[P]huffman-homework/my_encode.cc
// Function: assignCLRecursive(int, char)
void assignCLRecursive(int index, char cl) {
    CLRecordEntry *entry = CLRecord[index];
    entry->cl = cl;
    if (entry->s1 < 0)
        assignCLRecursive(~entry->s1, cl + 1);
    if (entry->s2 < 0)
        assignCLRecursive(~entry->s2, cl + 1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %esi, %ebx
movq 0x5d55(%rip), %rax      # 0x7130
movslq %edi, %rcx
movq (%rax,%rcx,8), %r14
movb %bl, 0x8(%r14)
movl (%r14), %edi
testl %edi, %edi
jns 0x1401
notl %edi
leal 0x1(%rbx), %eax
movsbl %al, %esi
callq 0x13cb
movq 0x5d2f(%rip), %rax      # 0x7130
movl 0x4(%r14), %edi
testl %edi, %edi
jns 0x140f
notl %edi
incb %bl
jmp 0x13db
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/dm4[P]huffman-homework/my_encode.cc
// Function: buildSymbols()
void buildSymbols() {
    for (int i = CLRecord.size() - 1; i >= 0; i--) {
        CLRecordEntry *entry = CLRecord[i];
        if (entry->s1 >= 0) {
            Symbol *s = (Symbol *)malloc(sizeof(Symbol));
            s->cl = entry->cl;
            s->symbol = entry->s1;
            symbols.push_back(s);
        }
        if (entry->s2 >= 0) {
            Symbol *s = (Symbol *)malloc(sizeof(Symbol));
            s->cl = entry->cl;
            s->symbol = entry->s2;
            symbols.push_back(s);
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq 0x5cec(%rip), %rax      # 0x7138
subq 0x5cdd(%rip), %rax      # 0x7130
shrq $0x3, %rax
movl %eax, %r12d
decq %r12
leaq 0x5ce4(%rip), %r14      # 0x7148
leaq -0x30(%rbp), %r15
testl %r12d, %r12d
js 0x14d7
movl %r12d, %eax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movq 0x5cb4(%rip), %rcx      # 0x7130
movq (%rcx,%rax,8), %r13
movl (%r13), %ebx
testl %ebx, %ebx
js 0x14a9
pushq $0x8
popq %rdi
callq 0x1150
movq %rax, -0x30(%rbp)
movb 0x8(%r13), %cl
movb %cl, 0x4(%rax)
movb %bl, 0x5(%rax)
movq %r14, %rdi
movq %r15, %rsi
callq 0x1ab8
movl 0x4(%r13), %ebx
testl %ebx, %ebx
js 0x14d2
pushq $0x8
popq %rdi
callq 0x1150
movq %rax, -0x30(%rbp)
movb 0x8(%r13), %cl
movb %cl, 0x4(%rax)
movb %bl, 0x5(%rax)
movq %r14, %rdi
movq %r15, %rsi
callq 0x1ab8
decq %r12
jmp 0x1468
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/dm4[P]huffman-homework/my_encode.cc
// Function: buildSymbolsCodeword()
void buildSymbolsCodeword() {
    unsigned int codeword = 0;
    symbols[0]->codeword = codeword;
    for (int i = 1; i < symbols.size(); i++) {
        int lengthDiff = symbols[i]->cl - symbols[i - 1]->cl;
        codeword += 1;
        codeword <<= lengthDiff;
        symbols[i]->codeword = codeword;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq 0x5c57(%rip), %rax      # 0x7148
movq (%rax), %rcx
andl $0x0, (%rcx)
movq 0x5c52(%rip), %rdx      # 0x7150
subq %rax, %rdx
sarq $0x3, %rdx
xorl %esi, %esi
movabsq $0x1, %rdi
cmpq %rdi, %rdx
jbe 0x1533
movq -0x8(%rax,%rdi,8), %r8
movq (%rax,%rdi,8), %r9
movl 0x4(%r9), %ecx
subl 0x4(%r8), %ecx
incl %esi
shll %cl, %esi
movl %esi, (%r9)
incq %rdi
jmp 0x1511
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/ArashPartow[P]exprtk-extras/exprtk_wiener_process_pi.cpp
// Function: void wiener_process_pi<double>()
void wiener_process_pi()
{
   typedef exprtk::symbol_table<T> symbol_table_t;
   typedef exprtk::expression<T>   expression_t;
   typedef exprtk::parser<T>       parser_t;

   const std::string wiener_process_pi_program =
      " var w[10^4] := [0];                            "
      "                                                "
      " for (var i := 0; i < w[]; i += 1)              "
      " {                                              "
      "    var x[10^4] := [(rnd_01 < 1 / 2) ? -1 : 1]; "
      "    w[i]        := sum(x);                      "
      " }                                              "
      "                                                "
      " (2 * w[]) / avg(abs(w))^2;                     ";

   rnd_01<T> rnd01;

   symbol_table_t symbol_table;
   symbol_table.add_function("rnd_01",rnd01);

   expression_t expression;
   expression.register_symbol_table(symbol_table);

   parser_t parser;
   parser.compile(wiener_process_pi_program,expression);

   const T approximate_pi = expression.value();

   const T real_pi = T(3.141592653589793238462643383279502); // or close enough...

   printf("pi ~ %20.17f\terror: %20.17f\n",
          approximate_pi,
          std::abs(real_pi - approximate_pi));
}

// Assembly:
pushq %rbx
subq $0xaf0, %rsp            # imm = 0xAF0
leaq 0x12addf(%rip), %rsi    # 0x23b111
leaq 0x30(%rsp), %rdi
leaq 0x1c8(%rsp), %rdx
callq 0x1102e8
leaq 0x50(%rsp), %rdi
callq 0x110566
leaq 0x8(%rsp), %rdi
pushq $0x1
popq %rsi
callq 0x110596
leaq 0x12af60(%rip), %rsi    # 0x23b2c2
leaq 0x1c8(%rsp), %rdi
leaq 0x78(%rsp), %rdx
callq 0x1102e8
leaq 0x8(%rsp), %rdi
leaq 0x1c8(%rsp), %rsi
leaq 0x50(%rsp), %rdx
callq 0x1105ba
leaq 0x1c8(%rsp), %rdi
callq 0x10e5e8
leaq 0x10(%rsp), %rdi
callq 0x11061a
leaq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x11067a
leaq 0x78(%rsp), %rdi
pushq $0x7f
popq %rsi
callq 0x1106d6
leaq 0x1c8(%rsp), %rdi
leaq 0x78(%rsp), %rsi
callq 0x1107e6
leaq 0x78(%rsp), %rdi
callq 0x110dfe
leaq 0x1c8(%rsp), %rdi
leaq 0x30(%rsp), %rsi
leaq 0x10(%rsp), %rdx
callq 0x110e46
movq 0x10(%rsp), %rax
movq 0x8(%rax), %rdi
movq (%rdi), %rax
callq *0x18(%rax)
movsd 0x125c00(%rip), %xmm1   # 0x236008
subsd %xmm0, %xmm1
andpd 0x125ccc(%rip), %xmm1   # 0x2360e0
leaq 0x12aeae(%rip), %rdi    # 0x23b2c9
movb $0x2, %al
callq 0x10e060
leaq 0x1c8(%rsp), %rdi
callq 0x1112c8
leaq 0x10(%rsp), %rdi
callq 0x111402
leaq 0x8(%rsp), %rdi
callq 0x111418
leaq 0x30(%rsp), %rdi
callq 0x10e5e8
addq $0xaf0, %rsp            # imm = 0xAF0
popq %rbx
retq
jmp 0x110458
movq %rax, %rbx
leaq 0x1c8(%rsp), %rdi
callq 0x1112c8
jmp 0x11047e
movq %rax, %rbx
leaq 0x78(%rsp), %rdi
callq 0x110dfe
jmp 0x11047e
jmp 0x11047b
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x111402
jmp 0x1104a1
jmp 0x11049e
movq %rax, %rbx
leaq 0x1c8(%rsp), %rdi
callq 0x10e5e8
jmp 0x1104a1
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x111418
jmp 0x1104b2
jmp 0x1104af
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0x10e5e8
movq %rbx, %rdi
callq 0x10e310
// File: /workspace/github_cpp_makefile_star2_O2/Erkaman[P]spiky-anim/main.cpp
// Function: zeroPad[abi:cxx11](int, int)
std::string zeroPad(int n, int len) {
    string str = "";

    str = to_string(n);

    while(str.size() < len) {
        str = "0" + str;
    }

    return str;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x20, %rsp
movl %edx, %r15d
movl %esi, %r14d
movq %rdi, %rbx
leaq 0x1def(%rip), %rsi      # 0x414a
leaq -0x40(%rbp), %rdx
callq 0x2cb0
leaq -0x40(%rbp), %rdi
movl %r14d, %esi
callq 0x2ceb
leaq -0x40(%rbp), %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2180
movq %r14, %rdi
callq 0x2090
movslq %r15d, %r12
leaq 0x1cbf(%rip), %r15      # 0x4050
cmpq %r12, 0x8(%rbx)
jae 0x23ba
movq %r14, %rdi
movq %r15, %rsi
movq %rbx, %rdx
callq 0x2d4b
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2180
movq %r14, %rdi
callq 0x2090
jmp 0x2391
movq %rbx, %rax
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0x23cc
movq %rax, %r14
movq %rbx, %rdi
callq 0x2090
movq %r14, %rdi
callq 0x21f0
// File: /workspace/github_cpp_makefile_star2_O2/eschwabe[P]interview-practice/src/libds_list.cpp
// Function: List::AppendHead(int const&)
void List::AppendHead(const int& value) {
  if(head_.get() == nullptr) {
    head_.reset(new List::Node());
    head_.get()->value = value;
    tail_ = head_.get();
  } else {
    List::Node* tmp = new List::Node();
    tmp->value = value;
    tmp->next = std::move(head_);
    head_.reset(tmp);
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq (%rdi), %r12
pushq $0x10
popq %rdi
callq 0x1050
movq %rax, %r15
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
testq %r12, %r12
je 0x1229
movl (%r14), %eax
movl %eax, 0x8(%r15)
movq %r15, %rdi
movq %rbx, %rsi
callq 0x1562
movq %rbx, %rdi
movq %r15, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x157a
movq %rbx, %rdi
movq %r15, %rsi
callq 0x157a
movl (%r14), %eax
movq (%rbx), %rcx
movl %eax, 0x8(%rcx)
movq %rcx, 0x8(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/eschwabe[P]interview-practice/src/libds_list.cpp
// Function: List::AppendTail(int const&)
void List::AppendTail(const int& value) {
  if(head_.get() == nullptr) {
    head_.reset(new List::Node());
    head_.get()->value = value;
    tail_ = head_.get();
  } else {
    List::Node* tmp = new List::Node();
    tmp->value = value;
    tmp->next = nullptr;
    tail_->next.reset(tmp);
    tail_ = tail_->next.get();
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r15
movq %rdi, %rbx
movq (%rdi), %r12
pushq $0x10
popq %rdi
callq 0x1050
movq %rax, %r14
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
testq %r12, %r12
je 0x129f
movl (%r15), %eax
movl %eax, 0x8(%r14)
movq %r14, %rdi
xorl %esi, %esi
callq 0x157a
movq 0x8(%rbx), %rdi
movq %r14, %rsi
callq 0x157a
movq 0x8(%rbx), %rax
movq (%rax), %rax
movq %rax, 0x8(%rbx)
jmp 0x12b7
movq %rbx, %rdi
movq %r14, %rsi
callq 0x157a
movl (%r15), %eax
movq (%rbx), %rcx
movl %eax, 0x8(%rcx)
movq %rcx, 0x8(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/eschwabe[P]interview-practice/src/libds_list.cpp
// Function: List::RemoveTail()
int List::RemoveTail() {
  if(tail_ == nullptr) {
    return -1;
  } else if(head_.get() == tail_) {
    int tmp = tail_->value;
    tail_ = nullptr;
    head_.release();
    return tmp;
  } else {
    int tmp = tail_->value;
    Node* prev = nullptr;
    Node* current = head_.get();
    while(current != nullptr && current->next.get() != nullptr) {
      prev = current;
      current = current->next.get();
    }
    prev->next.release();
    tail_ = prev;
    return tmp;
  }
}

// Assembly:
movq 0x8(%rdi), %rdx
testq %rdx, %rdx
je 0x1313
movq (%rdi), %rcx
movl 0x8(%rdx), %eax
cmpq %rdx, %rcx
je 0x1317
xorl %esi, %esi
movq %rsi, %rdx
testq %rcx, %rcx
je 0x130a
movq %rcx, %rsi
movq (%rcx), %r8
movq %r8, %rcx
testq %r8, %r8
jne 0x12f4
andq $0x0, (%rdx)
movq %rdx, 0x8(%rdi)
retq
pushq $-0x1
popq %rax
retq
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
retq
// File: /workspace/github_cpp_makefile_star2_O2/eschwabe[P]interview-practice/src/libds_list.cpp
// Function: main
int main()
{
  List l;
  l.AppendTail(10);
  l.AppendHead(1);
  l.AppendHead(2);
  l.AppendTail(12);
  l.AppendHead(3);
  l.AppendTail(11);
  l.AppendHead(4);
  l.AppendTail(13);
  std::cout << l.RemoveHead() << std::endl;
  std::cout << l.RemoveTail() << std::endl;
  std::cout << l.RemoveHead() << std::endl;
  std::cout << l.RemoveTail() << std::endl;
  std::cout << l.RemoveHead() << std::endl;
  std::cout << l.RemoveTail() << std::endl;
  std::cout << l.RemoveHead() << std::endl;
  std::cout << l.RemoveTail() << std::endl;
  std::cout << l.RemoveHead() << std::endl;
  std::cout << l.RemoveTail() << std::endl;
  return 0;
}

// Assembly:
pushq %rbx
subq $0x20, %rsp
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %rdi
movaps %xmm0, (%rdi)
leaq 0xc(%rsp), %rsi
movl $0xa, (%rsi)
callq 0x124e
leaq 0xc(%rsp), %rsi
movl $0x1, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x11da
leaq 0xc(%rsp), %rsi
movl $0x2, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x11da
leaq 0xc(%rsp), %rsi
movl $0xc, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x124e
leaq 0xc(%rsp), %rsi
movl $0x3, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x11da
leaq 0xc(%rsp), %rsi
movl $0xb, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x124e
leaq 0xc(%rsp), %rsi
movl $0x4, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x11da
leaq 0xc(%rsp), %rsi
movl $0xd, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x124e
leaq 0x10(%rsp), %rdi
callq 0x12c4
movq 0x2bf6(%rip), %rdi      # 0x3fd8
movl %eax, %esi
callq 0x1080
movq %rax, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x12de
movq 0x2bd6(%rip), %rdi      # 0x3fd8
movl %eax, %esi
callq 0x1080
movq %rax, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x12c4
movq 0x2bb6(%rip), %rdi      # 0x3fd8
movl %eax, %esi
callq 0x1080
movq %rax, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x12de
movq 0x2b96(%rip), %rdi      # 0x3fd8
movl %eax, %esi
callq 0x1080
movq %rax, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x12c4
movq 0x2b76(%rip), %rdi      # 0x3fd8
movl %eax, %esi
callq 0x1080
movq %rax, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x12de
movq 0x2b56(%rip), %rdi      # 0x3fd8
movl %eax, %esi
callq 0x1080
movq %rax, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x12c4
movq 0x2b36(%rip), %rdi      # 0x3fd8
movl %eax, %esi
callq 0x1080
movq %rax, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x12de
movq 0x2b16(%rip), %rdi      # 0x3fd8
movl %eax, %esi
callq 0x1080
movq %rax, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x12c4
movq 0x2af6(%rip), %rdi      # 0x3fd8
movl %eax, %esi
callq 0x1080
movq %rax, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x12de
movq 0x2ad6(%rip), %rdi      # 0x3fd8
movl %eax, %esi
callq 0x1080
movq %rax, %rdi
callq 0x1030
leaq 0x10(%rsp), %rdi
callq 0x1548
xorl %eax, %eax
addq $0x20, %rsp
popq %rbx
retq
jmp 0x1533
jmp 0x1533
jmp 0x1533
jmp 0x1533
jmp 0x1533
jmp 0x1533
jmp 0x1533
jmp 0x1533
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x1548
movq %rbx, %rdi
callq 0x1090
// File: /workspace/github_cpp_makefile_star2_O2/CMU-SAFARI[P]optimal-seed-solver/thresholdSolver.cc
// Function: ThresholdSolver::init(int, int)
void ThresholdSolver::init(int readLength, int seedNum)
{
	this->seedNum = seedNum;
	vector< int > thresholdVec (seedNum);
	for(int i = 0; i < thresholdVec.size(); i++)
		thresholdVec[i] = readLength;
	this->thresholdVec = thresholdVec;
	this->frequencyVec.resize(thresholdVec.size(), -1);
	this->lengthVec.resize(thresholdVec.size(), 0);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x20, %rsp
movl %esi, %ebp
movq %rdi, %rbx
movl %edx, 0xc8(%rdi)
movslq %edx, %rsi
leaq 0x8(%rsp), %r14
leaq 0x4(%rsp), %rdx
movq %r14, %rdi
callq 0x59b0
movq (%r14), %rax
movq 0x8(%r14), %rcx
subq %rax, %rcx
sarq $0x2, %rcx
xorl %edx, %edx
cmpq %rdx, %rcx
jbe 0x473d
movl %ebp, (%rax,%rdx,4)
incq %rdx
jmp 0x4730
leaq 0x450(%rbx), %rdi
leaq 0x8(%rsp), %rsi
callq 0x5a02
leaq 0x480(%rbx), %rdi
movq 0x10(%rsp), %rsi
subq 0x8(%rsp), %rsi
sarq $0x2, %rsi
leaq 0x4(%rsp), %rdx
orl $-0x1, (%rdx)
callq 0x3d4a
addq $0x468, %rbx            # imm = 0x468
movq 0x10(%rsp), %rsi
subq 0x8(%rsp), %rsi
sarq $0x2, %rsi
leaq 0x4(%rsp), %rdx
andl $0x0, (%rdx)
movq %rbx, %rdi
callq 0x3d4a
leaq 0x8(%rsp), %rdi
callq 0x3f42
addq $0x20, %rsp
popq %rbx
popq %r14
popq %rbp
retq
jmp 0x47ac
jmp 0x47ac
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x3f42
movq %rbx, %rdi
callq 0x3470
nop
// File: /workspace/github_cpp_makefile_star2_O2/CMU-SAFARI[P]optimal-seed-solver/thresholdSolver.cc
// Function: ThresholdSolver::analyzeRead(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void ThresholdSolver::analyzeRead(string read) {
	int minLength = tree.getHashLength();
	int maxLength = tree.getFullLength();

	int pos = 0;

	for (int i = 0; i < thresholdVec.size(); i++) {
		string seed = read.substr(pos, maxLength);

		tree.query(seed, thresholdVec[i]);
		frequencyVec[i] = tree.frequency();
		lengthVec[i] = tree.effectiveLength();
		pos += tree.effectiveLength();

		if (pos > read.length() - minLength)
			break;
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0xd0(%rdi), %r15
movq %r15, %rdi
callq 0x6e46
movl %eax, %ebp
movq %r15, %rdi
callq 0x6e4a
cltq
movq %rax, 0x10(%rsp)
movslq %ebp, %rax
movq %rax, (%rsp)
xorl %r12d, %r12d
xorl %r13d, %r13d
movq %r14, 0x8(%rsp)
movq 0x458(%r14), %rax
subq 0x450(%r14), %rax
sarq $0x2, %rax
cmpq %r12, %rax
jbe 0x492c
movslq %r13d, %rdx
leaq 0x38(%rsp), %rbp
movq %rbp, %rdi
movq %rbx, %rsi
movq 0x10(%rsp), %rcx
callq 0x3280
leaq 0x18(%rsp), %rdi
movq %rbp, %rsi
callq 0x3380
movq 0x450(%r14), %rax
movl (%rax,%r12,4), %edx
movq %r15, %rdi
leaq 0x18(%rsp), %rbp
movq %rbp, %rsi
callq 0x6e4e
movq %rbp, %rdi
callq 0x3110
movq %r15, %rdi
callq 0x6f98
movq 0x480(%r14), %rcx
movl %eax, (%rcx,%r12,4)
movq %r15, %rdi
callq 0x6f90
movq 0x468(%r14), %rcx
movl %eax, (%rcx,%r12,4)
movq %r15, %rdi
callq 0x6f90
addl %eax, %r13d
movslq %r13d, %rbp
movq %r15, %r14
movq %rbx, %r15
movq 0x8(%rbx), %rbx
subq (%rsp), %rbx
leaq 0x38(%rsp), %rdi
callq 0x3110
incq %r12
cmpq %rbp, %rbx
movq %r15, %rbx
movq %r14, %r15
movq 0x8(%rsp), %r14
jae 0x4866
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x18(%rsp), %rdi
callq 0x3110
jmp 0x494d
movq %rax, %rbx
leaq 0x38(%rsp), %rdi
callq 0x3110
movq %rbx, %rdi
callq 0x3470
nop
// File: /workspace/github_cpp_makefile_star2_O2/CMU-SAFARI[P]optimal-seed-solver/thresholdSolver.cc
// Function: ThresholdSolver::printFreqTable()
void ThresholdSolver::printFreqTable() {
	cout << "Printing Frequency Table." << endl;
	for (int i = 0; i < freqTable.size(); i++)
	{
		for (int j = 0; j<freqTable[i].size(); j++)
			cout << freqTable[i][j] << " ";
		cout << "" << endl;
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0xa94b(%rip), %r14      # 0xffc8
leaq 0x4c1d(%rip), %rsi      # 0xa2a1
movq %r14, %rdi
callq 0x3250
movq %rax, %rdi
callq 0x3120
xorl %r13d, %r13d
leaq 0x4a78(%rip), %r15      # 0xa116
movq 0x30(%rbx), %rcx
movq 0x38(%rbx), %rax
subq %rcx, %rax
cqto
pushq $0x18
popq %rsi
idivq %rsi
cmpq %r13, %rax
jbe 0x570e
imulq $0x18, %r13, %rbp
xorl %r12d, %r12d
movq (%rcx,%rbp), %rax
movq 0x8(%rcx,%rbp), %rcx
subq %rax, %rcx
sarq $0x2, %rcx
cmpq %r12, %rcx
jbe 0x56f2
movl (%rax,%r12,4), %esi
movq %r14, %rdi
callq 0x3450
movq %rax, %rdi
movq %r15, %rsi
callq 0x3250
incq %r12
movq 0x30(%rbx), %rcx
jmp 0x56bd
movq %r14, %rdi
leaq 0x4dcf(%rip), %rsi      # 0xa4cb
callq 0x3250
movq %rax, %rdi
callq 0x3120
incq %r13
jmp 0x569e
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/CMU-SAFARI[P]optimal-seed-solver/thresholdSolver.cc
// Function: ThresholdSolver::printTotalFreqTable()
void ThresholdSolver::printTotalFreqTable() {
	cout << "seedNum: " << seedNum << endl;
	for(int i = 0; i < totalFrequency.size(); i++)
	{
		if(totalFrequency[i] != 0)
			cout << i-1 << ": " << totalFrequency[i] << endl;
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0xa898(%rip), %r14      # 0xffc8
leaq 0x493c(%rip), %rsi      # 0xa073
movq %r14, %rdi
callq 0x3250
movl 0xc8(%rbx), %esi
movq %rax, %rdi
callq 0x3450
movq %rax, %rdi
callq 0x3120
xorl %r12d, %r12d
leaq 0x4e2d(%rip), %r15      # 0xa58c
movq 0xa8(%rbx), %rax
movq 0xb0(%rbx), %rcx
subq %rax, %rcx
sarq $0x2, %rcx
cmpq %r12, %rcx
jbe 0x57b8
cmpl $0x0, (%rax,%r12,4)
je 0x57b3
leal -0x1(%r12), %esi
movq %r14, %rdi
callq 0x3450
movq %rax, %rdi
movq %r15, %rsi
callq 0x3250
movq 0xa8(%rbx), %rcx
movl (%rcx,%r12,4), %esi
movq %rax, %rdi
callq 0x3450
movq %rax, %rdi
callq 0x3120
incq %r12
jmp 0x575f
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/CMU-SAFARI[P]optimal-seed-solver/thresholdSolver.cc
// Function: ThresholdSolver::printInfo()
void ThresholdSolver::printInfo() {
	cout << "Thresholds: ";
	for (int i = 0; i < thresholdVec.size(); i++)
		cout << "\t|" << thresholdVec[i];

	cout << endl << "Lengths:";
	for (int i = 0; i < thresholdVec.size(); i++)
		cout << "\t|" << lengthVec[i];

	cout << endl << "Frequencys:";
	for (int i = 0; i < thresholdVec.size(); i++)
		cout << "\t|" << frequencyVec[i];

	int pos = 0;
	cout << endl << "Seeds:" << endl;
	for (int i = 0; i < thresholdVec.size(); i++) {
		cout << read.substr(pos, lengthVec[i]) << endl;
		pos += lengthVec[i];
		if (lengthVec[i] == 0)
			break;
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
movq 0xa7ec(%rip), %r14      # 0xffc8
leaq 0x4ad8(%rip), %rsi      # 0xa2bb
movq %r14, %rdi
callq 0x3250
xorl %r12d, %r12d
leaq 0x4ad3(%rip), %r15      # 0xa2c8
movq 0x458(%rbx), %rax
subq 0x450(%rbx), %rax
sarq $0x2, %rax
cmpq %r12, %rax
jbe 0x582f
movq %r14, %rdi
movq %r15, %rsi
callq 0x3250
movq 0x450(%rbx), %rcx
movl (%rcx,%r12,4), %esi
movq %rax, %rdi
callq 0x3450
incq %r12
jmp 0x57f5
movq 0xa792(%rip), %r14      # 0xffc8
movq %r14, %rdi
callq 0x3120
leaq 0x4a86(%rip), %rsi      # 0xa2cb
movq %rax, %rdi
callq 0x3250
xorl %r12d, %r12d
leaq 0x4a71(%rip), %r15      # 0xa2c8
movq 0x458(%rbx), %rax
subq 0x450(%rbx), %rax
sarq $0x2, %rax
cmpq %r12, %rax
jbe 0x5891
movq %r14, %rdi
movq %r15, %rsi
callq 0x3250
movq 0x468(%rbx), %rcx
movl (%rcx,%r12,4), %esi
movq %rax, %rdi
callq 0x3450
incq %r12
jmp 0x5857
movq 0xa730(%rip), %r14      # 0xffc8
movq %r14, %rdi
callq 0x3120
leaq 0x4a2d(%rip), %rsi      # 0xa2d4
movq %rax, %rdi
callq 0x3250
xorl %r12d, %r12d
leaq 0x4a0f(%rip), %r15      # 0xa2c8
movq 0x458(%rbx), %rax
subq 0x450(%rbx), %rax
sarq $0x2, %rax
cmpq %r12, %rax
jbe 0x58f3
movq %r14, %rdi
movq %r15, %rsi
callq 0x3250
movq 0x480(%rbx), %rcx
movl (%rcx,%r12,4), %esi
movq %rax, %rdi
callq 0x3450
incq %r12
jmp 0x58b9
movq 0xa6ce(%rip), %r14      # 0xffc8
movq %r14, %rdi
callq 0x3120
leaq 0x49d7(%rip), %rsi      # 0xa2e0
movq %rax, %rdi
callq 0x3250
movq %rax, %rdi
callq 0x3120
leaq 0x430(%rbx), %r15
xorl %r13d, %r13d
leaq 0x8(%rsp), %r12
xorl %ebp, %ebp
movq 0x458(%rbx), %rax
subq 0x450(%rbx), %rax
sarq $0x2, %rax
cmpq %r13, %rax
jbe 0x598b
movslq %ebp, %rdx
movq 0x468(%rbx), %rax
movslq (%rax,%r13,4), %rcx
movq %r12, %rdi
movq %r15, %rsi
callq 0x3280
movq %r14, %rdi
movq %r12, %rsi
callq 0x3220
movq %rax, %rdi
callq 0x3120
movq %r12, %rdi
callq 0x3110
movq 0x468(%rbx), %rax
movl (%rax,%r13,4), %eax
testl %eax, %eax
je 0x598b
addl %eax, %ebp
incq %r13
jmp 0x592a
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x3110
movq %rbx, %rdi
callq 0x3470
nop
// File: /workspace/github_cpp_makefile_star2_O2/devvoid[P]vini/./vini.hpp
// Function: Vini::Vini(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
Vini(std::string path) : ini_file() {
        std::ifstream file;

        file.open(path.c_str());

        std::stringstream stringbuffer;

        stringbuffer << file.rdbuf();

        file.close();
        
        parse_text(stringbuffer.str());
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x3b0, %rsp            # imm = 0x3B0
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x8(%rdi), %rax
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
andq $0x0, 0x10(%rdi)
movq %rax, 0x18(%rdi)
movq %rax, 0x20(%rdi)
andq $0x0, 0x28(%rdi)
leaq -0x3c0(%rbp), %rdi
callq 0x2210
movq (%r14), %rsi
leaq -0x3c0(%rbp), %rdi
pushq $0x8
popq %rdx
callq 0x2130
leaq -0x1b8(%rbp), %rdi
callq 0x2150
leaq -0x1a8(%rbp), %rdi
leaq -0x3b0(%rbp), %rsi
callq 0x2070
leaq -0x3c0(%rbp), %rdi
callq 0x2060
leaq -0x1a0(%rbp), %rsi
leaq -0x30(%rbp), %rdi
callq 0x2270
leaq -0x30(%rbp), %rsi
movq %rbx, %rdi
callq 0x2d4c
leaq -0x30(%rbp), %rdi
callq 0x20f0
leaq -0x1b8(%rbp), %rdi
callq 0x2170
leaq -0x3c0(%rbp), %rdi
callq 0x2090
addq $0x3b0, %rsp            # imm = 0x3B0
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %r14
leaq -0x30(%rbp), %rdi
callq 0x20f0
jmp 0x2aa7
jmp 0x2a9a
movq %rax, %r14
jmp 0x2ab3
movq %rax, %r14
jmp 0x2abf
movq %rax, %r14
leaq -0x1b8(%rbp), %rdi
callq 0x2170
leaq -0x3c0(%rbp), %rdi
callq 0x2090
movq %rbx, %rdi
callq 0x409a
movq %r14, %rdi
callq 0x22b0
nop
// File: /workspace/github_cpp_makefile_star2_O2/devvoid[P]vini/./vini.hpp
// Function: Vini::get(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::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
std::string get(std::string section, std::string key, std::string default_value) {
        if (ini_file[section][key] != "")
            return ini_file[section][key];
        
        //If it can't find anything, return default value.
        set(section, key, default_value);

        return default_value;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %r8, %r14
movq %rcx, %r12
movq %rdx, %r13
movq %rsi, %r15
movq %rdi, %rbx
movq %rsi, %rdi
movq %rdx, %rsi
callq 0x3120
movq %rax, %rdi
movq %r12, %rsi
callq 0x318a
leaq 0x2604(%rip), %rsi      # 0x5111
movq %rax, %rdi
callq 0x40f2
testb %al, %al
je 0x2b3c
movq %r15, %rdi
movq %r13, %rsi
callq 0x3120
movq %rax, %rdi
movq %r12, %rsi
callq 0x318a
movq %rbx, %rdi
movq %rax, %rsi
callq 0x2230
jmp 0x2ba3
leaq -0x88(%rbp), %rdi
movq %r13, %rsi
callq 0x2230
leaq -0x68(%rbp), %rdi
movq %r12, %rsi
callq 0x2230
leaq -0x48(%rbp), %rdi
movq %r14, %rsi
callq 0x2230
leaq -0x88(%rbp), %rsi
leaq -0x68(%rbp), %rdx
leaq -0x48(%rbp), %rcx
movq %r15, %rdi
callq 0x2be8
leaq -0x48(%rbp), %rdi
callq 0x20f0
leaq -0x68(%rbp), %rdi
callq 0x20f0
leaq -0x88(%rbp), %rdi
callq 0x20f0
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2220
movq %rbx, %rax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x48(%rbp), %rdi
callq 0x20f0
jmp 0x2bc6
movq %rax, %rbx
leaq -0x68(%rbp), %rdi
callq 0x20f0
jmp 0x2bd4
movq %rax, %rbx
leaq -0x88(%rbp), %rdi
callq 0x20f0
movq %rbx, %rdi
callq 0x22b0
// File: /workspace/github_cpp_makefile_star2_O2/devvoid[P]vini/./vini.hpp
// Function: Vini::save(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void save(std::string path) {
        std::ofstream file;

        file.open(path.c_str());

        for (vini_file::iterator it = ini_file.begin(); it != ini_file.end(); it++) {
            file << "[" << it->first << "]" << "\n";

            for (vini_content::iterator inner_it = it->second.begin(); inner_it != it->second.end(); inner_it++)
                file << inner_it->first << "=\"" << inner_it->second << "\"\n";
        }
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x218, %rsp            # imm = 0x218
movq %rsi, %rbx
movq %rdi, %r14
leaq -0x238(%rbp), %r15
movq %r15, %rdi
callq 0x22a0
movq (%rbx), %rsi
pushq $0x10
popq %rdx
movq %r15, %rdi
callq 0x2040
movq 0x18(%r14), %rbx
addq $0x8, %r14
leaq -0x238(%rbp), %r12
leaq 0x24ab(%rip), %r13      # 0x510c
leaq 0x24a7(%rip), %r15      # 0x510f
movq %r14, -0x30(%rbp)
cmpq %r14, %rbx
je 0x2d12
movq %r12, %rdi
leaq 0x2489(%rip), %rsi      # 0x5108
callq 0x21c0
leaq 0x20(%rbx), %rsi
movq %rax, %rdi
callq 0x21b0
movq %rax, %rdi
leaq 0x2470(%rip), %rsi      # 0x510a
callq 0x21c0
movq %rax, %rdi
leaq 0x2467(%rip), %rsi      # 0x5110
callq 0x21c0
movq %rbx, %rax
movq 0x58(%rbx), %rbx
movq %rax, -0x38(%rbp)
leaq 0x48(%rax), %r14
cmpq %r14, %rbx
je 0x2cfd
leaq 0x20(%rbx), %rsi
movq %r12, %rdi
callq 0x21b0
movq %rax, %rdi
movq %r13, %rsi
callq 0x21c0
leaq 0x40(%rbx), %rsi
movq %rax, %rdi
callq 0x21b0
movq %rax, %rdi
movq %r15, %rsi
callq 0x21c0
movq %rbx, %rdi
callq 0x2140
movq %rax, %rbx
jmp 0x2cbd
movq -0x38(%rbp), %rdi
callq 0x2140
movq %rax, %rbx
movq -0x30(%rbp), %r14
jmp 0x2c6c
leaq -0x238(%rbp), %rdi
callq 0x2250
addq $0x218, %rsp            # imm = 0x218
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x2d34
jmp 0x2d34
movq %rax, %rbx
leaq -0x238(%rbp), %rdi
callq 0x2250
movq %rbx, %rdi
callq 0x22b0
nop
// File: /workspace/github_cpp_makefile_star2_O2/devvoid[P]vini/./vini.hpp
// Function: Vini::split(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char)
std::vector<std::string> split(const std::string &s, char delim) {
        std::vector<std::string> elems;

        std::stringstream ss(s);
        std::string item;

        while(std::getline(ss, item, delim)) {
            elems.push_back(item);
        }

        return elems;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x1b0, %rsp            # imm = 0x1B0
movl %ecx, %r14d
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
andq $0x0, 0x10(%rdi)
leaq -0x1c8(%rbp), %rdi
pushq $0x18
popq %rax
movq %rdx, %rsi
movl %eax, %edx
callq 0x2280
leaq -0x30(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
movsbl %r14b, %r14d
leaq -0x1c8(%rbp), %r15
leaq -0x40(%rbp), %r12
movq %r15, %rdi
movq %r12, %rsi
movl %r14d, %edx
callq 0x22d0
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x30a7
movq %rbx, %rdi
movq %r12, %rsi
callq 0x3220
jmp 0x307e
leaq -0x40(%rbp), %rdi
callq 0x20f0
leaq -0x1c8(%rbp), %rdi
callq 0x2170
movq %rbx, %rax
addq $0x1b0, %rsp            # imm = 0x1B0
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
jmp 0x30ec
movq %rax, %r14
leaq -0x40(%rbp), %rdi
callq 0x20f0
leaq -0x1c8(%rbp), %rdi
callq 0x2170
movq %rbx, %rdi
callq 0x31f4
movq %r14, %rdi
callq 0x22b0
// File: /workspace/github_cpp_makefile_star2_O2/bluesky466[P]ResourcesArscDemo/main.cpp
// Function: readResTableHeader(_IO_FILE*)
void readResTableHeader(FILE* pFile) {
	uint16_t type;
	fread((void*)&type, sizeof(type), 1, pFile);
	if(type == RES_TABLE_TYPE) {
		struct ResTable_header header = {RES_TABLE_TYPE};
		fread((void*)(((char*)&header)+2), sizeof(struct ResTable_header)-2, 1, pFile);
		printf("type:%u, headSize:%u, size:%u, packageCount:%u\n",
				header.header.type,
				header.header.headerSize,
				header.header.size,
				header.packageCount);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
leaq -0x12(%rbp), %r14
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
movq %r14, %rdi
movq %rbx, %rcx
callq 0x2190
cmpw $0x2, (%r14)
jne 0x2726
leaq -0x1e(%rbp), %r14
andl $0x0, 0x6(%r14)
movq $0x2, -0x2(%r14)
pushq $0xa
popq %rsi
pushq $0x1
popq %rdx
movq %r14, %rdi
movq %rbx, %rcx
callq 0x2190
movzwl -0x2(%r14), %esi
movzwl (%r14), %edx
movl 0x2(%r14), %ecx
movl 0x6(%r14), %r8d
leaq 0x2981(%rip), %rdi      # 0x50a0
xorl %eax, %eax
callq 0x2030
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/bluesky466[P]ResourcesArscDemo/main.cpp
// Function: readResStringPoolHeader(_IO_FILE*)
struct ResStringPool_header readResStringPoolHeader(FILE* pFile) {
	struct ResStringPool_header header;
	uint16_t type;
	fread((void*)&header, sizeof(struct ResStringPool_header), 1, pFile);
	printf("type:%u, headSize:%u, size:%u, stringCount:%u, stringStart:%u, styleCount:%u, styleStart:%u\n",
				header.header.type,
				header.header.headerSize,
				header.header.size,
				header.stringCount,
				header.stringsStart,
				header.styleCount,
				header.stylesStart);
	return header;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rsi, %rcx
movq %rdi, %rbx
pushq $0x1c
popq %rsi
pushq $0x1
popq %rdx
callq 0x2190
movzwl (%rbx), %esi
movzwl 0x2(%rbx), %edx
movl 0x4(%rbx), %ecx
movl 0x8(%rbx), %r8d
movl 0x14(%rbx), %r9d
movl 0xc(%rbx), %r10d
movl 0x18(%rbx), %r11d
leaq 0x2969(%rip), %rdi      # 0x50d0
xorl %eax, %eax
pushq %r11
pushq %r10
callq 0x2030
popq %rcx
popq %rdx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/bluesky466[P]ResourcesArscDemo/main.cpp
// Function: readStringsFromStringPool(_IO_FILE*, ResStringPool_header)
unsigned char* readStringsFromStringPool(FILE* pFile,  struct ResStringPool_header header) {
	uint32_t size = header.header.size - sizeof(struct ResStringPool_header);
	unsigned char* pData = (unsigned char*)malloc(size);
	fread((void*)pData, size, 1, pFile);
	uint32_t* pOffsets = (uint32_t*)pData;

	//stringsStart指的是header的起始地址到字符串起始地址的距离
	//pData已经是header末尾的地址了，所以要减去header的大小
	char* pStringsStart = (char*)(pData + header.stringsStart - sizeof(struct ResStringPool_header));

	for(int i = 0 ; i < header.stringCount ; i++) {
		//前面两个字节是长度,要跳过
		char* str = pStringsStart + *(pOffsets + i) + 2;
		if(header.flags & ResStringPool_header::UTF8_FLAG) {
			printf("%s\n", str);
		} else {
			printUtf16String((char16_t*)str);
		}
	}

	return pData;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
movl 0x14(%rbp), %r15d
addl $-0x1c, %r15d
movq %r15, %rdi
callq 0x2150
movq %rax, %rbx
pushq $0x1
popq %rdx
movq %rax, %rdi
movq %r15, %rsi
movq %r14, %rcx
callq 0x2190
movl 0x24(%rbp), %eax
movl 0x18(%rbp), %r14d
movl 0x20(%rbp), %r15d
leaq (%rbx,%rax), %r12
addq $-0x1a, %r12
xorl %r13d, %r13d
cmpq %r13, %r14
je 0x27ed
movl (%rbx,%r13,4), %edi
addq %r12, %rdi
btl $0x8, %r15d
jb 0x27e3
callq 0x2a23
jmp 0x27e8
callq 0x21a0
incq %r13
jmp 0x27c9
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/bluesky466[P]ResourcesArscDemo/main.cpp
// Function: readResTablePackageHeader(_IO_FILE*, ResTable_package*)
int readResTablePackageHeader(FILE* pFile, struct ResTable_package* pHeader) {
	if(fread((void*)pHeader, sizeof(struct ResTable_package), 1, pFile) == 0) {
		return 0;
	}
	printf("type:%u, headSize:%u, size:%u, id:%x, packageName:",
				pHeader->header.type,
				pHeader->header.headerSize,
				pHeader->header.size,
				pHeader->id);
	printUtf16String((char16_t*)pHeader->name);
	return 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %rcx
pushq $0x1
popq %rdx
movl $0x120, %esi            # imm = 0x120
movq %rbx, %rdi
callq 0x2190
testq %rax, %rax
je 0x284d
movzwl (%rbx), %esi
movzwl 0x2(%rbx), %edx
movl 0x4(%rbx), %ecx
movl 0x8(%rbx), %r8d
leaq 0x28f8(%rip), %rdi      # 0x512d
xorl %eax, %eax
callq 0x2030
addq $0xc, %rbx
movq %rbx, %rdi
callq 0x2a23
pushq $0x1
popq %rax
jmp 0x284f
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/bluesky466[P]ResourcesArscDemo/main.cpp
// Function: printStringFromStringsPool(unsigned int*, char*, unsigned int, unsigned int)
void printStringFromStringsPool(uint32_t* pOffsets, char* pStringsStart, uint32_t stringIndex, uint32_t isUtf8) {
	//前面两个字节是长度,要跳过
	char* str = pStringsStart + *(pOffsets + stringIndex) + 2;
	if(isUtf8) {
		printf("%s\n", str);
	} else {
		printUtf16String((char16_t*)str);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl %edx, %eax
movl (%rdi,%rax,4), %eax
leaq (%rsi,%rax), %rdi
addq $0x2, %rdi
testl %ecx, %ecx
je 0x2871
popq %rbp
jmp 0x21a0
popq %rbp
jmp 0x2a23
// File: /workspace/github_cpp_makefile_star2_O2/bluesky466[P]ResourcesArscDemo/main.cpp
// Function: printStringOfComplex(unsigned int, bool)
void printStringOfComplex(uint32_t complex, bool isFraction) {
    const float MANTISSA_MULT =
        1.0f / (1<<Res_value::COMPLEX_MANTISSA_SHIFT);
    const float RADIX_MULTS[] = {
        1.0f*MANTISSA_MULT, 1.0f/(1<<7)*MANTISSA_MULT,
        1.0f/(1<<15)*MANTISSA_MULT, 1.0f/(1<<23)*MANTISSA_MULT
    };

    float value = (complex&(Res_value::COMPLEX_MANTISSA_MASK
                   <<Res_value::COMPLEX_MANTISSA_SHIFT))
            * RADIX_MULTS[(complex>>Res_value::COMPLEX_RADIX_SHIFT)
                            & Res_value::COMPLEX_RADIX_MASK];
	printf("%f",value);

    if (!isFraction) {
        switch ((complex>>Res_value::COMPLEX_UNIT_SHIFT)&Res_value::COMPLEX_UNIT_MASK) {
            case Res_value::COMPLEX_UNIT_PX: printf("px\n"); break;
            case Res_value::COMPLEX_UNIT_DIP: printf("dp\n"); break;
            case Res_value::COMPLEX_UNIT_SP: printf("sp\n"); break;
            case Res_value::COMPLEX_UNIT_PT: printf("pt\n"); break;
            case Res_value::COMPLEX_UNIT_IN: printf("in\n"); break;
            case Res_value::COMPLEX_UNIT_MM: printf("mm\n"); break;
            default: printf("(unknown unit)\n"); break;
        }
    } else {
        switch ((complex>>Res_value::COMPLEX_UNIT_SHIFT)&Res_value::COMPLEX_UNIT_MASK) {
            case Res_value::COMPLEX_UNIT_FRACTION: printf("%%\n"); break;
            case Res_value::COMPLEX_UNIT_FRACTION_PARENT: printf("%%p\n"); break;
            default: printf("(unknown unit)\n"); break;
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %edi, %ebx
movl %edi, %eax
andl $0xffffff00, %eax       # imm = 0xFFFFFF00
cvtsi2ss %rax, %xmm0
movl %esi, %r14d
movl %edi, %eax
shrl $0x2, %eax
andl $0xc, %eax
leaq 0x28ac(%rip), %rcx      # 0x5380
mulss (%rax,%rcx), %xmm0
cvtss2sd %xmm0, %xmm0
leaq 0x2689(%rip), %rdi      # 0x516d
movb $0x1, %al
callq 0x2030
andl $0xf, %ebx
testl %r14d, %r14d
je 0x2b05
cmpl $0x1, %ebx
je 0x2b2e
testl %ebx, %ebx
jne 0x2b25
leaq 0x266d(%rip), %rdi      # 0x5170
jmp 0x2b35
cmpl $0x5, %ebx
ja 0x2b25
movl %ebx, %eax
leaq 0x250d(%rip), %rcx      # 0x5020
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq 0x2844(%rip), %rdi      # 0x5367
jmp 0x2b6b
leaq 0x283e(%rip), %rdi      # 0x536a
jmp 0x2b6b
leaq 0x263f(%rip), %rdi      # 0x5174
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
jmp 0x2030
leaq 0x2814(%rip), %rdi      # 0x535b
jmp 0x2b6b
leaq 0x2811(%rip), %rdi      # 0x5361
jmp 0x2b6b
leaq 0x2805(%rip), %rdi      # 0x535e
jmp 0x2b6b
leaq 0x2802(%rip), %rdi      # 0x5364
jmp 0x2b6b
leaq 0x27ed(%rip), %rdi      # 0x5358
popq %rbx
popq %r14
popq %rbp
jmp 0x21a0
// File: /workspace/github_cpp_makefile_star2_O2/iZhangHui[P]CppPrimer/CH13_CopyControl/examples/StrFolder.cc
// Function: swap(Message&, Message&)
void swap(Message &lhs, Message &rhs)
{
	using std::swap;  // not strictly needed in this case, but good habit

	// remove pointers to each Message from their (original) respective Folders
	for (auto f : lhs.folders)
		f->remMsg(&lhs);
	for (auto f : rhs.folders)
		f->remMsg(&rhs);

	// swap the contents and Folder pointer sets
	swap(lhs.folders, rhs.folders);   // uses swap(set&, set&)
	swap(lhs.contents, rhs.contents); // swap(String&, String&)

	// add pointers to each Message to their (new) respective Folders
	for (auto f : lhs.folders)
		f->addMsg(&lhs);
	for (auto f : rhs.folders)
		f->addMsg(&rhs);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq 0x28(%rdi), %r15
leaq 0x18(%rdi), %r13
cmpq %r13, %r15
je 0x1376
movq 0x20(%r15), %rdi
movq %r14, %rsi
callq 0x1a42
movq %r15, %rdi
callq 0x1120
movq %rax, %r15
jmp 0x1358
leaq 0x10(%r14), %rax
movq %rax, -0x30(%rbp)
movq 0x28(%rbx), %r12
movq %rbx, %r15
addq $0x18, %rbx
cmpq %rbx, %r12
je 0x13a8
movq 0x20(%r12), %rdi
movq %r15, %rsi
callq 0x1a42
movq %r12, %rdi
callq 0x1120
movq %rax, %r12
jmp 0x1389
movq %r15, %r12
leaq 0x10(%r15), %rsi
movq -0x30(%rbp), %rdi
callq 0x2c90
movq 0x8(%r14), %rax
movq 0x8(%r15), %rcx
movq %rcx, 0x8(%r14)
movq %rax, 0x8(%r15)
movq (%r14), %rax
movq (%r15), %rcx
movq %rcx, (%r14)
movq %rax, (%r15)
movq 0x28(%r14), %r15
cmpq %r13, %r15
je 0x13f6
movq 0x20(%r15), %rdi
movq %r14, %rsi
callq 0x1a60
movq %r15, %rdi
callq 0x1120
movq %rax, %r15
jmp 0x13d8
movq 0x28(%r12), %r14
cmpq %rbx, %r14
je 0x1419
movq 0x20(%r14), %rdi
movq %r12, %rsi
callq 0x1a60
movq %r14, %rdi
callq 0x1120
movq %rax, %r14
jmp 0x13fb
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/iZhangHui[P]CppPrimer/CH13_CopyControl/examples/StrFolder.cc
// Function: Folder::operator=(Folder&&)
Folder& Folder::operator=(Folder&& f)
{
	if (this != &f) {        // direct check for self-assignment
		remove_from_Msgs();  // remove this Folder from the current msgs
		move_Messages(&f);   // make each Message point to this Folder
	}
	return *this;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
cmpq %rsi, %rdi
je 0x14f3
movq %rsi, %r14
movq %rbx, %rdi
callq 0x14fc
movq %rbx, %rdi
movq %r14, %rsi
callq 0x146a
movq %rbx, %rax
popq %rbx
popq %r14
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/iZhangHui[P]CppPrimer/CH13_CopyControl/examples/String.cc
// Function: String::operator=(String const&)
String& String::operator=(const String& rhs)
{
	// copying the right-hand operand before deleting the left handles self-assignment
	auto newp = a.allocate(rhs.sz); // copy the underlying string from rhs
	uninitialized_copy(rhs.p, rhs.p + rhs.sz, newp);

	if (p)
		a.deallocate(p, sz); // free the memory used by the left-hand operand
	p = newp;    // p now points to the newly allocated string
	sz = rhs.sz; // update the size

	return *this;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq (%rsi), %rsi
leaq 0x511a(%rip), %rdi      # 0x90ec
xorl %edx, %edx
callq 0x203c
movq %rax, %r15
movq (%r14), %rdx
testq %rdx, %rdx
je 0x3ff0
movq 0x8(%r14), %rsi
movq %r15, %rdi
callq 0x1160
movq 0x8(%rbx), %rdi
testq %rdi, %rdi
je 0x4001
movq (%rbx), %rsi
callq 0x1100
movq %r15, 0x8(%rbx)
movq (%r14), %rax
movq %rax, (%rbx)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop