LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: s0sasaki[P]ExecutableBlockchain/vm.cpp
// Function: VM::funcOpCall()
void VM::funcOpCall() { 
    return_stack[++rsp] = ib; 
    return_stack[++rsp] = ip + 2; 
    ib = mem[ip++];  
    ip = mem[ip];  
    load();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
movl (%rdi), %ecx
movl 0x8(%rdi), %eax
addl $0x1, %eax
movl %eax, 0x8(%rdi)
cltq
movl %ecx, 0x3020(%rdi,%rax,4)
movl 0x4(%rdi), %ecx
addl $0x2, %ecx
movl 0x8(%rdi), %eax
addl $0x1, %eax
movl %eax, 0x8(%rdi)
cltq
movl %ecx, 0x3020(%rdi,%rax,4)
movl 0x4(%rdi), %eax
movl %eax, %ecx
addl $0x1, %ecx
movl %ecx, 0x4(%rdi)
cltq
movl 0x1020(%rdi,%rax,4), %eax
movl %eax, (%rdi)
movslq 0x4(%rdi), %rax
movl 0x1020(%rdi,%rax,4), %eax
movl %eax, 0x4(%rdi)
callq 0xb5d0
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: s0sasaki[P]ExecutableBlockchain/vm.cpp
// Function: VM::exec(int const*, Blockchain const&)
void VM::exec(const int32_t *bin_data, const Blockchain &blockchain) {
    refresh(bin_data, blockchain);
    while(is_halt == false) {
#ifdef DEBUG
        displayState();
#endif
        (this->*func_table[mem[ip++]])();
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x20(%rbp)
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq 0xae30
movq -0x20(%rbp), %rax
movb 0x10(%rax), %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
jne 0xae27
movq -0x20(%rbp), %rcx
movslq 0x4(%rcx), %rax
movl %eax, %edx
incl %edx
movl %edx, 0x4(%rcx)
movslq 0x1020(%rcx,%rax,4), %rdx
shlq $0x4, %rdx
movq 0x5020(%rcx,%rdx), %rax
movq %rax, -0x30(%rbp)
movq 0x5028(%rcx,%rdx), %rdx
addq %rdx, %rcx
movq %rcx, -0x28(%rbp)
andq $0x1, %rax
cmpq $0x0, %rax
je 0xae13
movq -0x30(%rbp), %rcx
movq -0x28(%rbp), %rax
movq (%rax), %rax
subq $0x1, %rcx
movq (%rax,%rcx), %rax
movq %rax, -0x38(%rbp)
jmp 0xae1b
movq -0x30(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x28(%rbp), %rdi
movq -0x38(%rbp), %rax
callq *%rax
jmp 0xada9
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
// File: s0sasaki[P]ExecutableBlockchain/vm.cpp
// Function: VM::refresh(int const*, Blockchain const&)
void VM::refresh(const int32_t *latest_data, const Blockchain &blockchain){
    ib      = blockchain.chain.size();
    ip      = 0;
    rsp     = 0;
    psp     = 0;
    is_halt = false;
    pblockchain = &blockchain;
    std::memcpy(mem,      latest_data, sizeof mem);
    std::memcpy(bin_data, latest_data, sizeof mem);
    std::memset(return_stack, 0, sizeof return_stack);
    std::memset(data_stack, 0, sizeof data_stack);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rdi
callq 0x2aa0
movq -0x20(%rbp), %rdi
movl %eax, (%rdi)
movl $0x0, 0x4(%rdi)
movl $0x0, 0x8(%rdi)
movl $0x0, 0xc(%rdi)
movb $0x0, 0x10(%rdi)
movq -0x18(%rbp), %rax
movq %rax, 0x18(%rdi)
addq $0x1020, %rdi           # imm = 0x1020
movq -0x10(%rbp), %rsi
movl $0x1000, %edx           # imm = 0x1000
callq 0x21a0
movq -0x20(%rbp), %rdi
addq $0x20, %rdi
movq -0x10(%rbp), %rsi
movl $0x1000, %edx           # imm = 0x1000
callq 0x21a0
movq -0x20(%rbp), %rdi
addq $0x3020, %rdi           # imm = 0x3020
xorl %esi, %esi
movl $0x1000, %edx           # imm = 0x1000
callq 0x2110
movq -0x20(%rbp), %rdi
addq $0x4020, %rdi           # imm = 0x4020
xorl %esi, %esi
movl $0x1000, %edx           # imm = 0x1000
callq 0x2110
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: s0sasaki[P]ExecutableBlockchain/vm.cpp
// Function: VM::load()
inline void VM::load() {
    if (ib < pblockchain->chain.size())
        std::memcpy(mem, pblockchain->chain[ib].data, sizeof mem);
    else
        std::memcpy(mem, bin_data, sizeof mem);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movslq (%rax), %rcx
movq %rcx, -0x10(%rbp)
movq 0x18(%rax), %rdi
callq 0x2aa0
movq %rax, %rcx
movq -0x10(%rbp), %rax
cmpq %rcx, %rax
jae 0xb635
movq -0x18(%rbp), %rax
movq %rax, %rcx
addq $0x1020, %rcx           # imm = 0x1020
movq %rcx, -0x20(%rbp)
movq 0x18(%rax), %rdi
movslq (%rax), %rsi
callq 0x8f50
movq -0x20(%rbp), %rdi
movq %rax, %rsi
addq $0x40, %rsi
movl $0x1000, %edx           # imm = 0x1000
callq 0x21a0
jmp 0xb651
movq -0x18(%rbp), %rsi
movq %rsi, %rdi
addq $0x1020, %rdi           # imm = 0x1020
addq $0x20, %rsi
movl $0x1000, %edx           # imm = 0x1000
callq 0x21a0
addq $0x20, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: big-data-lab-team[P]OrpailleCC/main.cpp
// Function: main
int main(){
	CoarseMondrianForest<double, funct, KappaMetrics<LABEL_COUNT>, FEATURE_COUNT, LABEL_COUNT, 6000> classifier(0.6, 0.0001, 0.0, 10);
	//CoarseMondrianForest<double, funct, ErrorMetrics<FEATURE_COUNT, LABEL_COUNT>, FEATURE_COUNT, LABEL_COUNT, 6000> classifier(0.6, 0.0001, 0.0, 10);
	classifier.train(dt[0], labels[0]);
	classifier.train(dt[2], labels[2]);

	double scores[2];
	int result = classifier.predict(dt[0], scores);
#ifdef DEBUG
	cout << "Prediction: " << result << endl;
	cout << "True Label: " << labels[0] << endl;
#endif
	//result = classifier.predict(dt[2], scores);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x18b0, %rsp           # imm = 0x18B0
leaq -0x1848(%rbp), %rdi
movsd 0x9dfe(%rip), %xmm0     # 0xb008
movsd 0x9dfe(%rip), %xmm1     # 0xb010
xorps %xmm2, %xmm2
movl $0xa, %esi
xorl %r9d, %r9d
movl $0x1, %ecx
movl $0xffffffff, %r8d       # imm = 0xFFFFFFFF
movsd 0x9de8(%rip), %xmm6     # 0xb018
movl %r9d, %edx
movl $0x0, (%rsp)
movl $0x0, 0x8(%rsp)
movl $0x0, 0x10(%rsp)
movaps %xmm6, %xmm3
movl $0x1, 0x18(%rsp)
movl $0x1, 0x20(%rsp)
movaps %xmm6, %xmm4
movaps %xmm6, %xmm5
movl $0x0, 0x28(%rsp)
movl $0x0, 0x30(%rsp)
movl $0x0, 0x38(%rsp)
callq 0x12f0
movl 0xbfaa(%rip), %edx      # 0xd230
leaq -0x1848(%rbp), %rdi
leaq 0xbddc(%rip), %rsi      # 0xd070
callq 0x16a0
movl 0xbf99(%rip), %edx      # 0xd238
leaq -0x1848(%rbp), %rdi
leaq 0xbdc3(%rip), %rsi      # 0xd070
addq $0x40, %rsi
callq 0x16a0
leaq -0x1860(%rbp), %rdx
leaq -0x1848(%rbp), %rdi
leaq 0xbda5(%rip), %rsi      # 0xd070
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
callq 0x1930
movl %eax, -0x1864(%rbp)
xorl %eax, %eax
addq $0x18b0, %rsp           # imm = 0x18B0
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: CoarseMondrianForest<double, funct, KappaMetrics<2, false>, 4, 2, 6000>::predict(double const*, double*, int)
int predict(feature_type const* features, double* scores = nullptr, int tree_to_use = -1){
	if(tree_to_use < 0)
		tree_to_use = tree_count;
	//Update internal count
	//NOTE uncomment for bound and trim, just to be safer
	#ifndef UNBOUND_OPTIMIZE
	if(extend_type != EXTEND_GHOST)
		update_posterior_count();
	#endif
	//The posterior mean of the forest will be the average posterior means over all trees
	//We start by computing the sum
	double tree_used = 0;
	double sum_posterior_mean[label_count] = {0};
	for(int i = 0; i < tree_to_use; ++i){
		double posterior_mean[label_count];
		//Get the  posterior means of the leaf of the data point in tree *i*
		predict_tree(features, i, posterior_mean);
		tree_used += 1;
		//Update the sum of posterior means
		for(int k = 0; k < label_count; ++k)
			sum_posterior_mean[k] += posterior_mean[k];
	}
	//Then we divide by the number trees.
	for(int k = 0; k < label_count; ++k)
		sum_posterior_mean[k] /= tree_used;

	//Finally, we look for the best label
	return Utils::index_max(sum_posterior_mean, label_count);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x70(%rbp)
cmpl $0x0, -0x1c(%rbp)
jge 0x1962
movq -0x70(%rbp), %rax
movl 0x17dc(%rax), %eax
movl %eax, -0x1c(%rbp)
movq -0x70(%rbp), %rax
cmpl $0x2, 0x3c(%rax)
je 0x1975
movq -0x70(%rbp), %rdi
callq 0x2260
xorps %xmm0, %xmm0
movsd %xmm0, -0x28(%rbp)
leaq -0x40(%rbp), %rdi
xorl %esi, %esi
movl $0x10, %edx
callq 0x1030
movl $0x0, -0x44(%rbp)
movl -0x44(%rbp), %eax
cmpl -0x1c(%rbp), %eax
jge 0x1a07
movq -0x70(%rbp), %rdi
movq -0x10(%rbp), %rsi
movl -0x44(%rbp), %edx
leaq -0x60(%rbp), %rcx
movl $0xffffffff, %r8d       # imm = 0xFFFFFFFF
callq 0x22e0
movsd 0x965a(%rip), %xmm0     # 0xb018
addsd -0x28(%rbp), %xmm0
movsd %xmm0, -0x28(%rbp)
movl $0x0, -0x64(%rbp)
cmpl $0x2, -0x64(%rbp)
jge 0x19fa
movslq -0x64(%rbp), %rax
movsd -0x60(%rbp,%rax,8), %xmm0
movslq -0x64(%rbp), %rax
addsd -0x40(%rbp,%rax,8), %xmm0
movsd %xmm0, -0x40(%rbp,%rax,8)
movl -0x64(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x64(%rbp)
jmp 0x19cf
jmp 0x19fc
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
jmp 0x1994
movl $0x0, -0x68(%rbp)
cmpl $0x2, -0x68(%rbp)
jge 0x1a38
movsd -0x28(%rbp), %xmm1
movslq -0x68(%rbp), %rax
movsd -0x40(%rbp,%rax,8), %xmm0
divsd %xmm1, %xmm0
movsd %xmm0, -0x40(%rbp,%rax,8)
movl -0x68(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x68(%rbp)
jmp 0x1a0e
leaq -0x40(%rbp), %rdi
movl $0x2, %esi
callq 0x2870
addq $0x70, %rsp
popq %rbp
retq
nopl (%rax)
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: CoarseMondrianForest<double, funct, KappaMetrics<2, false>, 4, 2, 6000>::TreeBase::reset(int)
void reset(int const node_limit=1){
		root = EMPTY_ROOT;
		node_count_limit = node_limit;
		statistics.reset();
		sum_contribution = 0;
		count_contribution = 0;
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x18(%rbp)
movl $0xffffffff, 0x8(%rdi)  # imm = 0xFFFFFFFF
movl -0xc(%rbp), %eax
movl %eax, (%rdi)
addq $0x20, %rdi
callq 0x1be0
movq -0x18(%rbp), %rax
xorps %xmm0, %xmm0
movsd %xmm0, 0x10(%rax)
xorps %xmm0, %xmm0
movsd %xmm0, 0x18(%rax)
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: MondrianNode<4, 2>::reset()
void reset(void){
		for(int i = 0; i < label_count; ++i)
			counters[i] = 0;
		for(int i = 0; i < feature_count; ++i)
			bound_lower[i] = bound_upper[i] = 0;
		child_left = child_right = EMPTY_NODE;
		split_dimension = EMPTY_NODE;
		split_value = 0;
		tau = EMPTY_NODE;
		parent = EMPTY_NODE;
		forced_extend = 0;
		fading_score = 0;
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movl $0x0, -0xc(%rbp)
cmpl $0x2, -0xc(%rbp)
jge 0x1b58
movq -0x18(%rbp), %rax
movslq -0xc(%rbp), %rcx
movl $0x0, 0x68(%rax,%rcx,4)
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x1b37
movl $0x0, -0x10(%rbp)
cmpl $0x4, -0x10(%rbp)
jge 0x1b8e
movq -0x18(%rbp), %rax
movslq -0x10(%rbp), %rcx
xorps %xmm0, %xmm0
movsd %xmm0, 0x30(%rax,%rcx,8)
movslq -0x10(%rbp), %rcx
xorps %xmm0, %xmm0
movsd %xmm0, 0x10(%rax,%rcx,8)
movl -0x10(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x10(%rbp)
jmp 0x1b5f
movq -0x18(%rbp), %rax
movl $0xffffffff, 0x54(%rax) # imm = 0xFFFFFFFF
movl $0xffffffff, 0x50(%rax) # imm = 0xFFFFFFFF
movl $0xffffffff, (%rax)     # imm = 0xFFFFFFFF
xorps %xmm0, %xmm0
movsd %xmm0, 0x8(%rax)
movsd 0x9472(%rip), %xmm0     # 0xb028
movsd %xmm0, 0x60(%rax)
movl $0xffffffff, 0x58(%rax) # imm = 0xFFFFFFFF
movl $0x0, 0x70(%rax)
xorps %xmm0, %xmm0
movsd %xmm0, 0x78(%rax)
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)
// File: big-data-lab-team[P]OrpailleCC/./src/metrics.hpp
// Function: KappaMetrics<2, false>::reset()
void reset(){
		for(int i = 0; i < label_count; ++i)
			for(int j = 0; j < label_count; ++j)
				confusion[i][j] = 0;
		total = 0;
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movl $0x0, -0xc(%rbp)
cmpl $0x2, -0xc(%rbp)
jge 0x1c3c
movl $0x0, -0x10(%rbp)
cmpl $0x2, -0x10(%rbp)
jge 0x1c2f
movq -0x18(%rbp), %rax
movslq -0xc(%rbp), %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movslq -0x10(%rbp), %rcx
movl $0x0, (%rax,%rcx,4)
movl -0x10(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x10(%rbp)
jmp 0x1c04
jmp 0x1c31
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x1bf7
movq -0x18(%rbp), %rax
movl $0x0, 0x10(%rax)
popq %rbp
retq
nopl (%rax)
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: CoarseMondrianForest<double, funct, KappaMetrics<2, false>, 4, 2, 6000>::tree_trim()
void tree_trim(){
	if(trim_type == TRIM_NONE)
		return;
	for(int i = 0; i < tree_count; ++i){
		int id = tree_trim(i);
		if(tree_bases()[i].root != id && id >= 0 && id < node_count) //Can't cut the root
			cut_block(id, i);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
cmpl $0x0, 0x40(%rax)
jne 0x1f2c
jmp 0x1f9e
movl $0x0, -0xc(%rbp)
movq -0x18(%rbp), %rcx
movl -0xc(%rbp), %eax
cmpl 0x17dc(%rcx), %eax
jge 0x1f9e
movq -0x18(%rbp), %rdi
movl -0xc(%rbp), %esi
callq 0x2f70
movq -0x18(%rbp), %rdi
movl %eax, -0x10(%rbp)
callq 0x1a50
movslq -0xc(%rbp), %rcx
imulq $0x38, %rcx, %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
cmpl -0x10(%rbp), %eax
je 0x1f91
cmpl $0x0, -0x10(%rbp)
jl 0x1f91
movq -0x18(%rbp), %rcx
movl -0x10(%rbp), %eax
cmpl 0x17d4(%rcx), %eax
jge 0x1f91
movq -0x18(%rbp), %rdi
movl -0x10(%rbp), %esi
movl -0xc(%rbp), %edx
callq 0x3430
jmp 0x1f93
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x1f33
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nop
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: CoarseMondrianForest<double, funct, KappaMetrics<2, false>, 4, 2, 6000>::update_posterior_count()
void update_posterior_count(void){
	//For each tree, run the recursive *update_posterior_count* on the root
	TreeBase* bases = tree_bases();
	for(int i = 0; i < tree_count; ++i)
		if(!bases[i].is_empty())
			update_posterior_count(bases[i].root);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x20(%rbp)
callq 0x1a50
movq %rax, -0x10(%rbp)
movl $0x0, -0x14(%rbp)
movq -0x20(%rbp), %rcx
movl -0x14(%rbp), %eax
cmpl 0x17dc(%rcx), %eax
jge 0x22d3
movq -0x10(%rbp), %rdi
movslq -0x14(%rbp), %rax
imulq $0x38, %rax, %rax
addq %rax, %rdi
callq 0x28d0
testb $0x1, %al
jne 0x22c6
movq -0x20(%rbp), %rdi
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
imulq $0x38, %rcx, %rcx
addq %rcx, %rax
movl 0x8(%rax), %esi
callq 0x28f0
jmp 0x22c8
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x2284
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: big-data-lab-team[P]OrpailleCC/./src/utils.hpp
// Function: int Utils::index_max<double>(double*, int)
static int index_max(T* array, int const size) {
		int best = 0;
		for(int i = 1; i < size; ++i)
			if(array[i] > array[best])
				best = i;
		return best;
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl $0x0, -0x10(%rbp)
movl $0x1, -0x14(%rbp)
movl -0x14(%rbp), %eax
cmpl -0xc(%rbp), %eax
jge 0x28c0
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm0
movq -0x8(%rbp), %rax
movslq -0x10(%rbp), %rcx
ucomisd (%rax,%rcx,8), %xmm0
jbe 0x28b3
movl -0x14(%rbp), %eax
movl %eax, -0x10(%rbp)
jmp 0x28b5
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x2889
movl -0x10(%rbp), %eax
popq %rbp
retq
nopw %cs:(%rax,%rax)
nop
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: CoarseMondrianForest<double, funct, KappaMetrics<2, false>, 4, 2, 6000>::update_posterior_count(int)
void update_posterior_count(int const node_id){
	Node& node = nodes()[node_id];
	if(node.is_leaf()){
		//A leaf should already has its count right
		return;
	}
	else{ //This is an internal node
		//Compute the posterior count for the two children
		update_posterior_count(node.child_left);
		update_posterior_count(node.child_right);
	}
	//Update each count
	for(int i = 0; i < label_count; ++i){
		int const c_left = Utils::min(1, nodes()[node.child_left].counters[i]);
		int const c_right = Utils::min(1, nodes()[node.child_right].counters[i]);
		node.counters[i] = c_left + c_right;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x30(%rbp)
callq 0x1b00
movslq -0xc(%rbp), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rdi
callq 0x29e0
testb $0x1, %al
jne 0x292a
jmp 0x292f
jmp 0x29d3
movq -0x30(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x50(%rax), %esi
callq 0x28f0
movq -0x30(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x54(%rax), %esi
callq 0x28f0
movl $0x0, -0x1c(%rbp)
cmpl $0x2, -0x1c(%rbp)
jge 0x29d3
movq -0x30(%rbp), %rdi
callq 0x1b00
movq -0x18(%rbp), %rcx
movslq 0x50(%rcx), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movslq -0x1c(%rbp), %rcx
movl 0x68(%rax,%rcx,4), %esi
movl $0x1, %edi
callq 0x2a00
movq -0x30(%rbp), %rdi
movl %eax, -0x20(%rbp)
callq 0x1b00
movq -0x18(%rbp), %rcx
movslq 0x54(%rcx), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movslq -0x1c(%rbp), %rcx
movl 0x68(%rax,%rcx,4), %esi
movl $0x1, %edi
callq 0x2a00
movl %eax, -0x24(%rbp)
movl -0x20(%rbp), %edx
addl -0x24(%rbp), %edx
movq -0x18(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movl %edx, 0x68(%rax,%rcx,4)
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x2956
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: CoarseMondrianForest<double, funct, KappaMetrics<2, false>, 4, 2, 6000>::cut_block(int, int)
void cut_block(int const node_id, int const tree_id){
	Node& node = nodes()[node_id];
	Node& parent = nodes()[node.parent];
	int sibling_id;
	if(parent.child_right == node_id)
		sibling_id = parent.child_left;
	else
		sibling_id = parent.child_right;
	Node& sibling = nodes()[sibling_id];

	if(parent.parent == -1){ //Place the other sibling as root (behead)
		parent.reset();
		node_available += 1;
		node_reset(node_id);
		//Cut off node and everything below
		tree_bases()[tree_id].root = sibling_id;
		sibling.parent = Node::EMPTY_NODE;
		return;
	}
	Node& grandparent = nodes()[parent.parent];
	int rem_count_id = parent.parent;
	if(grandparent.child_right == node.parent)
		grandparent.child_right = sibling_id;
	else
		grandparent.child_left = sibling_id;
	sibling.parent = parent.parent;
	node_available += 1;
	parent.reset();
	//TODO remove the counters?
	node_reset(node_id);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x48(%rbp)
callq 0x1b00
movq -0x48(%rbp), %rdi
movslq -0xc(%rbp), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movq %rax, -0x18(%rbp)
callq 0x1b00
movq -0x18(%rbp), %rcx
movslq 0x58(%rcx), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movl 0x54(%rax), %eax
cmpl -0xc(%rbp), %eax
jne 0x3492
movq -0x20(%rbp), %rax
movl 0x50(%rax), %eax
movl %eax, -0x24(%rbp)
jmp 0x349c
movq -0x20(%rbp), %rax
movl 0x54(%rax), %eax
movl %eax, -0x24(%rbp)
movq -0x48(%rbp), %rdi
callq 0x1b00
movslq -0x24(%rbp), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movq %rax, -0x30(%rbp)
movq -0x20(%rbp), %rax
cmpl $-0x1, 0x58(%rax)
jne 0x3512
movq -0x20(%rbp), %rdi
callq 0x1b20
movq -0x48(%rbp), %rdi
movl 0x17d8(%rdi), %eax
addl $0x1, %eax
movl %eax, 0x17d8(%rdi)
movl -0xc(%rbp), %esi
callq 0x35b0
movq -0x48(%rbp), %rdi
movl -0x24(%rbp), %eax
movl %eax, -0x4c(%rbp)
callq 0x1a50
movl -0x4c(%rbp), %ecx
movslq -0x10(%rbp), %rdx
imulq $0x38, %rdx, %rdx
addq %rdx, %rax
movl %ecx, 0x8(%rax)
movq -0x30(%rbp), %rax
movl $0xffffffff, 0x58(%rax) # imm = 0xFFFFFFFF
jmp 0x3594
movq -0x48(%rbp), %rdi
callq 0x1b00
movq -0x20(%rbp), %rcx
movslq 0x58(%rcx), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movq %rax, -0x38(%rbp)
movq -0x20(%rbp), %rax
movl 0x58(%rax), %eax
movl %eax, -0x3c(%rbp)
movq -0x38(%rbp), %rax
movl 0x54(%rax), %eax
movq -0x18(%rbp), %rcx
cmpl 0x58(%rcx), %eax
jne 0x3554
movl -0x24(%rbp), %ecx
movq -0x38(%rbp), %rax
movl %ecx, 0x54(%rax)
jmp 0x355e
movl -0x24(%rbp), %ecx
movq -0x38(%rbp), %rax
movl %ecx, 0x50(%rax)
movq -0x48(%rbp), %rax
movq -0x20(%rbp), %rcx
movl 0x58(%rcx), %edx
movq -0x30(%rbp), %rcx
movl %edx, 0x58(%rcx)
movl 0x17d8(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x17d8(%rax)
movq -0x20(%rbp), %rdi
callq 0x1b20
movq -0x48(%rbp), %rdi
movl -0xc(%rbp), %esi
callq 0x35b0
addq $0x50, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: CoarseMondrianForest<double, funct, KappaMetrics<2, false>, 4, 2, 6000>::available_node() const
int available_node(void) const{
	if(node_available == 0)
		return -1;
	static int last_returned_node = 0;
	for(int i = 0; i < node_count; ++i){
		int const node_id = (i + last_returned_node) % node_count;
		if(nodes()[node_id].available()){
			last_returned_node = node_id;
			return node_id;
		}
	}
	return -1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
cmpl $0x0, 0x17d8(%rax)
jne 0x3886
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x38f6
movl $0x0, -0x14(%rbp)
movq -0x20(%rbp), %rcx
movl -0x14(%rbp), %eax
cmpl 0x17d4(%rcx), %eax
jge 0x38ef
movq -0x20(%rbp), %rdi
movl -0x14(%rbp), %eax
addl 0x99cb(%rip), %eax      # 0xd274
cltd
idivl 0x17d4(%rdi)
movl %edx, -0x18(%rbp)
callq 0x2a60
movq %rax, %rdi
movslq -0x18(%rbp), %rax
shlq $0x7, %rax
addq %rax, %rdi
callq 0x70c0
testb $0x1, %al
jne 0x38d1
jmp 0x38e2
movl -0x18(%rbp), %eax
movl %eax, 0x999a(%rip)      # 0xd274
movl -0x18(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x38f6
jmp 0x38e4
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x388d
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nop
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: CoarseMondrianForest<double, funct, KappaMetrics<2, false>, 4, 2, 6000>::sample_block(int, double const*, int)
void sample_block(int const node_id, feature_type const* features, int const label){
	Node& node = nodes()[node_id];
	//Set the box of the node node_id
	for(int i = 0; i < feature_count; ++i){
		node.bound_lower[i] = features[i];
		node.bound_upper[i] = features[i];
	}
	//Update the counter for labels
	node.counters[label] += 1;
	//NOTE we don't need to check for lifetime because we only have one element
	//see the original source code (https://github.com/balajiln/mondrianforest)
	node.tau = lifetime;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x38(%rbp)
callq 0x1b00
movslq -0xc(%rbp), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movl $0x0, -0x2c(%rbp)
cmpl $0x4, -0x2c(%rbp)
jge 0x3980
movq -0x18(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm0
movq -0x28(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movsd %xmm0, 0x10(%rax,%rcx,8)
movq -0x18(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm0
movq -0x28(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movsd %xmm0, 0x30(%rax,%rcx,8)
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x3939
movq -0x38(%rbp), %rax
movq -0x28(%rbp), %rcx
movslq -0x1c(%rbp), %rdx
movl 0x68(%rcx,%rdx,4), %esi
addl $0x1, %esi
movl %esi, 0x68(%rcx,%rdx,4)
movsd 0x17e8(%rax), %xmm0
movq -0x28(%rbp), %rax
movsd %xmm0, 0x60(%rax)
addq $0x40, %rsp
popq %rbp
retq
nop
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: CoarseMondrianForest<double, funct, KappaMetrics<2, false>, 4, 2, 6000>::count_fe_down(int, double const*) const
int count_fe_down(int const start_id, feature_type const* features) const{
	int node_id = start_id;
	Node const* cnodes = nodes();
	int count = 0;

	//Loop to find the leaf
	while(!cnodes[node_id].is_leaf()){
		Node const&  node = cnodes[node_id];
		count += node.forced_extend;
		//Choose a direction
		if(features[node.split_dimension] > node.split_value)
			node_id = node.child_right;
		else
			node_id = node.child_left;
	}
	count += cnodes[node_id].forced_extend;
	return count;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movl -0xc(%rbp), %eax
movl %eax, -0x1c(%rbp)
callq 0x2a60
movq %rax, -0x28(%rbp)
movl $0x0, -0x2c(%rbp)
movq -0x28(%rbp), %rdi
movslq -0x1c(%rbp), %rax
shlq $0x7, %rax
addq %rax, %rdi
callq 0x29e0
xorb $-0x1, %al
testb $0x1, %al
jne 0x3a29
jmp 0x3a7c
movq -0x28(%rbp), %rax
movslq -0x1c(%rbp), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
movl 0x70(%rax), %eax
addl -0x2c(%rbp), %eax
movl %eax, -0x2c(%rbp)
movq -0x18(%rbp), %rax
movq -0x38(%rbp), %rcx
movslq (%rcx), %rcx
movsd (%rax,%rcx,8), %xmm0
movq -0x38(%rbp), %rax
ucomisd 0x8(%rax), %xmm0
jbe 0x3a70
movq -0x38(%rbp), %rax
movl 0x54(%rax), %eax
movl %eax, -0x1c(%rbp)
jmp 0x3a7a
movq -0x38(%rbp), %rax
movl 0x50(%rax), %eax
movl %eax, -0x1c(%rbp)
jmp 0x3a0d
movq -0x28(%rbp), %rax
movslq -0x1c(%rbp), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movl 0x70(%rax), %eax
addl -0x2c(%rbp), %eax
movl %eax, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: int CoarseMondrianForest<double, funct, KappaMetrics<2, false>, 4, 2, 6000>::unravel<false>(int)
int unravel(int const node_id){

	if(node_id >= node_count){
 		#ifdef DEBUG
		cout << "WARNING: " << node_id << " is higher than node_count (" << node_count << ") (" << __FILE__ << ":" << __LINE__ << ")" << endl;
		#endif
		return -1;
	}
	int cur = node_id;
	int count = 0;
	while(nodes()[cur].parent != -1){
 		#ifdef DEBUG
		if(verbose)
			cout << "Unravelling " << cur << endl;
		#endif
		cur = nodes()[cur].parent;
		++count;
	}
	#ifdef DEBUG
	if(verbose)
		cout << "Root: " << cur << endl;
	int tree_id = -1;
	for(int i = 0; i < tree_count; ++i){
		if(tree_bases()[i].root == cur){
			if(verbose)
				cout << "Root of " << i << endl;
			tree_id = i;
		}
	}
	if(verbose && tree_id == -1)
		cout << "Root of none of the " << tree_count << " trees.";
	#endif
	return count;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movq -0x10(%rbp), %rcx
movq %rcx, -0x28(%rbp)
movl -0x14(%rbp), %eax
cmpl 0x17d4(%rcx), %eax
jl 0x73bb
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x740d
movl -0x14(%rbp), %eax
movl %eax, -0x18(%rbp)
movl $0x0, -0x1c(%rbp)
movq -0x28(%rbp), %rdi
callq 0x1b00
movslq -0x18(%rbp), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
cmpl $-0x1, 0x58(%rax)
je 0x7407
movq -0x28(%rbp), %rdi
callq 0x1b00
movslq -0x18(%rbp), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movl 0x58(%rax), %eax
movl %eax, -0x18(%rbp)
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x73c8
movl -0x1c(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: CoarseMondrianForest<double, funct, KappaMetrics<2, false>, 4, 2, 6000>::TreeBase::is_paused(int) const
bool is_paused(int const tree_management = 0) const{
		if(tree_management == ROBUR_MANAGEMENT || tree_management == PAUSING_PHOENIX_MANAGEMENT)
			return size >= node_count_limit;
		else if(tree_management == COBBLE_MANAGEMENT || tree_management == OPTIMISTIC_COBBLE_MANAGEMENT)
			return false; //
		else if(tree_management == PHOENIX_MANAGEMENT)
			return false;
		return false;
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
cmpl $0x2, -0x14(%rbp)
je 0x743f
cmpl $0x4, -0x14(%rbp)
jne 0x7452
movq -0x20(%rbp), %rcx
movl 0x4(%rcx), %eax
cmpl (%rcx), %eax
setge %al
andb $0x1, %al
movb %al, -0x1(%rbp)
jmp 0x7478
cmpl $0x0, -0x14(%rbp)
je 0x745e
cmpl $0x1, -0x14(%rbp)
jne 0x7464
movb $0x0, -0x1(%rbp)
jmp 0x7478
cmpl $0x3, -0x14(%rbp)
jne 0x7470
movb $0x0, -0x1(%rbp)
jmp 0x7478
jmp 0x7472
jmp 0x7474
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
popq %rbp
retq
nop
// File: big-data-lab-team[P]OrpailleCC/./src/utils.hpp
// Function: Utils::turn_array_into_probability(double*, int, double)
static void turn_array_into_probability(double* values, int const size, double sum = -1) {
		//Compute the sum unless sum is already computed
		if(sum < 0){
			sum = 0;
			for(int i = 0; i < size; ++i)
				sum += values[i];
		}
		//Set the first element of the array to its probability
		values[0] = (values[0]/sum);

		//Itirate to create the sum of probabilities
		for(int i = 1; i < size; ++i)
			values[i] = values[i-1] + (values[i]/sum);
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movsd %xmm0, -0x18(%rbp)
xorps %xmm0, %xmm0
ucomisd -0x18(%rbp), %xmm0
jbe 0x74d5
xorps %xmm0, %xmm0
movsd %xmm0, -0x18(%rbp)
movl $0x0, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
cmpl -0xc(%rbp), %eax
jge 0x74d3
movq -0x8(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm0
addsd -0x18(%rbp), %xmm0
movsd %xmm0, -0x18(%rbp)
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x74a9
jmp 0x74d5
movq -0x8(%rbp), %rax
movsd (%rax), %xmm0
divsd -0x18(%rbp), %xmm0
movq -0x8(%rbp), %rax
movsd %xmm0, (%rax)
movl $0x1, -0x20(%rbp)
movl -0x20(%rbp), %eax
cmpl -0xc(%rbp), %eax
jge 0x7539
movq -0x8(%rbp), %rax
movl -0x20(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movsd (%rax,%rcx,8), %xmm0
movq -0x8(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm1
divsd -0x18(%rbp), %xmm1
addsd %xmm1, %xmm0
movq -0x8(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsd %xmm0, (%rax,%rcx,8)
movl -0x20(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x20(%rbp)
jmp 0x74f1
popq %rbp
retq
nopl (%rax,%rax)
// File: big-data-lab-team[P]OrpailleCC/./src/utils.hpp
// Function: int Utils::pick_from_distribution<funct>(double const*, int)
static int pick_from_distribution(double const*const probabilities, const int size){
		double const u = func::rand_uniform(); //Sample a random number between [0,1[
		//NOTE improve with a log search :]
		for(int i = 0; i < size; ++i){
			if(u <= probabilities[i])
				return i;
		}
		return size;//NOTE: this should never happen unless the last element of *probabilities* is less than 1
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
callq 0x35a0
movsd %xmm0, -0x20(%rbp)
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl -0x14(%rbp), %eax
jge 0x7595
movsd -0x20(%rbp), %xmm1
movq -0x10(%rbp), %rax
movslq -0x24(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm0
ucomisd %xmm1, %xmm0
jb 0x7588
movl -0x24(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x759b
jmp 0x758a
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x7560
movl -0x14(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nop
// File: big-data-lab-team[P]OrpailleCC/./src/mondrian_coarse.hpp
// Function: CoarseMondrianForest<double, funct, KappaMetrics<2, false>, 4, 2, 6000>::pass_data_point_down(int, double const*, int)
int pass_data_point_down(int const start_id, feature_type const* features, int const label){
	int node_id = start_id;

	//Loop to find the leaf
	while(true){
		Node& node = nodes()[node_id];
		//Update box size
		for(int i = 0; i < feature_count; ++i){
			double const lower = Utils::min(node.bound_lower[i], features[i]);
			double const upper = Utils::max(node.bound_upper[i], features[i]);
			node.bound_lower[i] = lower;
			node.bound_upper[i] = upper;
		}
		if(node.is_leaf())
			break;
		//Choose a direction
		if(features[node.split_dimension] > node.split_value)
			node_id = node.child_right;
		else
			node_id = node.child_left;
	}
	Node& node = nodes()[node_id];
	node.counters[label] += 1;
	node.fading_score += 1; //fading_score is decreased later
	return node_id;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x50(%rbp)
movl -0xc(%rbp), %eax
movl %eax, -0x20(%rbp)
movq -0x50(%rbp), %rdi
callq 0x1b00
movslq -0x20(%rbp), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movl $0x0, -0x2c(%rbp)
cmpl $0x4, -0x2c(%rbp)
jge 0x9ca7
movq -0x28(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movsd 0x10(%rax,%rcx,8), %xmm0
movq -0x18(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm1
callq 0x8bc0
movsd %xmm0, -0x38(%rbp)
movq -0x28(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movsd 0x30(%rax,%rcx,8), %xmm0
movq -0x18(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm1
callq 0x2a80
movsd %xmm0, -0x40(%rbp)
movsd -0x38(%rbp), %xmm0
movq -0x28(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movsd %xmm0, 0x10(%rax,%rcx,8)
movsd -0x40(%rbp), %xmm0
movq -0x28(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movsd %xmm0, 0x30(%rax,%rcx,8)
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x9c23
movq -0x28(%rbp), %rdi
callq 0x29e0
testb $0x1, %al
jne 0x9cb6
jmp 0x9cb8
jmp 0x9cee
movq -0x18(%rbp), %rax
movq -0x28(%rbp), %rcx
movslq (%rcx), %rcx
movsd (%rax,%rcx,8), %xmm0
movq -0x28(%rbp), %rax
ucomisd 0x8(%rax), %xmm0
jbe 0x9cdf
movq -0x28(%rbp), %rax
movl 0x54(%rax), %eax
movl %eax, -0x20(%rbp)
jmp 0x9ce9
movq -0x28(%rbp), %rax
movl 0x50(%rax), %eax
movl %eax, -0x20(%rbp)
jmp 0x9c04
movq -0x50(%rbp), %rdi
callq 0x1b00
movslq -0x20(%rbp), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movq %rax, -0x48(%rbp)
movq -0x48(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movl 0x68(%rax,%rcx,4), %edx
addl $0x1, %edx
movl %edx, 0x68(%rax,%rcx,4)
movq -0x48(%rbp), %rax
movsd 0x12f3(%rip), %xmm0     # 0xb018
addsd 0x78(%rax), %xmm0
movsd %xmm0, 0x78(%rax)
movl -0x20(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: ef-gy[P]libefgy/include/ef.gy/polar.h
// Function: efgy::math::vector<double, 3u, efgy::math::format::polar>::operator efgy::math::vector<double, 3u, efgy::math::format::cartesian>() const
operator vector<F, n, format::cartesian>() const {
    vector<F, n, format::cartesian> v;

    for (unsigned int i = 0; i < n; i++) {
      v[i] = (*this)[0];
    }

#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wtautological-compare"
    for (unsigned int i = 0; i < (n - 1); i++)
#pragma clang diagnostic pop
    {
      const unsigned int p = i + 1;

      v[i] *= math::cosine((*this)[p], spaceTag.precision);

      for (unsigned int j = p; j < n; j++) {
        v[j] *= math::sine((*this)[p], spaceTag.precision);
      }
    }

    return v;
  }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x40(%rbp)
movq %rdi, -0x50(%rbp)
movq %rsi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x48(%rbp)
leaq -0x20(%rbp), %rdi
xorl %esi, %esi
movl $0x18, %edx
callq 0x51c0
movq -0x40(%rbp), %rdi
leaq -0x20(%rbp), %rsi
leaq -0x21(%rbp), %rdx
callq 0x33850
movl $0x0, -0x28(%rbp)
cmpl $0x3, -0x28(%rbp)
jae 0x6da2
movq -0x48(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x33570
movq -0x40(%rbp), %rdi
movsd (%rax), %xmm0
movsd %xmm0, -0x58(%rbp)
movl -0x28(%rbp), %eax
movl %eax, %esi
callq 0x335a0
movsd -0x58(%rbp), %xmm0
movsd %xmm0, (%rax)
movl -0x28(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x28(%rbp)
jmp 0x6d64
movl $0x0, -0x2c(%rbp)
cmpl $0x2, -0x2c(%rbp)
jae 0x6e5f
movq -0x48(%rbp), %rdi
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x30(%rbp)
movl -0x30(%rbp), %eax
movl %eax, %esi
callq 0x33570
movq -0x48(%rbp), %rsi
movq %rax, %rdi
addq $0x18, %rsi
callq 0x6500
movq -0x40(%rbp), %rdi
movsd %xmm0, -0x60(%rbp)
movl -0x2c(%rbp), %eax
movl %eax, %esi
callq 0x335a0
movsd -0x60(%rbp), %xmm0
mulsd (%rax), %xmm0
movsd %xmm0, (%rax)
movl -0x30(%rbp), %eax
movl %eax, -0x34(%rbp)
cmpl $0x3, -0x34(%rbp)
jae 0x6e4f
movq -0x48(%rbp), %rdi
movl -0x30(%rbp), %eax
movl %eax, %esi
callq 0x33570
movq -0x48(%rbp), %rsi
movq %rax, %rdi
addq $0x18, %rsi
callq 0x6530
movq -0x40(%rbp), %rdi
movsd %xmm0, -0x68(%rbp)
movl -0x34(%rbp), %eax
movl %eax, %esi
callq 0x335a0
movsd -0x68(%rbp), %xmm0
mulsd (%rax), %xmm0
movsd %xmm0, (%rax)
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x6e00
jmp 0x6e51
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x6da9
movq -0x50(%rbp), %rax
addq $0x70, %rsp
popq %rbp
retq
nopl (%rax)
// File: ef-gy[P]libefgy/include/ef.gy/polar.h
// Function: efgy::math::vector<double, 3u, efgy::math::format::polar>::vector(efgy::math::vector<double, 3u, efgy::math::format::cartesian> const&, efgy::math::format::polar const&)
vector(const vector<F, n, format::cartesian> &v,
         const format::polar &s = format::polar())
      : std::array<F, n>(), spaceTag(s) {
    (*this)[0] = length(v);
    for (unsigned int k = 0; k < (n - 1); k++) {
      F s = F(0);
      for (unsigned int i = k; i < n; i++) {
        s += v[i] * v[i];
      }
      s = v[k] / sqrt(s);
      if (k == (n - 2)) {
        (*this)[(n - 1)] = arccosine(s);
        if (v[(n - 1)] < F(0)) {
          (*this)[(n - 1)] = M_PI * F(2) - (*this)[(n - 1)];
        }
      } else {
        (*this)[(k + 1)] = arccosine(s);
      }
    }
  }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x50(%rbp)
xorl %esi, %esi
movl $0x18, %edx
callq 0x51c0
movq -0x50(%rbp), %rax
movq -0x18(%rbp), %rcx
movq (%rcx), %rcx
movq %rcx, 0x18(%rax)
movq -0x10(%rbp), %rdi
callq 0x33890
movq -0x50(%rbp), %rdi
movsd %xmm0, -0x48(%rbp)
xorl %eax, %eax
movl %eax, %esi
callq 0x335a0
movsd -0x48(%rbp), %xmm0
movsd %xmm0, (%rax)
movl $0x0, -0x1c(%rbp)
cmpl $0x2, -0x1c(%rbp)
jae 0x70f0
xorps %xmm0, %xmm0
movsd %xmm0, -0x28(%rbp)
movl -0x1c(%rbp), %eax
movl %eax, -0x2c(%rbp)
cmpl $0x3, -0x2c(%rbp)
jae 0x6fee
movq -0x10(%rbp), %rdi
movl -0x2c(%rbp), %eax
movl %eax, %esi
callq 0x33570
movsd (%rax), %xmm0
movsd %xmm0, -0x58(%rbp)
movq -0x10(%rbp), %rdi
movl -0x2c(%rbp), %eax
movl %eax, %esi
callq 0x33570
movsd -0x58(%rbp), %xmm0
movsd (%rax), %xmm2
movsd -0x28(%rbp), %xmm1
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, -0x28(%rbp)
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x6f9d
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
movl %eax, %esi
callq 0x33570
movsd (%rax), %xmm0
movsd %xmm0, -0x60(%rbp)
movsd -0x28(%rbp), %xmm0
callq 0x52e0
movaps %xmm0, %xmm1
movsd -0x60(%rbp), %xmm0
divsd %xmm1, %xmm0
movsd %xmm0, -0x28(%rbp)
cmpl $0x1, -0x1c(%rbp)
jne 0x70aa
movq $0xa, -0x38(%rbp)
leaq -0x28(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0x6560
movq -0x50(%rbp), %rdi
movsd %xmm0, -0x68(%rbp)
movl $0x2, %esi
callq 0x335a0
movsd -0x68(%rbp), %xmm0
movsd %xmm0, (%rax)
movq -0x10(%rbp), %rdi
movl $0x2, %esi
callq 0x33570
xorps %xmm0, %xmm0
ucomisd (%rax), %xmm0
jbe 0x70a8
movq -0x50(%rbp), %rdi
movl $0x2, %esi
callq 0x335a0
movq -0x50(%rbp), %rdi
movsd 0x2cf7c(%rip), %xmm0    # 0x34008
subsd (%rax), %xmm0
movsd %xmm0, -0x70(%rbp)
movl $0x2, %esi
callq 0x335a0
movsd -0x70(%rbp), %xmm0
movsd %xmm0, (%rax)
jmp 0x70e0
movq $0xa, -0x40(%rbp)
leaq -0x28(%rbp), %rdi
leaq -0x40(%rbp), %rsi
callq 0x6560
movq -0x50(%rbp), %rdi
movsd %xmm0, -0x78(%rbp)
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x335a0
movsd -0x78(%rbp), %xmm0
movsd %xmm0, (%rax)
jmp 0x70e2
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x6f85
addq $0x80, %rsp
popq %rbp
retq
nopl (%rax)
// File: ef-gy[P]libefgy/include/ef.gy/vector.h
// Function: double efgy::math::operator*<double, 3u, efgy::math::format::cartesian>(efgy::math::vector<double, 3u, efgy::math::format::cartesian> const&, efgy::math::vector<double, 3u, efgy::math::format::cartesian> const&)
F operator*(const vector<F, n, format> &a, const vector<F, n, format> &b) {
  F s = F(0);
  for (unsigned int i = 0; i < n; i++) {
    s += a[i] * b[i];
  }
  return s;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
xorps %xmm0, %xmm0
movsd %xmm0, -0x18(%rbp)
movl $0x0, -0x1c(%rbp)
cmpl $0x3, -0x1c(%rbp)
jae 0x33940
movq -0x8(%rbp), %rdi
movl -0x1c(%rbp), %eax
movl %eax, %esi
callq 0x33570
movsd (%rax), %xmm0
movsd %xmm0, -0x28(%rbp)
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %eax
movl %eax, %esi
callq 0x33570
movsd -0x28(%rbp), %xmm0
movsd (%rax), %xmm2
movsd -0x18(%rbp), %xmm1
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, -0x18(%rbp)
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x338ef
movsd -0x18(%rbp), %xmm0
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: sbme-tutorials[P]huffman-encoding/huffman.cpp
// Function: Huffman::readInput()
void Huffman::readInput()
{
    std::cin >> intensity >> width >> height >> maxIntensity;
    for (int i = 0; i < width * height; i++)
    {
        int temp;
        std::cin >> temp;
        input.push_back(temp);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rsi
movq %rsi, -0x20(%rbp)
addq $0x30, %rsi
movq 0xdf91(%rip), %rdi      # 0x12fe0
callq 0x3380
movq -0x20(%rbp), %rsi
movq %rax, %rdi
addq $0x20, %rsi
callq 0x31c0
movq -0x20(%rbp), %rsi
movq %rax, %rdi
addq $0x24, %rsi
callq 0x31c0
movq -0x20(%rbp), %rsi
movq %rax, %rdi
addq $0x28, %rsi
callq 0x31c0
movl $0x0, -0xc(%rbp)
movq -0x20(%rbp), %rdx
movl -0xc(%rbp), %eax
movl 0x20(%rdx), %ecx
imull 0x24(%rdx), %ecx
cmpl %ecx, %eax
jge 0x50cf
movq 0xdf3c(%rip), %rdi      # 0x12fe0
leaq -0x10(%rbp), %rsi
callq 0x31c0
movq -0x20(%rbp), %rdi
addq $0x58, %rdi
movl -0x10(%rbp), %eax
movb %al, -0x11(%rbp)
leaq -0x11(%rbp), %rsi
callq 0x6e60
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x508b
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: sbme-tutorials[P]huffman-encoding/huffman.cpp
// Function: Huffman::computeProb()
float Huffman::computeProb() // computes entropy and probability of each greyscale value
{
    unsigned long long pixels = input.size(); // total number of pixels in the pic
    float entropy = 0;
    for (auto value : input) // for loop to calculate frequency of each greyscale value
    {
        probability[value]++;
    }
    // divide the frequency over total
    // number of pixels to get probability
    for (auto &value : probability)
    {
        value.second = value.second / (float)pixels;
        entropy += value.second * log2(value.second); //entropy formula
    }
    return -1 * entropy;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x60(%rbp)
addq $0x58, %rdi
callq 0x6e90
movq %rax, %rcx
movq -0x60(%rbp), %rax
movq %rcx, -0x10(%rbp)
xorps %xmm0, %xmm0
movss %xmm0, -0x14(%rbp)
addq $0x58, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdi
callq 0x6eb0
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rdi
callq 0x6ee0
movq %rax, -0x30(%rbp)
leaq -0x28(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x6f10
testb $0x1, %al
jne 0x5145
jmp 0x517f
leaq -0x28(%rbp), %rdi
callq 0x6f50
movq -0x60(%rbp), %rdi
movb (%rax), %al
movb %al, -0x31(%rbp)
addq $0x70, %rdi
leaq -0x31(%rbp), %rsi
callq 0x6f70
movss 0x7ee0(%rip), %xmm0     # 0xd04c
addss (%rax), %xmm0
movss %xmm0, (%rax)
leaq -0x28(%rbp), %rdi
callq 0x7050
jmp 0x5132
movq -0x60(%rbp), %rax
addq $0x70, %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rdi
callq 0x7070
movq %rax, -0x48(%rbp)
movq -0x40(%rbp), %rdi
callq 0x70a0
movq %rax, -0x50(%rbp)
leaq -0x48(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x70d0
testb $0x1, %al
jne 0x51bb
jmp 0x526a
leaq -0x48(%rbp), %rdi
callq 0x7100
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rax
movss 0x4(%rax), %xmm0
movss %xmm0, -0x6c(%rbp)
movq -0x10(%rbp), %rax
movq %rax, %rdx
shrq %rdx
movl %eax, %ecx
andl $0x1, %ecx
orq %rdx, %rcx
cvtsi2ss %rcx, %xmm0
addss %xmm0, %xmm0
cvtsi2ss %rax, %xmm1
movss %xmm1, -0x68(%rbp)
testq %rax, %rax
movss %xmm0, -0x64(%rbp)
js 0x520f
movss -0x68(%rbp), %xmm0
movss %xmm0, -0x64(%rbp)
movss -0x6c(%rbp), %xmm0
movss -0x64(%rbp), %xmm1
divss %xmm1, %xmm0
movq -0x58(%rbp), %rax
movss %xmm0, 0x4(%rax)
movq -0x58(%rbp), %rax
movss 0x4(%rax), %xmm0
movss %xmm0, -0x70(%rbp)
movq -0x58(%rbp), %rax
movss 0x4(%rax), %xmm0
callq 0x7120
movaps %xmm0, %xmm2
movss -0x70(%rbp), %xmm0
movss -0x14(%rbp), %xmm1
mulss %xmm2, %xmm0
addss %xmm1, %xmm0
movss %xmm0, -0x14(%rbp)
leaq -0x48(%rbp), %rdi
callq 0x7140
jmp 0x51a5
movss 0x7dd6(%rip), %xmm0     # 0xd048
mulss -0x14(%rbp), %xmm0
addq $0x70, %rsp
popq %rbp
retq
nopl (%rax)
// File: sbme-tutorials[P]huffman-encoding/huffman.cpp
// Function: Huffman::getCodeTable(Node*, char*, int)
void Huffman::getCodeTable(Node *parent, char *arr, int index)
{
    if (parent->left)
    {
        arr[index] = '0';
        getCodeTable(parent->left, arr, index + 1);
    }

    if (parent->right)
    {
        arr[index] = '1';
        getCodeTable(parent->right, arr, index + 1);
    }

    if (!(parent->right || parent->left))
    {
        std::string binaryCode(arr, arr + index);
        codeTable[parent->val] = binaryCode;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x5604
movq -0x60(%rbp), %rdi
movq -0x18(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movb $0x30, (%rax,%rcx)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rsi
movq -0x18(%rbp), %rdx
movl -0x1c(%rbp), %ecx
addl $0x1, %ecx
callq 0x55b0
movq -0x10(%rbp), %rax
cmpq $0x0, 0x10(%rax)
je 0x5636
movq -0x60(%rbp), %rdi
movq -0x18(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movb $0x31, (%rax,%rcx)
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rsi
movq -0x18(%rbp), %rdx
movl -0x1c(%rbp), %ecx
addl $0x1, %ecx
callq 0x55b0
movq -0x10(%rbp), %rax
cmpq $0x0, 0x10(%rax)
jne 0x56f6
movq -0x10(%rbp), %rax
cmpq $0x0, 0x8(%rax)
jne 0x56f6
movq -0x18(%rbp), %rax
movq %rax, -0x78(%rbp)
movslq -0x1c(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0x70(%rbp)
leaq -0x41(%rbp), %rdi
movq %rdi, -0x68(%rbp)
callq 0x34f0
movq -0x78(%rbp), %rsi
movq -0x70(%rbp), %rdx
movq -0x68(%rbp), %rcx
leaq -0x40(%rbp), %rdi
callq 0x7190
jmp 0x568b
leaq -0x41(%rbp), %rdi
callq 0x3310
movq -0x60(%rbp), %rdi
addq $0xa0, %rdi
movq -0x10(%rbp), %rsi
callq 0x7200
movq %rax, -0x80(%rbp)
jmp 0x56ae
movq -0x80(%rbp), %rdi
leaq -0x40(%rbp), %rsi
callq 0x3040
jmp 0x56bd
leaq -0x40(%rbp), %rdi
callq 0x31d0
jmp 0x56f6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x41(%rbp), %rdi
callq 0x3310
jmp 0x56ff
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x40(%rbp), %rdi
callq 0x31d0
jmp 0x56ff
addq $0x80, %rsp
popq %rbp
retq
movq -0x50(%rbp), %rdi
callq 0x34e0
nopl (%rax,%rax)