// File: RuiDGPires[P]CrimLang/src/generator.cpp
// Function: gc_Tracker::declaration_cas(crl::Node*)
void _gc_Tracker::declaration_cas(crl::Node *node){
	ASSERT(node->get_child(0)->type == crl::Node::Type::LEAF, "Func declaration must have a type as first token");
	ASSERT(node->get_child(1)->type == crl::Node::Type::LEAF, "Func declaration must have a name as second token");
	std::string type = get_token(node->get_child(0)).str;
	std::string name = get_token(node->get_child(1)).str;
	this->current_func_name = name;
	u32 size = size_of(type);

	stream_funcs << name << ":\n"; 
	
	// RESULT SPACE ALLOCATION MUST BE DONE BY CALLER
	
	symb_tracker.frame_offset = size - 1;
	symb_tracker.sp = 0;

	this->stream_funcs << 
		";Function " << name << "\n" <<
		"MOV R7 RF\n" << // TMP STORE RF
		"MOV RF RS\n";

	symb_tracker.push("R7", stream_funcs);
	symb_tracker.push("RE", stream_funcs);


	// Arguents will be stored on the stack like this:
	// foo(a, b, c) -> [a b c]

	// TREAT ARGMENTS
	size_t args_size = 0;
	for(u32 i = 0; i < node->argc; i++){
		crl::Node *arg = node->get_child(2 + i);
		std::string type = get_token(arg->get_child(0)).str;
		std::string name = get_token(arg->get_child(1)).str;

		bool is_mut = arg->annotation == "mut";
		u32 arg_size = is_mut? 1: size_of(type);
		args_size += arg_size;
		
		symb_tracker.arg_create(name, arg_size, is_mut);
	}

	u32 rollback = symb_tracker.frame_offset;	
	this->stream_funcs <<
		"MVI R1 " << rollback << "\n" <<
		"ADD RF R1\n"; // Rollback frame

	crl::Node *block = node->get_child(2+node->argc);
	size_t block_size = block->children.size();
	for (size_t i = 0; i < block_size; i++){
		ASSERT(block->get_child(i)->type == crl::Node::Type::LEAF, "ALL CHILDREN OF CAS DECLARATION MUST BE LEAFS");
		stream_funcs << get_token(block->get_child(i)).str << "\n";
	}

	this->stream_funcs << 
		"; End of function\n" <<
		name << "-end:\n" <<
		"MOV RS RF\n" <<
		"MVI R1 " << args_size + 2 << "\n" <<
		"SUB RS R1\n";
		
	symb_tracker.pop("RE", stream_funcs);
	symb_tracker.pop("RF", stream_funcs);

	this->stream_funcs <<
		"MVI R2 2\n"
		"SUB R1 R2\n" <<
		"ADD RS R1\n" <<
		"RET\n\n";
		// The rest is the result (on stack)
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x4f0, %rsp            # imm = 0x4F0
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x360(%rbp)
movq -0x10(%rbp), %rdi
movq (%rdi), %rax
xorl %esi, %esi
callq *0x18(%rax)
cmpl $0x10, 0x8(%rax)
je 0xdea3
movb $0x1, -0x45(%rbp)
movl $0x50, %edi
callq 0x4190
movq %rax, -0x370(%rbp)
leaq -0x31(%rbp), %rdi
movq %rdi, -0x368(%rbp)
callq 0x4590
movq -0x368(%rbp), %rdx
leaq 0x1d5af(%rip), %rsi     # 0x2b3c6
leaq -0x30(%rbp), %rdi
callq 0x52e0
jmp 0xde22
movq -0x370(%rbp), %rdi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
leaq -0x30(%rbp), %rcx
movl %edx, %esi
callq 0x9140
jmp 0xde3b
movq -0x370(%rbp), %rdi
movb $0x0, -0x45(%rbp)
leaq 0x2bf33(%rip), %rsi     # 0x39d80
leaq -0x4b44(%rip), %rdx     # 0x9310
callq 0x4550
jmp 0xeb46
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0xde81
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x41e0
leaq -0x31(%rbp), %rdi
callq 0x4360
testb $0x1, -0x45(%rbp)
jne 0xde92
jmp 0xde9e
movq -0x370(%rbp), %rdi
callq 0x4230
jmp 0xeb3d
movq -0x10(%rbp), %rdi
movq (%rdi), %rax
movl $0x1, %esi
callq *0x18(%rax)
cmpl $0x10, 0x8(%rax)
je 0xdf7b
movb $0x1, -0x6a(%rbp)
movl $0x50, %edi
callq 0x4190
movq %rax, -0x380(%rbp)
leaq -0x69(%rbp), %rdi
movq %rdi, -0x378(%rbp)
callq 0x4590
movq -0x378(%rbp), %rdx
leaq 0x1d508(%rip), %rsi     # 0x2b3f7
leaq -0x68(%rbp), %rdi
callq 0x52e0
jmp 0xdefa
movq -0x380(%rbp), %rdi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
leaq -0x68(%rbp), %rcx
movl %edx, %esi
callq 0x9140
jmp 0xdf13
movq -0x380(%rbp), %rdi
movb $0x0, -0x6a(%rbp)
leaq 0x2be5b(%rip), %rsi     # 0x39d80
leaq -0x4c1c(%rip), %rdx     # 0x9310
callq 0x4550
jmp 0xeb46
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0xdf59
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x68(%rbp), %rdi
callq 0x41e0
leaq -0x69(%rbp), %rdi
callq 0x4360
testb $0x1, -0x6a(%rbp)
jne 0xdf6a
jmp 0xdf76
movq -0x380(%rbp), %rdi
callq 0x4230
jmp 0xeb3d
movq -0x10(%rbp), %rdi
movq (%rdi), %rax
movq 0x18(%rax), %rax
xorl %esi, %esi
callq *%rax
movq %rax, %rsi
leaq -0xc0(%rbp), %rdi
movq %rdi, -0x390(%rbp)
callq 0xa2e0
movq -0x390(%rbp), %rsi
leaq -0x90(%rbp), %rdi
callq 0x41d0
movq -0x390(%rbp), %rdi
callq 0x285a0
movq -0x10(%rbp), %rdi
movq (%rdi), %rax
movq 0x18(%rax), %rax
movl $0x1, %esi
callq *%rax
movq %rax, -0x388(%rbp)
jmp 0xdfda
movq -0x388(%rbp), %rsi
leaq -0x110(%rbp), %rdi
callq 0xa2e0
jmp 0xdfef
leaq -0xe0(%rbp), %rdi
movq %rdi, -0x398(%rbp)
leaq -0x110(%rbp), %rsi
movq %rsi, -0x3a0(%rbp)
callq 0x41d0
movq -0x3a0(%rbp), %rdi
callq 0x285a0
movq -0x360(%rbp), %rdi
movq -0x398(%rbp), %rsi
addq $0x4a0, %rdi            # imm = 0x4A0
callq 0x4050
jmp 0xe038
leaq -0x138(%rbp), %rdi
leaq -0x90(%rbp), %rsi
callq 0x4150
jmp 0xe04d
leaq -0x138(%rbp), %rdi
callq 0xdc30
movl %eax, -0x3a4(%rbp)
jmp 0xe061
leaq -0x138(%rbp), %rdi
callq 0x41e0
movl -0x3a4(%rbp), %eax
movq -0x360(%rbp), %rdi
movl %eax, -0x114(%rbp)
addq $0x328, %rdi            # imm = 0x328
leaq -0xe0(%rbp), %rsi
callq 0x42c0
movq %rax, -0x3b0(%rbp)
jmp 0xe09c
movq -0x3b0(%rbp), %rdi
leaq 0x1d3fa(%rip), %rsi     # 0x2b4a4
callq 0x42e0
jmp 0xe0b1
movq -0x360(%rbp), %rdi
movl -0x114(%rbp), %eax
decl %eax
movl %eax, 0x5b0(%rdi)
movl $0x0, 0x5ac(%rdi)
addq $0x328, %rdi            # imm = 0x328
leaq 0x1d34b(%rip), %rsi     # 0x2b429
callq 0x42e0
movq %rax, -0x3b8(%rbp)
jmp 0xe0ec
movq -0x3b8(%rbp), %rdi
leaq -0xe0(%rbp), %rsi
callq 0x42c0
movq %rax, -0x3c0(%rbp)
jmp 0xe108
movq -0x3c0(%rbp), %rdi
leaq 0x1d3cd(%rip), %rsi     # 0x2b4e3
callq 0x42e0
movq %rax, -0x3c8(%rbp)
jmp 0xe124
movq -0x3c8(%rbp), %rdi
leaq 0x1d302(%rip), %rsi     # 0x2b434
callq 0x42e0
movq %rax, -0x3d0(%rbp)
jmp 0xe140
movq -0x3d0(%rbp), %rdi
leaq 0x1d2f1(%rip), %rsi     # 0x2b43f
callq 0x42e0
jmp 0xe155
movq -0x360(%rbp), %rax
addq $0x530, %rax            # imm = 0x530
movq %rax, -0x3e0(%rbp)
leaq -0x159(%rbp), %rdi
movq %rdi, -0x3d8(%rbp)
callq 0x4590
movq -0x3d8(%rbp), %rdx
leaq 0x1d2c0(%rip), %rsi     # 0x2b44a
leaq -0x158(%rbp), %rdi
callq 0x52e0
jmp 0xe198
movq -0x3e0(%rbp), %rdi
movq -0x360(%rbp), %rdx
addq $0x318, %rdx            # imm = 0x318
leaq -0x158(%rbp), %rsi
callq 0x13330
jmp 0xe1bb
leaq -0x158(%rbp), %rdi
callq 0x41e0
leaq -0x159(%rbp), %rdi
callq 0x4360
movq -0x360(%rbp), %rax
addq $0x530, %rax            # imm = 0x530
movq %rax, -0x3f0(%rbp)
leaq -0x181(%rbp), %rdi
movq %rdi, -0x3e8(%rbp)
callq 0x4590
movq -0x3e8(%rbp), %rdx
leaq 0x1d245(%rip), %rsi     # 0x2b44d
leaq -0x180(%rbp), %rdi
callq 0x52e0
jmp 0xe216
movq -0x3f0(%rbp), %rdi
movq -0x360(%rbp), %rdx
addq $0x318, %rdx            # imm = 0x318
leaq -0x180(%rbp), %rsi
callq 0x13330
jmp 0xe239
leaq -0x180(%rbp), %rdi
callq 0x41e0
leaq -0x181(%rbp), %rdi
callq 0x4360
movq $0x0, -0x190(%rbp)
movl $0x0, -0x194(%rbp)
movl -0x194(%rbp), %eax
movq -0x10(%rbp), %rcx
cmpl 0x50(%rcx), %eax
jae 0xe5cf
movq -0x10(%rbp), %rdi
movl -0x194(%rbp), %esi
addl $0x2, %esi
movq (%rdi), %rax
movq 0x18(%rax), %rax
callq *%rax
movq %rax, -0x3f8(%rbp)
jmp 0xe298
movq -0x3f8(%rbp), %rax
movq %rax, -0x1a0(%rbp)
movq -0x1a0(%rbp), %rdi
movq (%rdi), %rax
movq 0x18(%rax), %rax
xorl %esi, %esi
callq *%rax
movq %rax, -0x400(%rbp)
jmp 0xe2c1
movq -0x400(%rbp), %rsi
leaq -0x1f0(%rbp), %rdi
callq 0xa2e0
jmp 0xe2d6
leaq -0x1c0(%rbp), %rdi
leaq -0x1f0(%rbp), %rsi
movq %rsi, -0x410(%rbp)
callq 0x41d0
movq -0x410(%rbp), %rdi
callq 0x285a0
movq -0x1a0(%rbp), %rdi
movq (%rdi), %rax
movq 0x18(%rax), %rax
movl $0x1, %esi
callq *%rax
movq %rax, -0x408(%rbp)
jmp 0xe31a
movq -0x408(%rbp), %rsi
leaq -0x240(%rbp), %rdi
callq 0xa2e0
jmp 0xe32f
leaq -0x210(%rbp), %rdi
leaq -0x240(%rbp), %rsi
movq %rsi, -0x420(%rbp)
callq 0x41d0
movq -0x420(%rbp), %rdi
callq 0x285a0
movq -0x1a0(%rbp), %rdi
addq $0x30, %rdi
leaq 0x1d0e9(%rip), %rsi     # 0x2b450
callq 0x66e0
movb %al, -0x411(%rbp)
jmp 0xe374
movb -0x411(%rbp), %al
andb $0x1, %al
movb %al, -0x241(%rbp)
movb -0x241(%rbp), %al
movb $0x0, -0x269(%rbp)
testb $0x1, %al
je 0xe3a0
movl $0x1, %eax
movl %eax, -0x424(%rbp)
jmp 0xe3de
leaq -0x268(%rbp), %rdi
leaq -0x1c0(%rbp), %rsi
callq 0x4150
jmp 0xe3b5
movb $0x1, -0x269(%rbp)
leaq -0x268(%rbp), %rdi
callq 0xdc30
movl %eax, -0x428(%rbp)
jmp 0xe3d0
movl -0x428(%rbp), %eax
movl %eax, -0x424(%rbp)
jmp 0xe3de
movl -0x424(%rbp), %eax
movl %eax, -0x42c(%rbp)
testb $0x1, -0x269(%rbp)
jne 0xe3f5
jmp 0xe401
leaq -0x268(%rbp), %rdi
callq 0x41e0
movq -0x360(%rbp), %rax
movl -0x42c(%rbp), %ecx
movl %ecx, -0x248(%rbp)
movl -0x248(%rbp), %ecx
movl %ecx, %edx
movq -0x190(%rbp), %rcx
addq %rdx, %rcx
movq %rcx, -0x190(%rbp)
addq $0x530, %rax            # imm = 0x530
movq %rax, -0x438(%rbp)
leaq -0x290(%rbp), %rdi
leaq -0x210(%rbp), %rsi
callq 0x4150
jmp 0xe44f
movq -0x438(%rbp), %rdi
movl -0x248(%rbp), %edx
movzbl -0x241(%rbp), %ecx
andl $0x1, %ecx
leaq -0x290(%rbp), %rsi
callq 0x133a0
jmp 0xe474
leaq -0x290(%rbp), %rdi
callq 0x41e0
leaq -0x210(%rbp), %rdi
callq 0x41e0
leaq -0x1c0(%rbp), %rdi
callq 0x41e0
movl -0x194(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x194(%rbp)
jmp 0xe266
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0xeb31
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0xeb25
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x138(%rbp), %rdi
callq 0x41e0
jmp 0xeb25
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0xe511
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x158(%rbp), %rdi
callq 0x41e0
leaq -0x159(%rbp), %rdi
callq 0x4360
jmp 0xeb25
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0xe548
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x180(%rbp), %rdi
callq 0x41e0
leaq -0x181(%rbp), %rdi
callq 0x4360
jmp 0xeb25
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0xe5be
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0xe5b2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
testb $0x1, -0x269(%rbp)
jne 0xe58c
jmp 0xe598
leaq -0x268(%rbp), %rdi
callq 0x41e0
jmp 0xe5b2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x290(%rbp), %rdi
callq 0x41e0
leaq -0x210(%rbp), %rdi
callq 0x41e0
leaq -0x1c0(%rbp), %rdi
callq 0x41e0
jmp 0xeb25
movq -0x360(%rbp), %rdi
movl 0x5b0(%rdi), %eax
movl %eax, -0x294(%rbp)
addq $0x328, %rdi            # imm = 0x328
leaq 0x1cd8d(%rip), %rsi     # 0x2b37d
callq 0x42e0
movq %rax, -0x440(%rbp)
jmp 0xe5fe
movq -0x440(%rbp), %rdi
movl -0x294(%rbp), %esi
callq 0x4420
movq %rax, -0x448(%rbp)
jmp 0xe619
movq -0x448(%rbp), %rdi
leaq 0x1cebc(%rip), %rsi     # 0x2b4e3
callq 0x42e0
movq %rax, -0x450(%rbp)
jmp 0xe635
movq -0x450(%rbp), %rdi
leaq 0x1ce11(%rip), %rsi     # 0x2b454
callq 0x42e0
jmp 0xe64a
movq -0x10(%rbp), %rdi
movl 0x50(%rdi), %esi
addl $0x2, %esi
movq (%rdi), %rax
movq 0x18(%rax), %rax
callq *%rax
movq %rax, -0x458(%rbp)
jmp 0xe666
movq -0x458(%rbp), %rax
movq %rax, -0x2a0(%rbp)
movq -0x2a0(%rbp), %rdi
addq $0x10, %rdi
callq 0x51d0
movq %rax, -0x2a8(%rbp)
movq $0x0, -0x2b0(%rbp)
movq -0x2b0(%rbp), %rax
cmpq -0x2a8(%rbp), %rax
jae 0xe86a
movq -0x2a0(%rbp), %rdi
movl -0x2b0(%rbp), %esi
movq (%rdi), %rax
movq 0x18(%rax), %rax
callq *%rax
movq %rax, -0x460(%rbp)
jmp 0xe6c9
movq -0x460(%rbp), %rax
cmpl $0x10, 0x8(%rax)
je 0xe7b1
movb $0x1, -0x2d2(%rbp)
movl $0x50, %edi
callq 0x4190
movq %rax, -0x470(%rbp)
leaq -0x2d1(%rbp), %rdi
movq %rdi, -0x468(%rbp)
callq 0x4590
movq -0x468(%rbp), %rdx
leaq 0x1cd4c(%rip), %rsi     # 0x2b45f
leaq -0x2d0(%rbp), %rdi
callq 0x52e0
jmp 0xe721
movq -0x470(%rbp), %rdi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
leaq -0x2d0(%rbp), %rcx
movl %edx, %esi
callq 0x9140
jmp 0xe73d
movq -0x470(%rbp), %rdi
movb $0x0, -0x2d2(%rbp)
leaq 0x2b62e(%rip), %rsi     # 0x39d80
leaq -0x5449(%rip), %rdx     # 0x9310
callq 0x4550
jmp 0xeb46
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0xe789
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x2d0(%rbp), %rdi
callq 0x41e0
leaq -0x2d1(%rbp), %rdi
callq 0x4360
testb $0x1, -0x2d2(%rbp)
jne 0xe7a0
jmp 0xe7ac
movq -0x470(%rbp), %rdi
callq 0x4230
jmp 0xeb25
movq -0x360(%rbp), %rax
addq $0x328, %rax            # imm = 0x328
movq %rax, -0x480(%rbp)
movq -0x2a0(%rbp), %rdi
movl -0x2b0(%rbp), %esi
movq (%rdi), %rax
movq 0x18(%rax), %rax
callq *%rax
movq %rax, -0x478(%rbp)
jmp 0xe7e4
movq -0x478(%rbp), %rsi
leaq -0x308(%rbp), %rdi
callq 0xa2e0
jmp 0xe7f9
movq -0x480(%rbp), %rdi
leaq -0x308(%rbp), %rsi
callq 0x42c0
movq %rax, -0x488(%rbp)
jmp 0xe815
movq -0x488(%rbp), %rdi
leaq 0x1ccc0(%rip), %rsi     # 0x2b4e3
callq 0x42e0
jmp 0xe82a
leaq -0x308(%rbp), %rdi
callq 0x285a0
movq -0x2b0(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x2b0(%rbp)
jmp 0xe696
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x308(%rbp), %rdi
callq 0x285a0
jmp 0xeb25
movq -0x360(%rbp), %rdi
addq $0x328, %rdi            # imm = 0x328
leaq 0x1cc0e(%rip), %rsi     # 0x2b48d
callq 0x42e0
movq %rax, -0x490(%rbp)
jmp 0xe88d
movq -0x490(%rbp), %rdi
leaq -0xe0(%rbp), %rsi
callq 0x42c0
movq %rax, -0x498(%rbp)
jmp 0xe8a9
movq -0x498(%rbp), %rdi
leaq 0x1cbe9(%rip), %rsi     # 0x2b4a0
callq 0x42e0
movq %rax, -0x4a0(%rbp)
jmp 0xe8c5
movq -0x4a0(%rbp), %rdi
leaq 0x1cbd4(%rip), %rsi     # 0x2b4a7
callq 0x42e0
movq %rax, -0x4a8(%rbp)
jmp 0xe8e1
movq -0x4a8(%rbp), %rdi
leaq 0x1ca8e(%rip), %rsi     # 0x2b37d
callq 0x42e0
movq %rax, -0x4b0(%rbp)
jmp 0xe8fd
movq -0x4b0(%rbp), %rdi
movq -0x190(%rbp), %rsi
addq $0x2, %rsi
callq 0x40b0
movq %rax, -0x4b8(%rbp)
jmp 0xe91d
movq -0x4b8(%rbp), %rdi
leaq 0x1cbb8(%rip), %rsi     # 0x2b4e3
callq 0x42e0
movq %rax, -0x4c0(%rbp)
jmp 0xe939
movq -0x4c0(%rbp), %rdi
leaq 0x1cb6b(%rip), %rsi     # 0x2b4b2
callq 0x42e0
jmp 0xe94e
movq -0x360(%rbp), %rax
addq $0x530, %rax            # imm = 0x530
movq %rax, -0x4d0(%rbp)
leaq -0x329(%rbp), %rdi
movq %rdi, -0x4c8(%rbp)
callq 0x4590
movq -0x4c8(%rbp), %rdx
leaq 0x1caca(%rip), %rsi     # 0x2b44d
leaq -0x328(%rbp), %rdi
callq 0x52e0
jmp 0xe991
movq -0x4d0(%rbp), %rdi
movq -0x360(%rbp), %rdx
addq $0x318, %rdx            # imm = 0x318
leaq -0x328(%rbp), %rsi
callq 0x13530
jmp 0xe9b4
leaq -0x328(%rbp), %rdi
callq 0x41e0
leaq -0x329(%rbp), %rdi
callq 0x4360
movq -0x360(%rbp), %rax
addq $0x530, %rax            # imm = 0x530
movq %rax, -0x4e0(%rbp)
leaq -0x351(%rbp), %rdi
movq %rdi, -0x4d8(%rbp)
callq 0x4590
movq -0x4d8(%rbp), %rdx
leaq 0x1cabc(%rip), %rsi     # 0x2b4bd
leaq -0x350(%rbp), %rdi
callq 0x52e0
jmp 0xea0f
movq -0x4e0(%rbp), %rdi
movq -0x360(%rbp), %rdx
addq $0x318, %rdx            # imm = 0x318
leaq -0x350(%rbp), %rsi
callq 0x13530
jmp 0xea32
leaq -0x350(%rbp), %rdi
callq 0x41e0
leaq -0x351(%rbp), %rdi
callq 0x4360
movq -0x360(%rbp), %rdi
addq $0x328, %rdi            # imm = 0x328
leaq 0x1ca61(%rip), %rsi     # 0x2b4c0
callq 0x42e0
movq %rax, -0x4e8(%rbp)
jmp 0xea6d
movq -0x4e8(%rbp), %rdi
leaq 0x1ca59(%rip), %rsi     # 0x2b4d4
callq 0x42e0
movq %rax, -0x4f0(%rbp)
jmp 0xea89
movq -0x4f0(%rbp), %rdi
leaq 0x1ca48(%rip), %rsi     # 0x2b4df
callq 0x42e0
jmp 0xea9e
leaq -0xe0(%rbp), %rdi
callq 0x41e0
leaq -0x90(%rbp), %rdi
callq 0x41e0
addq $0x4f0, %rsp            # imm = 0x4F0
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0xeae5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x328(%rbp), %rdi
callq 0x41e0
leaq -0x329(%rbp), %rdi
callq 0x4360
jmp 0xeb25
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0xeb19
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x350(%rbp), %rdi
callq 0x41e0
leaq -0x351(%rbp), %rdi
callq 0x4360
leaq -0xe0(%rbp), %rdi
callq 0x41e0
leaq -0x90(%rbp), %rdi
callq 0x41e0
movq -0x40(%rbp), %rdi
callq 0x4580
nopw %cs:(%rax,%rax)