LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/RuiDGPires[P]CrimLang/src/parser.cpp
// Function: ps_Tracker::comparison()
void _ps_Tracker::comparison(){
	this->enter(crl::Node::Type::COMPARISON);
	this->basic_expression();
	while(accept TYPE_EQ()){
		this->add(this->previous());
		this->basic_expression();
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
movl $0x18, %esi
callq 0xfafa
movq %rbx, %rdi
callq 0x105c8
movq %rbx, %rdi
movl $0x6, %esi
movl $0x2f, %edx
movl $0x34, %ecx
movl $0x31, %r8d
movl $0x30, %r9d
xorl %eax, %eax
pushq $0x33
pushq $0x32
callq 0xf8ec
addq $0x10, %rsp
testb %al, %al
je 0x1081b
leaq -0x48(%rbp), %r15
leaq -0x58(%rbp), %r14
movq (%rbx), %r12
movq 0x28(%rbx), %rax
leaq (%rax,%rax,2), %r13
shlq $0x4, %r13
movq %r15, -0x58(%rbp)
movq -0x30(%r12,%r13), %rsi
movq -0x28(%r12,%r13), %rdx
addq %rsi, %rdx
movq %r14, %rdi
callq 0x4d52
movl -0x8(%r12,%r13), %eax
movl %eax, 0x18(%r15)
movq -0x10(%r12,%r13), %rax
movq %rax, 0x10(%r15)
movq %rbx, %rdi
movq %r14, %rsi
callq 0xfc00
movq %r14, %rdi
callq 0x191f8
movq %rbx, %rdi
callq 0x105c8
movq %rbx, %rdi
movl $0x6, %esi
movl $0x2f, %edx
movl $0x34, %ecx
movl $0x31, %r8d
movl $0x30, %r9d
xorl %eax, %eax
pushq $0x33
pushq $0x32
callq 0xf8ec
addq $0x10, %rsp
testb %al, %al
jne 0x10791
movq 0x18(%rbx), %rax
movq 0x28(%rax), %rax
movq %rax, 0x18(%rbx)
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x58(%rbp), %rdi
callq 0x191f8
movq %rbx, %rdi
callq 0x33f0
// File: /workspace/github_cpp_makefile_star2_O3/RuiDGPires[P]CrimLang/src/parser.cpp
// Function: ps_Tracker::casted_expression()
void _ps_Tracker::casted_expression(){
	this->enter(crl::Node::Type::EXPRESSION);
	this->enter(crl::Node::Type::COMPARISON);
	this->enter(crl::Node::Type::EXPRESSION);
	this->enter(crl::Node::Type::TERM);
	this->enter(crl::Node::Type::FACTOR);
	this->enter(crl::Node::Type::CAST);

	this->expression();

	crl::Token t;
	t.type = crl::Token::Type::U32; t.str = "u32";
	this->add(t);
	this->leave();
	this->leave();
	this->leave();
	this->leave();
	this->leave();
	this->leave();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x60, %rsp
movq %rdi, %rbx
movl $0xd, %esi
callq 0xfafa
movq %rbx, %rdi
movl $0x18, %esi
callq 0xfafa
movq %rbx, %rdi
movl $0xd, %esi
callq 0xfafa
movq %rbx, %rdi
movl $0xe, %esi
callq 0xfafa
movq %rbx, %rdi
movl $0xf, %esi
callq 0xfafa
movq %rbx, %rdi
movl $0x15, %esi
callq 0xfafa
movq %rbx, %rdi
callq 0xfeb6
leaq -0x40(%rbp), %r14
movq %r14, %rdi
callq 0x1918c
movl $0x9, 0x20(%r14)
movq 0x8(%r14), %rdx
leaq 0xadc9(%rip), %rcx      # 0x1b693
movl $0x3, %r8d
movq %r14, %rdi
xorl %esi, %esi
callq 0x3340
leaq -0x60(%rbp), %rax
movq %rax, -0x10(%rax)
movq -0x40(%rbp), %rsi
movq -0x38(%rbp), %rdx
addq %rsi, %rdx
leaq -0x70(%rbp), %rdi
callq 0x4d52
leaq -0x20(%rbp), %rax
movl 0x8(%rax), %ecx
leaq -0x70(%rbp), %rsi
movl %ecx, 0x28(%rsi)
movq (%rax), %rax
movq %rax, 0x20(%rsi)
movq %rbx, %rdi
callq 0xfc00
leaq -0x70(%rbp), %rdi
callq 0x191f8
movq 0x18(%rbx), %rax
movq 0x28(%rax), %rax
movq 0x28(%rax), %rax
movq 0x28(%rax), %rax
movq 0x28(%rax), %rax
movq 0x28(%rax), %rax
movq 0x28(%rax), %rax
movq %rax, 0x18(%rbx)
leaq -0x40(%rbp), %rdi
callq 0x191f8
addq $0x60, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %rbx
leaq -0x70(%rbp), %rdi
callq 0x191f8
jmp 0x1095f
movq %rax, %rbx
leaq -0x40(%rbp), %rdi
callq 0x191f8
movq %rbx, %rdi
callq 0x33f0
// File: /workspace/github_cpp_makefile_star2_O3/RuiDGPires[P]CrimLang/src/parser.cpp
// Function: ps_Tracker::program()
void _ps_Tracker::program(){
	this->enter(crl::Node::Type::PROGRAM);
	while(!accept(crl::Token::Type::EOF_)){
		this->declaration();
	}
	
	this->leave();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl $0x1, %esi
callq 0xfafa
cmpl $0x3a, 0x58(%rbx)
je 0x10993
movq %rbx, %rdi
callq 0x109ae
jmp 0x10983
movq %rbx, %rdi
callq 0xf824
movq 0x18(%rbx), %rax
movq 0x28(%rax), %rax
movq %rax, 0x18(%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/RuiDGPires[P]CrimLang/src/parser.cpp
// Function: ps_Tracker::block(crl::Token::Type)
void _ps_Tracker::block(crl::Token::Type t){
	this->enter(crl::Node::Type::BLOCK);
	while(!accept(t))
		statement();		
	this->leave();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %esi, %r14d
movq %rdi, %rbx
movl $0x5, %esi
callq 0xfafa
cmpl %r14d, 0x58(%rbx)
je 0x11549
movq %rbx, %rdi
callq 0x11562
jmp 0x11539
movq %rbx, %rdi
callq 0xf824
movq 0x18(%rbx), %rax
movq 0x28(%rax), %rax
movq %rax, 0x18(%rbx)
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/RuiDGPires[P]CrimLang/src/parser.cpp
// Function: parse_assign[abi:cxx11](crl::Token::Type)
std::string parse_assign(crl::Token::Type t){
	switch (t){
		case crl::Token::Type::PLEQ:
			return "plus";	
		case crl::Token::Type::BECOMES:
			return "";	
		case crl::Token::Type::MIEQ:
			return "minus";	
		case crl::Token::Type::TIEQ:
			return "times";	
		case crl::Token::Type::SLEQ:
			return "slash";	
		default:
			return "";
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
addl $-0x2a, %esi
cmpl $0x4, %esi
ja 0x1209f
leaq 0x96c6(%rip), %rax      # 0x1b75c
movslq (%rax,%rsi,4), %rcx
addq %rax, %rcx
jmpq *%rcx
leaq 0x943e(%rip), %rdx      # 0x1b4e4
movq %rbx, %rdi
movq %rdx, %rsi
jmp 0x120ef
leaq 0x9510(%rip), %rsi      # 0x1b5c5
leaq 0x950e(%rip), %rdx      # 0x1b5ca
jmp 0x120ec
leaq 0x94ec(%rip), %rsi      # 0x1b5b1
leaq 0x94ea(%rip), %rdx      # 0x1b5b6
jmp 0x120ec
leaq 0x94e6(%rip), %rsi      # 0x1b5bb
leaq 0x94e4(%rip), %rdx      # 0x1b5c0
jmp 0x120ec
leaq 0x94c3(%rip), %rsi      # 0x1b5a8
leaq 0x94c0(%rip), %rdx      # 0x1b5ac
movq %rbx, %rdi
callq 0x4336
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/RuiDGPires[P]CrimLang/src/parser.cpp
// Function: ps_Tracker::_ps_Tracker(std::vector<crl::Token, std::allocator<crl::Token>>&)
_ps_Tracker(std::vector<crl::Token> &tl){
			this->token_list = tl; 
			this->aux = new crl::Node();
			this->ast = aux;
			this->current = tl[0];
		}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %r15
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
xorl %eax, %eax
movq %rax, 0x10(%rdi)
movq %rax, 0x28(%rdi)
movb $0x0, 0x30(%rdi)
leaq 0x38(%rdi), %r14
movq %r14, %rdi
callq 0x1918c
movq %rbx, %rdi
movq %r15, %rsi
callq 0x12366
movl $0x58, %edi
callq 0x3220
movq %rax, %r12
movq %rax, %rdi
callq 0x381c
movq %r12, 0x20(%rbx)
movq %r12, 0x18(%rbx)
movq (%r15), %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x3150
movl 0x28(%r15), %eax
movl %eax, 0x60(%rbx)
movq 0x20(%r15), %rax
movq %rax, 0x58(%rbx)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r15
movl $0x58, %esi
movq %r12, %rdi
callq 0x3230
jmp 0x1234d
movq %rax, %r15
jmp 0x12355
movq %rax, %r15
movq %r14, %rdi
callq 0x191f8
movq %rbx, %rdi
callq 0xf6fc
movq %r15, %rdi
callq 0x33f0
nop
// File: /workspace/github_cpp_makefile_star2_O3/RuiDGPires[P]CrimLang/src/preprocessor.cpp
// Function: include(std::vector<crl::Token, std::allocator<crl::Token>>&, crl::preprocessor_lib, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, unsigned long&, unsigned long&)
static void include(std::vector<crl::Token> &current, crl::Pproc_lib lib, std::string other, size_t &begin, size_t &i){
	std::vector<crl::Token> other_file = crl::tokenize(other);
	preprocess(other_file, lib);

	size_t other_size = other_file.size();
	current.erase(current.begin() + begin, current.begin() + begin + 4);
	current.insert(current.begin() + begin, other_file.begin(), other_file.end() - 1);
	i += other_size-2;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %r9, -0x48(%rbp)
movq %r8, %r15
movq %rdx, %r12
movq %rsi, %r13
movq %rdi, %r14
leaq -0x58(%rbp), %rax
movq %rax, -0x10(%rax)
movq (%rcx), %rsi
movq 0x8(%rcx), %rdx
addq %rsi, %rdx
leaq -0x68(%rbp), %rbx
movq %rbx, %rdi
callq 0x4d52
leaq -0x40(%rbp), %rdi
movq %rbx, %rsi
callq 0x1a488
movq -0x68(%rbp), %rdi
leaq -0x58(%rbp), %rax
cmpq %rax, %rdi
je 0x133f3
movq -0x58(%rbp), %rsi
incq %rsi
callq 0x3230
leaq -0x40(%rbp), %rdi
movq %r13, %rsi
movq %r12, %rdx
callq 0x128f8
movq -0x40(%rbp), %r12
movq -0x38(%rbp), %rbx
movq (%r14), %rax
movq (%r15), %rcx
leaq (%rcx,%rcx,2), %rcx
shlq $0x4, %rcx
leaq (%rax,%rcx), %rsi
leaq (%rax,%rcx), %rdx
addq $0xc0, %rdx
movq %r14, %rdi
callq 0x134c6
movq (%r15), %rax
leaq (%rax,%rax,2), %rsi
shlq $0x4, %rsi
addq (%r14), %rsi
movq -0x40(%rbp), %rdx
movq -0x38(%rbp), %rcx
addq $-0x30, %rcx
movq %r14, %rdi
callq 0x13592
subq %r12, %rbx
sarq $0x4, %rbx
movabsq $-0x5555555555555555, %rax # imm = 0xAAAAAAAAAAAAAAAB
imulq %rbx, %rax
movq -0x48(%rbp), %rdx
movq (%rdx), %rcx
addq %rcx, %rax
addq $-0x2, %rax
movq %rax, (%rdx)
leaq -0x40(%rbp), %rdi
callq 0xf6fc
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x13493
jmp 0x13493
movq %rax, %rbx
leaq -0x40(%rbp), %rdi
callq 0xf6fc
movq %rbx, %rdi
callq 0x33f0
movq %rax, %rbx
movq -0x68(%rbp), %rdi
leaq -0x58(%rbp), %rax
cmpq %rax, %rdi
je 0x1349f
movq -0x58(%rbp), %rsi
incq %rsi
callq 0x3230
jmp 0x1349f
nop
// File: /workspace/github_cpp_makefile_star2_O3/RuiDGPires[P]CrimLang/src/semantic_analiser.cpp
// Function: sc_Tracker::block(crl::Node*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void _sc_Tracker::block(crl::Node *node, std::string annotation){
	this->enter();
	size_t size = node->children.size();
	for (size_t i = 0; i < size; i++){
		this->statement(node->get_child(i), annotation);
	}
	this->leave();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdx, -0x40(%rbp)
movq %rsi, %r15
movq %rdi, -0x30(%rbp)
callq 0x13a90
movq 0x18(%r15), %rax
subq 0x10(%r15), %rax
je 0x1476c
sarq $0x3, %rax
cmpq $0x1, %rax
adcq $0x0, %rax
movq %rax, -0x38(%rbp)
xorl %r12d, %r12d
movq (%r15), %rax
movq %r15, %rdi
movl %r12d, %esi
callq *0x18(%rax)
movq %rax, %rbx
leaq -0x50(%rbp), %r13
movq %r13, -0x60(%rbp)
movq -0x40(%rbp), %rax
movq (%rax), %rsi
movq 0x8(%rax), %rdx
addq %rsi, %rdx
leaq -0x60(%rbp), %r14
movq %r14, %rdi
callq 0x4d52
movq -0x30(%rbp), %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x15d10
movq -0x60(%rbp), %rdi
cmpq %r13, %rdi
je 0x14763
movq -0x50(%rbp), %rsi
incq %rsi
callq 0x3230
incq %r12
cmpq %r12, -0x38(%rbp)
jne 0x1470e
movq -0x30(%rbp), %rcx
movq 0x8(%rcx), %r14
movq (%r14), %rax
movq %rax, 0x8(%rcx)
movq %r14, %rdi
callq 0x4420
movl $0x38, %esi
movq %r14, %rdi
callq 0x3230
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq -0x60(%rbp), %rdi
cmpq %r13, %rdi
je 0x147b7
movq -0x50(%rbp), %rsi
incq %rsi
callq 0x3230
movq %rbx, %rdi
callq 0x33f0
nop
// File: /workspace/github_cpp_makefile_star2_O3/RuiDGPires[P]CrimLang/src/semantic_analiser.cpp
// Function: sc_Tracker::program(crl::Node*)
void _sc_Tracker::program(crl::Node *node){
	size_t size = node->children.size();

	for (size_t i = 0; i < size; i++){
		crl::Node *child = node->get_child(i);
		ASSERT(child->type == crl::Node::Type::VAR_DECLARATION || child->type == crl::Node::Type::FUNC_DECLARATION || child->type == crl::Node::Type::CAS, "Program must only have declarations or cas instructions");
		if (child->type == crl::Node::Type::FUNC_DECLARATION)
			this->func_declaration(child);
		else if (child->type == crl::Node::Type::VAR_DECLARATION)
			this->var_declaration(child);
		else if (child->type == crl::Node::Type::CAS)
			this->cas(child);
		else
			ASSERT(false, "???");
	}	
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x20, %rsp
movq 0x18(%rsi), %r12
subq 0x10(%rsi), %r12
je 0x18437
movq %rsi, %rbx
movq %rdi, %r14
sarq $0x3, %r12
cmpq $0x1, %r12
adcq $0x0, %r12
xorl %r15d, %r15d
movq (%rbx), %rax
movq %rbx, %rdi
movl %r15d, %esi
callq *0x18(%rax)
movl 0x8(%rax), %ecx
cmpl $0x2, %ecx
je 0x18424
cmpl $0x3, %ecx
je 0x18417
cmpl $0x11, %ecx
jne 0x18444
movq %r14, %rdi
movq %rax, %rsi
callq 0x13cf6
jmp 0x1842f
movq %r14, %rdi
movq %rax, %rsi
callq 0x13fca
jmp 0x1842f
movq %r14, %rdi
movq %rax, %rsi
callq 0x147c0
incq %r15
cmpq %r15, %r12
jne 0x183ec
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movl $0x50, %edi
callq 0x3120
movq %rax, %rbx
leaq -0x30(%rbp), %r15
movq %r15, -0x10(%r15)
leaq 0x38f1(%rip), %rsi      # 0x1bd51
leaq 0x3921(%rip), %rdx      # 0x1bd88
leaq -0x40(%rbp), %rdi
callq 0x4336
movb $0x1, %r12b
leaq -0x40(%rbp), %rcx
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x5470
xorl %r12d, %r12d
leaq 0xa8e5(%rip), %rsi      # 0x22d78
leaq -0x12eb4(%rip), %rdx    # 0x55e6
movq %rbx, %rdi
callq 0x33d0
movq %rax, %r14
movq -0x40(%rbp), %rdi
cmpq %r15, %rdi
je 0x184ba
movq -0x30(%rbp), %rsi
incq %rsi
callq 0x3230
testb %r12b, %r12b
jne 0x184c4
jmp 0x184cc
movq %rax, %r14
movq %rbx, %rdi
callq 0x31a0
movq %r14, %rdi
callq 0x33f0
// File: /workspace/github_cpp_makefile_star2_O3/RuiDGPires[P]CrimLang/src/semantic_analiser.cpp
// Function: sc_Tracker::check()
void _sc_Tracker::check(){
	this->ast = this->ast->get_child(0); // Enter the program	
	this->program(this->ast);
	Context::Item item = this->context->seek("main");
	ASSERT(item.type == Context::Item::Type::FUNC, "Main function is not defined");
	ASSERT(item.subtype == "u32", "Main function is not defined");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0xd0, %rsp
movq %rdi, %rbx
movq (%rdi), %rdi
movq (%rdi), %rax
xorl %esi, %esi
callq *0x18(%rax)
movq %rax, (%rbx)
movq %rbx, %rdi
movq %rax, %rsi
callq 0x183be
movq 0x8(%rbx), %rbx
leaq -0x30(%rbp), %r15
movq %r15, -0x10(%r15)
leaq 0x3874(%rip), %rsi      # 0x1bd89
leaq 0x3871(%rip), %rdx      # 0x1bd8d
leaq -0x40(%rbp), %r14
movq %r14, %rdi
callq 0x4336
leaq -0xf0(%rbp), %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x442e
movq -0x40(%rbp), %rdi
cmpq %r15, %rdi
je 0x1854f
movq -0x30(%rbp), %rsi
incq %rsi
callq 0x3230
cmpl $0x1, -0xf0(%rbp)
jne 0x1858b
leaq -0xc8(%rbp), %rdi
leaq 0x312d(%rip), %rsi      # 0x1b693
callq 0x30a0
testl %eax, %eax
jne 0x185eb
leaq -0xf0(%rbp), %rdi
callq 0x4824
addq $0xd0, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movl $0x50, %edi
callq 0x3120
movq %rax, %rbx
leaq -0x70(%rbp), %r15
movq %r15, -0x10(%r15)
leaq 0x37e7(%rip), %rsi      # 0x1bd8e
leaq 0x37fc(%rip), %rdx      # 0x1bdaa
leaq -0x80(%rbp), %rdi
callq 0x4336
movb $0x1, %r12b
leaq -0x80(%rbp), %rcx
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x5470
xorl %r12d, %r12d
leaq 0xa79e(%rip), %rsi      # 0x22d78
leaq -0x12ffb(%rip), %rdx    # 0x55e6
movq %rbx, %rdi
callq 0x33d0
jmp 0x18649
movl $0x50, %edi
callq 0x3120
movq %rax, %rbx
leaq -0x50(%rbp), %r15
movq %r15, -0x10(%r15)
leaq 0x3787(%rip), %rsi      # 0x1bd8e
leaq 0x379c(%rip), %rdx      # 0x1bdaa
leaq -0x60(%rbp), %rdi
callq 0x4336
movb $0x1, %r12b
leaq -0x60(%rbp), %rcx
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x5470
xorl %r12d, %r12d
leaq 0xa73e(%rip), %rsi      # 0x22d78
leaq -0x1305b(%rip), %rdx    # 0x55e6
movq %rbx, %rdi
callq 0x33d0
movq %rax, %r14
movq -0x60(%rbp), %rdi
cmpq %r15, %rdi
je 0x18675
movq -0x50(%rbp), %rsi
jmp 0x1866d
jmp 0x1867c
movq %rax, %r14
movq -0x80(%rbp), %rdi
cmpq %r15, %rdi
je 0x18675
movq -0x70(%rbp), %rsi
incq %rsi
callq 0x3230
testb %r12b, %r12b
jne 0x1867f
jmp 0x18687
movq %rax, %r14
movq %rbx, %rdi
callq 0x31a0
leaq -0xf0(%rbp), %rdi
callq 0x4824
jmp 0x186ad
movq %rax, %r14
movq -0x40(%rbp), %rdi
cmpq %r15, %rdi
je 0x186ad
movq -0x30(%rbp), %rsi
incq %rsi
callq 0x3230
movq %r14, %rdi
callq 0x33f0
// File: /workspace/github_cpp_makefile_star2_O3/RuiDGPires[P]CrimLang/src/token.cpp
// Function: crl::Token::Token()
crl::Token::Token(){
	this->type = crl::Token::Type::NONE;
	this->str = "";
	this->line = 0;
	this->column = 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x10(%rdi), %r15
movq %r15, (%rdi)
movq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
movl $0x0, 0x20(%rdi)
leaq 0x232a(%rip), %rcx      # 0x1b4e4
xorl %esi, %esi
xorl %edx, %edx
xorl %r8d, %r8d
callq 0x3340
movq $0x0, 0x24(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq (%rbx), %rdi
cmpq %r15, %rdi
je 0x191ef
movq (%r15), %rsi
incq %rsi
callq 0x3230
movq %r14, %rdi
callq 0x33f0
nop
// File: /workspace/github_cpp_makefile_star2_O3/RuiDGPires[P]CrimLang/src/tokenizer.cpp
// Function: crl::tokenize(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
std::vector<crl::Token> crl::tokenize(std::string filename){
	std::ifstream file;
	file.open(filename);

	Tracker tracker;	
	char c;
	while (file >> std::noskipws >> c){
		tracker.take(c);
	}
	// TODO : Is this needed?
	tracker.take(c);

	tracker.dump_eof();
	file.close();

	return tracker.get_result();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x278, %rsp            # imm = 0x278
movq %rsi, %r14
movq %rdi, %rbx
leaq -0x298(%rbp), %r15
movq %r15, %rdi
callq 0x3270
movq %r15, %rdi
movq %r14, %rsi
movl $0x8, %edx
callq 0x3200
leaq -0x90(%rbp), %rdi
callq 0x1918c
leaq -0x48(%rbp), %r14
movl $0x1, -0x18(%r14)
movl $0x0, -0x8(%r14)
xorps %xmm0, %xmm0
movups %xmm0, (%r14)
xorl %eax, %eax
movq %rax, 0x10(%r14)
movq %rax, -0x14(%r14)
movb $0x0, -0xc(%r14)
leaq -0x29(%rbp), %r12
leaq -0x90(%rbp), %r13
movq -0x298(%rbp), %rax
movq -0x18(%rax), %rax
andl $0xffffefff, -0x280(%rbp,%rax) # imm = 0xFFFFEFFF
movq %r15, %rdi
movq %r12, %rsi
callq 0x32c0
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
movsbl -0x29(%rbp), %esi
jne 0x1a53f
movq %r13, %rdi
callq 0x19a84
jmp 0x1a502
leaq -0x90(%rbp), %rdi
callq 0x19a84
leaq -0x90(%rbp), %rdi
movl $0x3a, 0x20(%rdi)
movq 0x8(%rdi), %rdx
movl $0x1, %ecx
xorl %esi, %esi
xorl %r8d, %r8d
callq 0x3420
leaq -0x90(%rbp), %rdi
callq 0x199e6
leaq -0x298(%rbp), %rdi
callq 0x3070
movq %rbx, %rdi
movq %r14, %rsi
callq 0xf656
movq %r14, %rdi
callq 0xf6fc
leaq -0x90(%rbp), %rdi
callq 0x191f8
leaq -0x298(%rbp), %rdi
callq 0x3080
movq %rbx, %rax
addq $0x278, %rsp            # imm = 0x278
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x1a5c6
movq %rax, %rbx
jmp 0x1a5e4
jmp 0x1a5cd
movq %rax, %rbx
movq %r14, %rdi
callq 0xf6fc
leaq -0x90(%rbp), %rdi
callq 0x191f8
leaq -0x298(%rbp), %rdi
callq 0x3080
movq %rbx, %rdi
callq 0x33f0
// File: /workspace/github_cpp_makefile_star2_O3/tomfunkhouser[P]gaps/apps/scninfo/scninfo.cpp
// Function: PrintElement(gaps::R3SceneElement*, int, int)
static int
PrintElement(R3SceneElement *element, int index, int level)
{
  // Construct indent
  char indent[4096] = { '\0' };
  for (int i = 0; i < level; i++) {
    strcat(indent, "  ");
  }

  // Print element stuff
  R3Box bbox = element->BBox();
  R3Point centroid = element->Centroid();
  R3Material *material = element->Material();
  printf("%sElement %d\n", indent, index);
  printf("%s  # Shapes = %d\n", indent, element->NShapes());
  if (material) printf("%s  Material = %d\n", indent, material->SceneIndex());
  printf("%s  BBox = ( %g %g %g ) ( %g %g %g )\n", indent, bbox[0][0], bbox[0][1], bbox[0][2], bbox[1][0], bbox[1][1], bbox[1][2]);
  printf("%s  Centroid = %g %g %g\n", indent, centroid[0], centroid[1], centroid[2]);
  printf("\n");

  // Return success
  return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x1058, %rsp           # imm = 0x1058
movl %edx, %r14d
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x50(%rsp), %rdi
movl $0x1000, %edx           # imm = 0x1000
xorl %esi, %esi
callq 0x21450
testl %r14d, %r14d
jle 0x26593
leaq 0x50(%rsp), %r15
movq %r15, %rdi
callq 0x21350
movw $0x2020, 0x50(%rsp,%rax) # imm = 0x2020
movb $0x0, 0x52(%rsp,%rax)
decl %r14d
jne 0x2657a
movsd 0x30(%rbx), %xmm0
ucomisd 0xb2a78(%rip), %xmm0    # 0xd9018
jne 0x265ac
jp 0x265ac
movq %rbx, %rdi
callq 0x3c232
leaq 0x28(%rbx), %rsi
leaq 0x18(%rsp), %rdi
callq 0x6b254
movq %rsp, %rdi
movq %rbx, %rsi
callq 0x3bbf0
movq 0x8(%rbx), %r15
leaq 0xb2dcb(%rip), %rdi     # 0xd939b
leaq 0x50(%rsp), %r14
movq %r14, %rsi
movl %ebp, %edx
xorl %eax, %eax
callq 0x21080
movl 0x1c(%rbx), %edx
leaq 0xb2dbe(%rip), %rdi     # 0xd93a9
movq %r14, %rsi
xorl %eax, %eax
callq 0x21080
testq %r15, %r15
je 0x26611
movl 0x8(%r15), %edx
leaq 0xb2db7(%rip), %rdi     # 0xd93bc
leaq 0x50(%rsp), %rsi
xorl %eax, %eax
callq 0x21080
leaq 0x18(%rsp), %rbx
movsd 0x8(%rbx), %xmm0
movsd 0x10(%rbx), %xmm1
movsd 0x18(%rbx), %xmm2
movsd 0x20(%rbx), %xmm3
movsd 0x28(%rbx), %xmm4
movsd 0x30(%rbx), %xmm5
leaq 0xb2c06(%rip), %rdi     # 0xd9241
leaq 0x50(%rsp), %r14
movq %r14, %rsi
movb $0x6, %al
callq 0x21080
movsd (%rsp), %xmm0
movsd 0x8(%rsp), %xmm1
movsd 0x10(%rsp), %xmm2
leaq 0xb2bc6(%rip), %rdi     # 0xd9228
movq %r14, %rsi
movb $0x3, %al
callq 0x21080
movl $0xa, %edi
callq 0x21ca0
movq %rbx, %rdi
callq 0x6c074
addq $0x1058, %rsp           # imm = 0x1058
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x18(%rsp), %rdi
callq 0x6c074
movq %rbx, %rdi
callq 0x22060
// File: /workspace/github_cpp_makefile_star2_O3/ashlall[P]StreamStats/Test/./../SourceCode/ChiSquare/ChiSquareCategorical.cpp
// Function: ChiSquareCategorical::ChiSquareCategorical(double)
ChiSquareCategorical::ChiSquareCategorical(double p)
{
	chi_squared=0;
	stream_size=0;
	percent =p;
	range=pow(2,32);
	num_cat=0;	
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x60(%rdi), %rax
movq %rax, 0x30(%rdi)
movq $0x1, 0x38(%rdi)
xorps %xmm1, %xmm1
movups %xmm1, 0x40(%rdi)
movl $0x3f800000, 0x50(%rdi) # imm = 0x3F800000
movups %xmm1, 0x58(%rdi)
xorl %eax, %eax
movq %rax, (%rdi)
movq %rax, 0x20(%rdi)
movsd %xmm0, 0x10(%rdi)
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, 0x28(%rdi)
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/ashlall[P]StreamStats/Test/./../SourceCode/ChiSquare/ChiSquareCategorical.cpp
// Function: ChiSquareCategorical::insert(double)
void ChiSquareCategorical::insert(double c)
{
	stream_size++;
	HashTable HashA(71);
	long hash_value= HashA.hash(c);
	if(hash_value<((percent/100)*range))
	{	
		if(map.count(hash_value)<1)
		{	
			map.emplace(hash_value,1);
			num_cat++;
		}
		else
		{
			long cat_count=map.at(hash_value);
			cat_count++;
			map.at(hash_value)=cat_count;
		}
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
incl 0x20(%rdi)
cvttsd2si %xmm0, %rax
movl %eax, %ecx
shll $0x8, %ecx
addl %ecx, %eax
addl $0x479ab41d, %eax       # imm = 0x479AB41D
movl %eax, %ecx
shrl $0x5, %ecx
xorl %eax, %ecx
xorl $0xe4aa10ce, %ecx       # imm = 0xE4AA10CE
movl %ecx, %eax
shll $0xe, %eax
negl %eax
addl %ecx, %eax
addl $0x9942f0a6, %eax       # imm = 0x9942F0A6
movl %eax, %ecx
shrl $0x3, %ecx
xorl %eax, %ecx
xorl $0x5aedd67d, %ecx       # imm = 0x5AEDD67D
movl %ecx, %eax
shll $0x7, %eax
addl %ecx, %eax
addl $0x17bea992, %eax       # imm = 0x17BEA992
movq %rax, -0x18(%rbp)
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
movsd 0x10(%rdi), %xmm1
divsd 0x1c0c(%rip), %xmm1     # 0x3008
cvtsi2sdq 0x28(%rdi), %xmm2
mulsd %xmm1, %xmm2
ucomisd %xmm0, %xmm2
jbe 0x1469
movq %rdi, %rbx
leaq 0x30(%rdi), %r14
leaq -0x18(%rbp), %rsi
movq %r14, %rdi
callq 0x2628
testq %rax, %rax
je 0x1450
leaq -0x18(%rbp), %rsi
movq %r14, %rdi
callq 0x2946
testq %rax, %rax
je 0x1472
movl 0x10(%rax), %ebx
leaq -0x18(%rbp), %rsi
movq %r14, %rdi
callq 0x2946
testq %rax, %rax
je 0x1472
incl %ebx
movl %ebx, 0x10(%rax)
jmp 0x1469
leaq -0x1c(%rbp), %rdx
movl $0x1, (%rdx)
leaq -0x18(%rbp), %rsi
movq %r14, %rdi
callq 0x268a
incl 0x24(%rbx)
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x1dc6(%rip), %rdi      # 0x323f
callq 0x1160
// File: /workspace/github_cpp_makefile_star2_O3/ashlall[P]StreamStats/Test/Chi_Square_Categorical_test.cpp
// Function: categorical_test5()
void categorical_test5()
{
		
	ChiSquareCategorical c1(10);
	ChiSquareCategorical c2(10);
	int num_cat=10000;
	int df=0;
	for(int i=0;i<num_cat;i++)
	{
		int v1= (int)(rand() % 250+50);
		int max_dif= 28;
		int v2= v1-max_dif+rand()%(2*max_dif+1);
	
		for(int j=0;j<v1;j++)
			c1.insert(i);
				
		for(int k=0;k<v2;k++)
			c2.insert(i);
	}
	
	
	double chi=c1.calculate_statistic(c2,df);
	cout<<chi<<endl;
	cout<<1-pochisq(chi,df--);
	
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
leaq -0xa8(%rbp), %rax
movq %rax, -0x30(%rax)
movl $0x1, %ecx
movq %rcx, -0x28(%rax)
xorpd %xmm0, %xmm0
movupd %xmm0, -0x20(%rax)
movl $0x3f800000, %edx       # imm = 0x3F800000
movl %edx, -0x10(%rax)
movupd %xmm0, -0x8(%rax)
xorl %ebx, %ebx
movq %rbx, -0x60(%rax)
movq %rbx, -0x40(%rax)
movabsq $0x4024000000000000, %rsi # imm = 0x4024000000000000
movq %rsi, -0x50(%rax)
movabsq $0x100000000, %rdi      # imm = 0x100000000
movq %rdi, -0x38(%rax)
leaq -0x40(%rbp), %rax
movq %rax, -0x30(%rax)
movq %rcx, -0x28(%rax)
movupd %xmm0, -0x20(%rax)
movl %edx, -0x10(%rax)
movupd %xmm0, -0x8(%rax)
movq %rbx, -0x60(%rax)
movq %rbx, -0x40(%rax)
movq %rsi, -0x50(%rax)
movq %rdi, -0x38(%rax)
leaq -0x108(%rbp), %r15
leaq -0xa0(%rbp), %r12
callq 0x1050
movslq %eax, %r14
imulq $0x10624dd3, %r14, %rax # imm = 0x10624DD3
movq %rax, %rcx
shrq $0x3f, %rcx
shrq $0x20, %rax
sarl $0x4, %eax
addl %ecx, %eax
imull $0xfa, %eax, %eax
subl %eax, %r14d
callq 0x1050
movl %eax, -0x2c(%rbp)
xorps %xmm0, %xmm0
cvtsi2sd %ebx, %xmm0
movsd %xmm0, -0x38(%rbp)
cmpl $-0x31, %r14d
jl 0x24a4
leal 0x32(%r14), %r13d
movq %r15, %rdi
movsd -0x38(%rbp), %xmm0
callq 0x1390
decl %r13d
jne 0x2492
movslq -0x2c(%rbp), %rax
imulq $-0x7047dc11, %rax, %rcx # imm = 0x8FB823EF
shrq $0x20, %rcx
addl %eax, %ecx
movl %ecx, %edx
shrl $0x1f, %edx
sarl $0x5, %ecx
addl %edx, %ecx
imull $0x39, %ecx, %ecx
subl %ecx, %eax
addl %eax, %r14d
addl $0x16, %r14d
testl %r14d, %r14d
jle 0x24e2
movq %r12, %rdi
movsd -0x38(%rbp), %xmm0
callq 0x1390
decl %r14d
jne 0x24d0
incl %ebx
cmpl $0x2710, %ebx           # imm = 0x2710
jne 0x244c
leaq -0x108(%rbp), %rdi
leaq -0xa0(%rbp), %rsi
xorl %edx, %edx
callq 0x147e
movq 0x2acc(%rip), %rdi      # 0x4fd8
callq 0x1190
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x1110
movsbl %al, %esi
movq %r15, %rdi
callq 0x1030
movq %rax, %rdi
callq 0x10a0
movq 0x2a96(%rip), %rdi      # 0x4fd8
xorpd %xmm0, %xmm0
callq 0x1190
leaq -0x70(%rbp), %rdi
callq 0x25a4
leaq -0xd8(%rbp), %rdi
callq 0x25a4
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x2576
jmp 0x2576
movq %rax, %r15
leaq -0x70(%rbp), %rdi
callq 0x25a4
leaq -0xd8(%rbp), %rdi
callq 0x25a4
movq %r15, %rdi
callq 0x11c0
// File: /workspace/github_cpp_makefile_star2_O3/FFY00[P]uicc/include/milenage.h
// Function: milenage_f1(unsigned char const*, unsigned char const*, unsigned char const*, unsigned char const*, unsigned char const*, unsigned char*, unsigned char*)
bool milenage_f1(const u8 *opc, const u8 *k, const u8 *_rand,
                 const u8 *sqn, const u8 *amf, u8 *mac_a, u8 *mac_s) {
  u8 tmp1[16], tmp2[16], tmp3[16];
  int i;

  /* tmp1 = TEMP = E_K(RAND XOR OP_C) */
  for (i = 0; i < 16; i++)
    tmp1[i] = _rand[i] ^ opc[i];

  aes_128_encrypt_block(k, tmp1, tmp1);
  /* tmp2 = IN1 = SQN || AMF || SQN || AMF */
  memcpy(tmp2, sqn, 6);
  memcpy(tmp2 + 6, amf, 2);
  memcpy(tmp2 + 8, tmp2, 8);

  /* OUT1 = E_K(TEMP XOR rot(IN1 XOR OP_C, r1) XOR c1) XOR OP_C */

  /* rotate (tmp2 XOR OP_C) by r1 (= 0x40 = 8 bytes) */
  for (i = 0; i < 16; i++)
    tmp3[(i + 8) % 16] = tmp2[i] ^ opc[i];

  /* XOR with TEMP = E_K(RAND XOR OP_C) */
  for (i = 0; i < 16; i++)
    tmp3[i] ^= tmp1[i];

  /* XOR with c1 (= ..00, i.e., NOP) */
  /* f1 || f1* = E_K(tmp3) XOR OP_c */
  aes_128_encrypt_block(k, tmp3, tmp1);

  for (i = 0; i < 16; i++)
    tmp1[i] ^= opc[i];

  if (mac_a)
    memcpy(mac_a, tmp1, 8); /* f1 */

  if (mac_s)
    memcpy(mac_s, tmp1 + 8, 8); /* f1* */

  return true;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %r9, %rbx
movq %r8, %r12
movq %rcx, %r13
movq %rsi, %r15
movq %rdi, %r14
xorl %eax, %eax
movb (%r14,%rax), %cl
xorb (%rdx,%rax), %cl
movb %cl, -0x40(%rbp,%rax)
incq %rax
cmpq $0x10, %rax
jne 0x3f8e
leaq -0x40(%rbp), %rdx
movq %r15, %rdi
movq %rdx, %rsi
callq 0x4053
movzwl 0x4(%r13), %eax
movw %ax, -0x4c(%rbp)
movl (%r13), %eax
movl %eax, -0x50(%rbp)
movzwl (%r12), %eax
movw %ax, -0x4a(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x48(%rbp)
xorl %eax, %eax
movb (%r14,%rax), %cl
xorb -0x50(%rbp,%rax), %cl
movq %rax, %rdx
xorq $0x8, %rdx
movb %cl, -0x60(%rbp,%rdx)
incq %rax
cmpq $0x10, %rax
jne 0x3fd4
xorl %eax, %eax
movb -0x40(%rbp,%rax), %cl
xorb %cl, -0x60(%rbp,%rax)
incq %rax
cmpq $0x10, %rax
jne 0x3ff2
leaq -0x60(%rbp), %rsi
leaq -0x40(%rbp), %rdx
movq %r15, %rdi
callq 0x4053
xorl %eax, %eax
movb (%r14,%rax), %cl
xorb %cl, -0x40(%rbp,%rax)
incq %rax
cmpq $0x10, %rax
jne 0x4015
testq %rbx, %rbx
je 0x4032
movq -0x40(%rbp), %rax
movq %rax, (%rbx)
movq 0x10(%rbp), %rcx
testq %rcx, %rcx
je 0x4042
movq -0x38(%rbp), %rax
movq %rax, (%rcx)
movb $0x1, %al
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/FFY00[P]uicc/include/milenage.h
// Function: milenage_generate(unsigned char const*, unsigned char const*, unsigned char const*, unsigned char const*, unsigned char const*, unsigned char*, unsigned char*, unsigned char*, unsigned char*)
bool milenage_generate(const u8 *opc, const u8 *amf, const u8 *k,
                       const u8 *sqn, const u8 *_rand, u8 *autn, u8 *ik,
                       u8 *ck, u8 *res) {
  int i;
  u8 mac_a[8], ak[6];

  if (!milenage_f1(opc, k, _rand, sqn, amf, mac_a, NULL) ||
      !milenage_f2345(opc, k, _rand, res, ck, ik, ak, NULL))
    return false;

  /* AUTN = (SQN ^ AK) || AMF || MAC */
  for (i = 0; i < 6; i++)
    autn[i] = sqn[i] ^ ak[i];

  memcpy(autn + 6, amf, 2);
  memcpy(autn + 8, mac_a, 8);
  return true;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %r9, %rbx
movq %r8, %rax
movq %r8, -0x38(%rbp)
movq %rcx, %r14
movq %rdx, %r13
movq %rsi, %r8
movq %rdi, %r15
subq $0x8, %rsp
xorl %r12d, %r12d
leaq -0x48(%rbp), %r9
movq %rdx, %rsi
movq %rax, %rdx
movq %r8, -0x40(%rbp)
pushq %r12
callq 0x3f6c
addq $0x10, %rsp
leaq -0x2e(%rbp), %rax
movq %r15, %rdi
movq %r13, %rsi
movq -0x38(%rbp), %rdx
movq 0x20(%rbp), %rcx
movq 0x18(%rbp), %r8
movq 0x10(%rbp), %r9
pushq %r12
pushq %rax
callq 0x43b1
addq $0x10, %rsp
movb -0x2e(%rbp,%r12), %al
xorb (%r14,%r12), %al
movb %al, (%rbx,%r12)
incq %r12
cmpq $0x6, %r12
jne 0x45ba
movq -0x40(%rbp), %rax
movzwl (%rax), %eax
movw %ax, 0x6(%rbx)
movq -0x48(%rbp), %rax
movq %rax, 0x8(%rbx)
movb $0x1, %al
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/FFY00[P]uicc/include/milenage.h
// Function: milenage_opc_gen(unsigned char const*, unsigned char const*, unsigned char*)
void milenage_opc_gen(const u8 *k, const u8 *op, u8 *opc) {
  int i;
  /* Encrypt OP using K */
  aes_128_encrypt_block(k, op, opc);

  /* XOR the resulting Ek(OP) with OP */
  for (i = 0; i < 16; i++)
    opc[i] = opc[i] ^ op[i];
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
callq 0x4053
xorl %eax, %eax
movb (%r14,%rax), %cl
xorb %cl, (%rbx,%rax)
incq %rax
cmpq $0x10, %rax
jne 0x46fa
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/FFY00[P]uicc/include/uicc.h
// Function: UICC::open[abi:cxx11](char*)
string open(char *portname) {
        Assert( (fd=::open(portname, O_RDWR | O_NOCTTY | O_SYNC)) >=0,
                "Failed to open %s", portname);
        struct termios tty;
        Assert (tcgetattr(fd, &tty) >= 0, "");
        tty.c_cflag &= ~( CSIZE );
        tty.c_cflag |= CLOCAL | CREAD | CS8 | PARENB | CSTOPB | HUPCL ;
        /* setup for non-canonical mode */
        tty.c_iflag &= ~(IGNBRK | PARMRK | ISTRIP | INLCR | IGNCR | ICRNL | IXON);
        tty.c_lflag &= ~(ECHO | ECHONL | ICANON | ISIG | IEXTEN);
        tty.c_oflag &= ~OPOST;
        /* fetch bytes as they become available */
        tty.c_cc[VMIN] = 0;
        tty.c_cc[VTIME] = 1;
        cfsetispeed(&tty, (speed_t)B9600);
        cfsetospeed(&tty, (speed_t)B9600);
        Assert (tcsetattr(fd, TCSANOW, &tty) == 0,"");
        // reset the UICC
        int iFlags;
        iFlags = 0 ;
        // turn off DTR
        ioctl(fd, TIOCMSET, &iFlags);
        struct timespec t= {0,1000*1000*100};
        nanosleep(&t,NULL);
        iFlags = 0xFFFF;
        // turn on DTR
        //iFlags = TIOCM_CTS  ;
        //ioctl(fd, TIOCMSET, &iFlags);
        return this->read();
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x58, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq %rdx, %rdi
movl $0x101102, %esi         # imm = 0x101102
xorl %eax, %eax
callq 0x21c0
movl %eax, 0x4(%r14)
testl %eax, %eax
js 0xabe3
leaq -0x6c(%rbp), %rsi
movl %eax, %edi
callq 0x22a0
testl %eax, %eax
js 0xabeb
leaq -0x6c(%rbp), %r15
orl $0xdf0, 0x8(%r15)       # imm = 0xDF0
andl $0xfffffa16, (%r15)     # imm = 0xFFFFFA16
andl $0xffff7fb4, 0xc(%r15)  # imm = 0xFFFF7FB4
andb $-0x2, 0x4(%r15)
movw $0x1, 0x16(%r15)
movq %r15, %rdi
movl $0xd, %esi
callq 0x2160
movq %r15, %rdi
movl $0xd, %esi
callq 0x2290
movl 0x4(%r14), %edi
xorl %esi, %esi
movq %r15, %rdx
callq 0x2330
testl %eax, %eax
jne 0xabf0
leaq -0x1c(%rbp), %r15
movl $0x0, (%r15)
movl 0x4(%r14), %edi
movl $0x5418, %esi           # imm = 0x5418
movq %r15, %rdx
xorl %eax, %eax
callq 0x2350
movups 0xa470(%rip), %xmm0     # 0x15020
leaq -0x30(%rbp), %rdi
movaps %xmm0, (%rdi)
xorl %esi, %esi
callq 0x20c0
movl $0xffff, (%r15)         # imm = 0xFFFF
movl $0x400, %edx            # imm = 0x400
movq %rbx, %rdi
movq %r14, %rsi
callq 0xe17e
movq %rbx, %rax
addq $0x58, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %r15, %rdi
callq 0x24fc
callq 0x256a
callq 0x25ce
nop
// File: /workspace/github_cpp_makefile_star2_O3/FFY00[P]uicc/include/uicc.h
// Function: UICC::decodeIMSI(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
string decodeIMSI(string raw) {
        //int l=raw.c_str()[0];
        string imsi=bcdToAscii(raw.substr(1)); // First byte is length
        //IMSI length bytes, then parity is second byte
        return imsi.substr(1);
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %rdx, %rsi
movq %rdi, %rbx
leaq -0x40(%rbp), %r14
movl $0x1, %edx
movq %r14, %rdi
movq $-0x1, %rcx
callq 0x2270
leaq -0x50(%rbp), %r15
movq %r15, -0x10(%r15)
movq $0x0, -0x8(%r15)
movb $0x0, (%r15)
cmpq $0x0, 0x8(%r14)
je 0xac8a
xorl %r12d, %r12d
leaq -0x60(%rbp), %r14
movq -0x40(%rbp), %rax
movb (%rax,%r12), %al
movl %eax, %ecx
andb $0xf, %cl
orb $0x30, %cl
cmpb $0x39, %cl
ja 0xac6d
movzbl %cl, %esi
movq %r14, %rdi
callq 0x2200
movq -0x40(%rbp), %rax
movb (%rax,%r12), %al
shrb $0x4, %al
orb $0x30, %al
cmpb $0x39, %al
ja 0xac81
movzbl %al, %esi
movq %r14, %rdi
callq 0x2200
incq %r12
cmpq -0x38(%rbp), %r12
jb 0xac45
leaq -0x30(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xac9c
callq 0x2220
leaq -0x60(%rbp), %rsi
movl $0x1, %edx
movq %rbx, %rdi
movq $-0x1, %rcx
callq 0x2270
movq -0x60(%rbp), %rdi
cmpq %r15, %rdi
je 0xacc2
callq 0x2220
movq %rbx, %rax
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq -0x60(%rbp), %rdi
cmpq %r15, %rdi
jne 0xacfe
jmp 0xad03
movq %rax, %rbx
movq -0x60(%rbp), %rdi
cmpq %r15, %rdi
je 0xacf1
callq 0x2220
leaq -0x30(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xad03
callq 0x2220
movq %rbx, %rdi
callq 0x2400
nop
// File: /workspace/github_cpp_makefile_star2_O3/FFY00[P]uicc/include/uicc.h
// Function: UICC::decodeISDN(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
string decodeISDN(string raw) {
        // ISDN is in last 14 bytes
        string isdn=raw.substr(raw.size()-14);
        char isdnLength=isdn[0];
        //char TON=isdn[1]; // should be 0x81
        // two last bytes should be FF (capability , extensions)
        return bcdToAscii(isdn.substr(2,isdnLength));
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rdi, %rbx
movq 0x8(%rdx), %rax
addq $-0xe, %rax
leaq -0x58(%rbp), %r14
movq %r14, %rdi
movq %rdx, %rsi
movq %rax, %rdx
movq $-0x1, %rcx
callq 0x2270
movq (%r14), %rax
movsbq (%rax), %rcx
leaq -0x38(%rbp), %rdi
movl $0x2, %edx
movq %r14, %rsi
callq 0x2270
leaq 0x10(%rbx), %r15
movq %r15, (%rbx)
movq $0x0, 0x8(%rbx)
movb $0x0, 0x10(%rbx)
cmpq $0x0, -0x30(%rbp)
je 0xb3cf
xorl %r14d, %r14d
movq -0x38(%rbp), %rax
movb (%rax,%r14), %al
movl %eax, %ecx
andb $0xf, %cl
orb $0x30, %cl
cmpb $0x39, %cl
ja 0xb3b2
movzbl %cl, %esi
movq %rbx, %rdi
callq 0x2200
movq -0x38(%rbp), %rax
movb (%rax,%r14), %al
shrb $0x4, %al
orb $0x30, %al
cmpb $0x39, %al
ja 0xb3c6
movzbl %al, %esi
movq %rbx, %rdi
callq 0x2200
incq %r14
cmpq -0x30(%rbp), %r14
jb 0xb38a
leaq -0x28(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xb3e1
callq 0x2220
leaq -0x48(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xb3f3
callq 0x2220
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
jmp 0xb428
movq %rax, %r14
movq (%rbx), %rdi
cmpq %r15, %rdi
je 0xb416
callq 0x2220
leaq -0x28(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xb428
callq 0x2220
leaq -0x48(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xb43a
callq 0x2220
movq %r14, %rdi
callq 0x2400
// File: /workspace/github_cpp_makefile_star2_O3/FFY00[P]uicc/include/uicc.h
// Function: UICC::encodeIMSI(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
vector<string> encodeIMSI(string imsi) {
        vector<string> encoded;
        encoded.push_back("");

        if (imsi.size() %2 ==1 ) {
            encoded[0]+=(char)(imsi.size()/2 + 1);
            encoded[0]+=(char)(9 | (imsi[0]-'0')<<4);
        } else {
            encoded[0]+=(char)(imsi.size()/2);
            encoded[0]+=(char)(1 | (imsi[0]-'0')<<4);
        }

        encoded[0]+=makeBcd(imsi.substr(1));
        return encoded;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %rdx, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
leaq -0x30(%rbp), %r15
movq %r15, -0x10(%r15)
leaq 0xbe6e(%rip), %rdx      # 0x183b2
leaq -0x40(%rbp), %rdi
movq %rdx, %rsi
callq 0x139ec
leaq -0x40(%rbp), %rsi
movq %rbx, %rdi
callq 0x13a8a
movq -0x40(%rbp), %rdi
cmpq %r15, %rdi
je 0xc56a
callq 0x2220
movq 0x8(%r14), %rcx
movl %ecx, %eax
shrl %eax
testb $0x1, %cl
jne 0xc587
movq (%rbx), %rdi
movb $0x1, %r12b
movsbl %al, %esi
callq 0x2200
jmp 0xc597
incb %al
movq (%rbx), %rdi
movb $0x9, %r12b
movsbl %al, %esi
callq 0x2200
movq (%r14), %rax
movb (%rax), %al
shlb $0x4, %al
orb %r12b, %al
movq (%rbx), %rdi
movsbl %al, %esi
callq 0x2200
leaq -0x60(%rbp), %rdi
movl $0x1, %edx
movq %r14, %rsi
movq $-0x1, %rcx
callq 0x2270
leaq -0x40(%rbp), %rdi
leaq -0x60(%rbp), %rsi
movl $0x1, %edx
xorl %ecx, %ecx
callq 0x6c9a
movq (%rbx), %rdi
movq -0x40(%rbp), %rsi
movq -0x38(%rbp), %rdx
callq 0x20d0
movq -0x40(%rbp), %rdi
cmpq %r15, %rdi
je 0xc5f7
callq 0x2220
leaq -0x50(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xc609
callq 0x2220
movq %rbx, %rax
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq -0x40(%rbp), %rdi
cmpq %r15, %rdi
je 0xc62f
callq 0x2220
jmp 0xc62f
movq %rax, %r14
leaq -0x50(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
jne 0xc64c
jmp 0xc658
jmp 0xc655
movq %rax, %r14
movq -0x40(%rbp), %rdi
cmpq %r15, %rdi
je 0xc658
callq 0x2220
jmp 0xc658
jmp 0xc655
movq %rax, %r14
movq %rbx, %rdi
callq 0xb2cc
movq %r14, %rdi
callq 0x2400
// File: /workspace/github_cpp_makefile_star2_O3/FFY00[P]uicc/include/uicc.h
// Function: UICC::encodeMccMnc(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, int)
string encodeMccMnc(string Mcc, string Mnc, int len=0) {
        string out;
        out=makeBcd(Mcc);
        out+=makeBcd(Mnc, true, len>2?len-2:0);
        return out;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movl %r8d, %r14d
movq %rcx, %r15
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, -0x30(%rbp)
movq %rax, (%rdi)
movq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
leaq -0x80(%rbp), %r13
movq %r13, -0x10(%r13)
movq (%rdx), %rsi
movq 0x8(%rdx), %rdx
addq %rsi, %rdx
leaq -0x90(%rbp), %rdi
callq 0x1394e
leaq -0x50(%rbp), %rdi
leaq -0x90(%rbp), %rsi
movl $0x1, %edx
xorl %ecx, %ecx
callq 0x6c9a
leaq -0x50(%rbp), %r12
movq %rbx, %rdi
movq %r12, %rsi
callq 0x2320
movq (%r12), %rdi
leaq -0x40(%rbp), %r12
cmpq %r12, %rdi
je 0xc6ef
callq 0x2220
movq -0x90(%rbp), %rdi
cmpq %r13, %rdi
je 0xc700
callq 0x2220
leaq -0x60(%rbp), %r13
movq %r13, -0x10(%r13)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
leaq -0x70(%rbp), %rdi
callq 0x1394e
leal -0x2(%r14), %eax
xorl %ecx, %ecx
cmpl $0x3, %r14d
cmovgel %eax, %ecx
leaq -0x50(%rbp), %rdi
leaq -0x70(%rbp), %rsi
movl $0x1, %edx
callq 0x6c9a
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rdx
movq %rbx, %rdi
callq 0x20d0
movq -0x50(%rbp), %rdi
cmpq %r12, %rdi
je 0xc758
callq 0x2220
movq -0x70(%rbp), %rdi
cmpq %r13, %rdi
je 0xc766
callq 0x2220
movq %rbx, %rax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq -0x50(%rbp), %rdi
cmpq %r12, %rdi
je 0xc78e
callq 0x2220
jmp 0xc78e
movq %rax, %r14
movq -0x70(%rbp), %rdi
jmp 0xc7a0
jmp 0xc7ac
movq %rax, %r14
movq -0x90(%rbp), %rdi
cmpq %r13, %rdi
je 0xc7af
callq 0x2220
jmp 0xc7af
movq %rax, %r14
movq (%rbx), %rdi
cmpq -0x30(%rbp), %rdi
je 0xc7bd
callq 0x2220
movq %r14, %rdi
callq 0x2400
nop
// File: /workspace/github_cpp_makefile_star2_O3/FFY00[P]uicc/include/uicc.h
// Function: UICC::encodeISDN(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, int)
vector<string> encodeISDN(string isdn, int recordLenght) {
        vector<string> encoded;
        encoded.push_back("");

        for (int i=0; i < recordLenght-14 ; i++)
            encoded[0]+='\xff';

        encoded[0]+=makeBcd(isdn).size();
        encoded[0]+='\x81'; //add TON field
        encoded[0]+=makeBcd(isdn);

        for (int i=encoded.size(); i<recordLenght; i++)
            encoded[0]+='\xff';

        return encoded;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movl %ecx, %r14d
movq %rdx, %r15
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
leaq -0x38(%rbp), %r12
movq %r12, -0x10(%r12)
leaq 0xbaf0(%rip), %rdx      # 0x183b2
leaq -0x48(%rbp), %rdi
movq %rdx, %rsi
callq 0x139ec
leaq -0x48(%rbp), %rsi
movq %rbx, %rdi
callq 0x13a8a
movq -0x48(%rbp), %rdi
cmpq %r12, %rdi
je 0xc8e8
callq 0x2220
cmpl $0xf, %r14d
jl 0xc904
leal -0xe(%r14), %r13d
movq (%rbx), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x2200
decl %r13d
jne 0xc8f2
leaq -0x78(%rbp), %r13
movq %r13, -0x10(%r13)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
leaq -0x88(%rbp), %rdi
callq 0x1394e
leaq -0x48(%rbp), %rdi
leaq -0x88(%rbp), %rsi
movl $0x1, %edx
xorl %ecx, %ecx
callq 0x6c9a
movsbl -0x40(%rbp), %esi
movq (%rbx), %rdi
callq 0x2200
movq -0x48(%rbp), %rdi
cmpq %r12, %rdi
je 0xc953
callq 0x2220
movq -0x88(%rbp), %rdi
cmpq %r13, %rdi
je 0xc964
callq 0x2220
movq (%rbx), %rdi
movl $0xffffff81, %esi       # imm = 0xFFFFFF81
callq 0x2200
leaq -0x58(%rbp), %r13
movq %r13, -0x10(%r13)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
leaq -0x68(%rbp), %rdi
callq 0x1394e
leaq -0x48(%rbp), %rdi
leaq -0x68(%rbp), %rsi
movl $0x1, %edx
xorl %ecx, %ecx
callq 0x6c9a
movq (%rbx), %rdi
movq -0x48(%rbp), %rsi
movq -0x40(%rbp), %rdx
callq 0x20d0
movq -0x48(%rbp), %rdi
cmpq %r12, %rdi
je 0xc9be
callq 0x2220
movq -0x68(%rbp), %rdi
cmpq %r13, %rdi
je 0xc9cc
callq 0x2220
movq 0x8(%rbx), %rax
subq (%rbx), %rax
shrq $0x5, %rax
subl %eax, %r14d
jle 0xc9ee
movq (%rbx), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x2200
decl %r14d
jne 0xc9dc
movq %rbx, %rax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq -0x48(%rbp), %rdi
cmpq %r12, %rdi
je 0xca16
callq 0x2220
jmp 0xca16
movq %rax, %r14
movq -0x68(%rbp), %rdi
jmp 0xca3d
jmp 0xca5d
jmp 0xca5d
movq %rax, %r14
movq -0x48(%rbp), %rdi
cmpq %r12, %rdi
je 0xca36
callq 0x2220
jmp 0xca36
movq %rax, %r14
movq -0x88(%rbp), %rdi
cmpq %r13, %rdi
jne 0xca52
jmp 0xca60
jmp 0xca5d
movq %rax, %r14
movq -0x48(%rbp), %rdi
cmpq %r12, %rdi
je 0xca60
callq 0x2220
jmp 0xca60
jmp 0xca5d
jmp 0xca5d
movq %rax, %r14
movq %rbx, %rdi
callq 0xb2cc
movq %r14, %rdi
callq 0x2400
// File: /workspace/github_cpp_makefile_star2_O3/FFY00[P]uicc/include/uicc.h
// Function: USIM::fileRecordSize(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
int fileRecordSize(string filename) {
        openFile(filename);

        if (fileDesc.size() <= 2)
            return -1;

        return fileDesc[3];
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq -0x28(%rbp), %r15
movq %r15, -0x10(%r15)
movq (%rsi), %rax
movq 0x8(%rsi), %rdx
addq %rax, %rdx
leaq -0x38(%rbp), %r14
movq %r14, %rdi
movq %rax, %rsi
callq 0x1394e
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1168e
movq -0x38(%rbp), %rdi
cmpq %r15, %rdi
je 0xd16e
callq 0x2220
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpq $0x3, 0x30(%rbx)
jb 0xd182
movq 0x28(%rbx), %rax
movsbl 0x3(%rax), %eax
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq -0x38(%rbp), %rdi
cmpq %r15, %rdi
je 0xd19e
callq 0x2220
movq %rbx, %rdi
callq 0x2400