// File: /workspace/github_c_makefile_star2_O0/System-Glitch[P]ESGILinter-C/src/rules/parsing.c
// Function: parse_and_check
unsigned int parse_and_check(scope_t *root_scope, arraylist_t *file, arraylist_t *functions, arraylist_t *variables, arraylist_t *conf, arraylist_t *real_file) {

	type_t type;
	unsigned int result        = 0;
	unsigned int breaks        = 0;
	scope_t *scope             = NULL;
	char *line                 = NULL;
	char *message              = NULL;
	char *display              = NULL;
	function_t     *function   = NULL;
	field_t        *field      = NULL;
	invalid_call_t *call       = NULL;
	wrong_type_t   *wrong_type = NULL;
	line_t         *line_info  = NULL;
	messages_t     *messages   = malloc(sizeof(messages_t));

	if(messages == NULL) exit(1);

	if(root_scope->parent == NULL) {
		messages->functions_list = arraylist_init(root_scope->functions->size);
		messages->variables_list = arraylist_init(ARRAYLIST_DEFAULT_CAPACITY);
		fill_functions_list(root_scope, messages->functions_list);
		fill_variables_list(root_scope, messages->variables_list);
	} else {
		messages->functions_list = functions;
		messages->variables_list = variables;
	}

	for(int i = root_scope->from_line ; i <= root_scope->to_line ; i++) {
		scope = get_child_scope(root_scope, i);
		if(scope != root_scope) {
			if(i == scope->from_line) {
				result += parse_and_check(scope, file, messages->functions_list, messages->variables_list, conf, real_file);
			}
		} else {
			messages->undeclared_functions = arraylist_init(ARRAYLIST_DEFAULT_CAPACITY);
			messages->undeclared_variables = arraylist_init(ARRAYLIST_DEFAULT_CAPACITY);
			messages->invalid_params       = arraylist_init(ARRAYLIST_DEFAULT_CAPACITY);
			messages->invalid_calls        = arraylist_init(ARRAYLIST_DEFAULT_CAPACITY);
			messages->wrong_assignment     = arraylist_init(ARRAYLIST_DEFAULT_CAPACITY);
			messages->wrong_return         = arraylist_init(ARRAYLIST_DEFAULT_CAPACITY);
			messages->ternary_types        = arraylist_init(ARRAYLIST_DEFAULT_CAPACITY);
			messages->operator_spacing     = arraylist_init(ARRAYLIST_DEFAULT_CAPACITY);

			line_info = get_line(file, i);
			line = line_info->line;
			breaks = strcount_heading_line_breaks(line) + (line_info->start_real_line == 0 ? 1 : 0);
			type = parse_expression(line, i, scope, messages);
			if(!strcmp(type.name, "NULL")) {
				type = parse_operation(line, i, scope, messages);
			}

			if(conf == NULL || check_rule(conf, "undeclared-function")) {
				for(size_t j = 0 ; j < messages->undeclared_functions->size ; j++) {
					function = arraylist_get(messages->undeclared_functions, j);
					message = strconcat("Undeclared function: ", function->name);
					display = trim(arraylist_get(real_file, line_info->start_real_line + breaks - 1));
					print_error(line_info->source, line_info->start_real_line + breaks, display, message);
					free(display);
					free(message);
					result++;
				}
			}

			if(conf == NULL || check_rule(conf, "undeclared-variable")) {
				for(size_t j = 0 ; j < messages->undeclared_variables->size ; j++) {
					message = strconcat("Undeclared variable: ", arraylist_get(messages->undeclared_variables, j));
					display = trim(arraylist_get(real_file, line_info->start_real_line + breaks - 1));
					print_error(line_info->source, line_info->start_real_line + breaks, display, message);
					free(display);
					free(message);
					result++;
				}
			}

			if(conf == NULL || check_rule(conf, "arguments-count")) {
				for(size_t j = 0 ; j < messages->invalid_calls->size ; j++) {
					call = arraylist_get(messages->invalid_calls, j);
					message = strconcat(call->more > 0 ? "Too many arguments for function: " : "Too few arguments for function: ", call->name);
					display = trim(arraylist_get(real_file, line_info->start_real_line + breaks - 1));
					print_error(line_info->source, line_info->start_real_line + breaks, display, message);
					free(display);
					free(message);
					free(call->name);
					result++;
				}
			}

			if(conf == NULL || check_rule(conf, "function-parameters-type")) {
				for(size_t j = 0 ; j < messages->invalid_params->size ; j++) {
					field = arraylist_get(messages->invalid_params, j);
					message = strconcat("Invalid parameter type: ", field->name);
					display = trim(arraylist_get(real_file, line_info->start_real_line + breaks - 1));
					print_error(line_info->source, line_info->start_real_line + breaks, display, message);
					free(display);
					free(message);
					result++;
				}
			}

			if(conf == NULL || check_rule(conf, "variable-assignment-type")) {
				for(size_t j = 0 ; j < messages->wrong_assignment->size ; j++) {
					wrong_type = arraylist_get(messages->wrong_assignment, j);
					message = build_wrong_type_message(wrong_type, WRONG_TYPE_ASSIGNMENT);
					display = trim(arraylist_get(real_file, line_info->start_real_line + breaks - 1));
					print_error(line_info->source, line_info->start_real_line + breaks, display, message);
					free(display);
					free(message);
					result++;
				}
			}

			if(conf == NULL || check_rule(conf, "return-type")) {
				for(size_t j = 0 ; j < messages->wrong_return->size ; j++) {
					wrong_type = arraylist_get(messages->wrong_return, j);
					message = build_wrong_type_message(wrong_type, WRONG_TYPE_RETURN);
					display = trim(arraylist_get(real_file, line_info->start_real_line + breaks - 1));
					print_error(line_info->source, line_info->start_real_line + breaks, display, message);
					free(display);
					free(message);
					result++;
				}
			}

			if(conf == NULL || check_rule(conf, "ternary-types")) {
				for(size_t j = 0 ; j < messages->ternary_types->size ; j++) {
					wrong_type = arraylist_get(messages->ternary_types, j);
					message = build_wrong_type_message(wrong_type, WRONG_TYPE_TERNARY);
					display = trim(arraylist_get(real_file, line_info->start_real_line + breaks - 1));
					print_error(line_info->source, line_info->start_real_line + breaks, display, message);
					free(display);
					free(message);
					result++;
				}
			}

			if(conf == NULL || check_rule(conf, "operators-spacing")) {
				for(size_t j = 0 ; j < messages->operator_spacing->size ; j++) {
					message = strconcat("Missing operator spacing: ", arraylist_get(messages->operator_spacing, j));
					display = trim(arraylist_get(real_file, line_info->start_real_line + breaks - 1));
					print_warning(line_info->source, line_info->start_real_line + breaks, display, message);
					free(display);
					free(message);
					result++;
				}
			}

			function_list_free(messages->undeclared_functions);
			field_list_free(messages->invalid_params);
			arraylist_free(messages->undeclared_variables, 1);
			arraylist_free(messages->invalid_calls, 1);
			arraylist_free(messages->operator_spacing, 1);
			free_wrong_type_list(messages->wrong_assignment);
			free_wrong_type_list(messages->wrong_return);
			free_wrong_type_list(messages->ternary_types);
			free(type.name);

		}
		
	}

	if(root_scope->parent == NULL) {

		if(conf == NULL || check_rule(conf, "unused-variable")) {
			for(size_t j = 0 ; j < messages->variables_list->size ; j++) {
				field = arraylist_get(messages->variables_list, j);
				line_info = get_line(file, field->line);
				message = field->is_param ? strconcat("Unused parameter: ", field->name) : strconcat("Unused variable: ", field->name);
				breaks = strcount_heading_line_breaks(line_info->line) + (line_info->start_real_line == 0 ? 1 : 0);
				display = trim(arraylist_get(real_file, line_info->start_real_line + breaks - 1));
				print_warning(line_info->source, line_info->start_real_line + breaks, display, message);
				free(display);
				free(message);
				result++;
			}
		}

		if(conf == NULL || check_rule(conf, "unused-function")) {
			for(size_t j = 0 ; j < messages->functions_list->size ; j++) {
				function = arraylist_get(messages->functions_list, j);
				line_info = get_line(file, function->line);
				message = strconcat("Unused function: ", function->name);
				breaks = strcount_heading_line_breaks(line_info->line) + (line_info->start_real_line == 0 ? 1 : 0);
				display = trim(arraylist_get(real_file, line_info->start_real_line + breaks - 1));
				print_warning(line_info->source, line_info->start_real_line + breaks, display, message);
				free(display);
				free(message);
				result++;
			}
		}

		arraylist_free(messages->functions_list, 0);
		arraylist_free(messages->variables_list, 0);

		free(messages);
	}

	return result;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x120, %rsp            # imm = 0x120
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movl $0x0, -0x44(%rbp)
movl $0x0, -0x48(%rbp)
movq $0x0, -0x50(%rbp)
movq $0x0, -0x58(%rbp)
movq $0x0, -0x60(%rbp)
movq $0x0, -0x68(%rbp)
movq $0x0, -0x70(%rbp)
movq $0x0, -0x78(%rbp)
movq $0x0, -0x80(%rbp)
movq $0x0, -0x88(%rbp)
movq $0x0, -0x90(%rbp)
movl $0x50, %edi
callq 0x2110
movq %rax, -0x98(%rbp)
cmpq $0x0, -0x98(%rbp)
jne 0xdb04
movl $0x1, %edi
callq 0x2170
movq -0x8(%rbp), %rax
cmpq $0x0, (%rax)
jne 0xdb71
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movq 0x8(%rax), %rax
movl %eax, %edi
callq 0x8580
movq %rax, %rcx
movq -0x98(%rbp), %rax
movq %rcx, 0x48(%rax)
movl $0xa, %edi
callq 0x8580
movq %rax, %rcx
movq -0x98(%rbp), %rax
movq %rcx, 0x40(%rax)
movq -0x8(%rbp), %rdi
movq -0x98(%rbp), %rax
movq 0x48(%rax), %rsi
callq 0xe960
movq -0x8(%rbp), %rdi
movq -0x98(%rbp), %rax
movq 0x40(%rax), %rsi
callq 0xe9f0
jmp 0xdb8f
movq -0x18(%rbp), %rcx
movq -0x98(%rbp), %rax
movq %rcx, 0x48(%rax)
movq -0x20(%rbp), %rcx
movq -0x98(%rbp), %rax
movq %rcx, 0x40(%rax)
movq -0x8(%rbp), %rax
movl 0x20(%rax), %eax
movl %eax, -0x9c(%rbp)
movl -0x9c(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl 0x28(%rcx), %eax
jg 0xe656
movq -0x8(%rbp), %rdi
movl -0x9c(%rbp), %esi
callq 0xeaa0
movq %rax, -0x50(%rbp)
movq -0x50(%rbp), %rax
cmpq -0x8(%rbp), %rax
je 0xdc11
movl -0x9c(%rbp), %eax
movq -0x50(%rbp), %rcx
cmpl 0x20(%rcx), %eax
jne 0xdc0c
movq -0x50(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x98(%rbp), %rax
movq 0x48(%rax), %rdx
movq -0x98(%rbp), %rax
movq 0x40(%rax), %rcx
movq -0x28(%rbp), %r8
movq -0x30(%rbp), %r9
callq 0xda60
addl -0x44(%rbp), %eax
movl %eax, -0x44(%rbp)
jmp 0xe640
movl $0xa, %edi
callq 0x8580
movq %rax, %rcx
movq -0x98(%rbp), %rax
movq %rcx, 0x8(%rax)
movl $0xa, %edi
callq 0x8580
movq %rax, %rcx
movq -0x98(%rbp), %rax
movq %rcx, (%rax)
movl $0xa, %edi
callq 0x8580
movq %rax, %rcx
movq -0x98(%rbp), %rax
movq %rcx, 0x10(%rax)
movl $0xa, %edi
callq 0x8580
movq %rax, %rcx
movq -0x98(%rbp), %rax
movq %rcx, 0x18(%rax)
movl $0xa, %edi
callq 0x8580
movq %rax, %rcx
movq -0x98(%rbp), %rax
movq %rcx, 0x20(%rax)
movl $0xa, %edi
callq 0x8580
movq %rax, %rcx
movq -0x98(%rbp), %rax
movq %rcx, 0x28(%rax)
movl $0xa, %edi
callq 0x8580
movq %rax, %rcx
movq -0x98(%rbp), %rax
movq %rcx, 0x30(%rax)
movl $0xa, %edi
callq 0x8580
movq %rax, %rcx
movq -0x98(%rbp), %rax
movq %rcx, 0x38(%rax)
movq -0x10(%rbp), %rdi
movl -0x9c(%rbp), %esi
callq 0x2cb0
movq %rax, -0x90(%rbp)
movq -0x90(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rdi
callq 0xa840
movq -0x90(%rbp), %rcx
movl 0x10(%rcx), %esi
xorl %ecx, %ecx
movl $0x1, %edx
cmpl $0x0, %esi
cmovel %edx, %ecx
addl %ecx, %eax
movl %eax, -0x48(%rbp)
movq -0x58(%rbp), %rdi
movl -0x9c(%rbp), %esi
movq -0x50(%rbp), %rdx
movq -0x98(%rbp), %rcx
callq 0x10120
movq %rax, -0xb0(%rbp)
movq %rdx, -0xa8(%rbp)
movq -0xb0(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0xa8(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x40(%rbp), %rdi
leaq 0x6b3e(%rip), %rsi      # 0x148a0
callq 0x20f0
cmpl $0x0, %eax
jne 0xddaa
movq -0x58(%rbp), %rdi
movl -0x9c(%rbp), %esi
movq -0x50(%rbp), %rdx
movq -0x98(%rbp), %rcx
callq 0x8fe0
movq %rax, -0xc0(%rbp)
movq %rdx, -0xb8(%rbp)
movq -0xc0(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0xb8(%rbp), %rax
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x28(%rbp)
je 0xddcd
movq -0x28(%rbp), %rdi
leaq 0x6c7f(%rip), %rsi      # 0x14a3b
callq 0x75b0
movzbl %al, %eax
cmpl $0x0, %eax
je 0xdea8
movq $0x0, -0xc8(%rbp)
movq -0xc8(%rbp), %rax
movq -0x98(%rbp), %rcx
movq 0x8(%rcx), %rcx
cmpq 0x8(%rcx), %rax
jae 0xdea6
movq -0x98(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0xc8(%rbp), %rsi
callq 0x8890
movq %rax, -0x70(%rbp)
movq -0x70(%rbp), %rax
movq (%rax), %rsi
leaq 0x6c32(%rip), %rdi      # 0x14a4f
callq 0xa9b0
movq %rax, -0x60(%rbp)
movq -0x30(%rbp), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %eax
addl -0x48(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x8890
movq %rax, %rdi
callq 0xad00
movq %rax, -0x68(%rbp)
movq -0x90(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %esi
addl -0x48(%rbp), %esi
movq -0x68(%rbp), %rdx
movq -0x60(%rbp), %rcx
callq 0x6950
movq -0x68(%rbp), %rdi
callq 0x2030
movq -0x60(%rbp), %rdi
callq 0x2030
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
movq -0xc8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xc8(%rbp)
jmp 0xddd8
jmp 0xdea8
cmpq $0x0, -0x28(%rbp)
je 0xdecb
movq -0x28(%rbp), %rdi
leaq 0x6bab(%rip), %rsi      # 0x14a65
callq 0x75b0
movzbl %al, %eax
cmpl $0x0, %eax
je 0xdf9c
movq $0x0, -0xd0(%rbp)
movq -0xd0(%rbp), %rax
movq -0x98(%rbp), %rcx
movq (%rcx), %rcx
cmpq 0x8(%rcx), %rax
jae 0xdf9a
movq -0x98(%rbp), %rax
movq (%rax), %rdi
movq -0xd0(%rbp), %rsi
callq 0x8890
movq %rax, %rsi
leaq 0x6b68(%rip), %rdi      # 0x14a79
callq 0xa9b0
movq %rax, -0x60(%rbp)
movq -0x30(%rbp), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %eax
addl -0x48(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x8890
movq %rax, %rdi
callq 0xad00
movq %rax, -0x68(%rbp)
movq -0x90(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %esi
addl -0x48(%rbp), %esi
movq -0x68(%rbp), %rdx
movq -0x60(%rbp), %rcx
callq 0x6950
movq -0x68(%rbp), %rdi
callq 0x2030
movq -0x60(%rbp), %rdi
callq 0x2030
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
movq -0xd0(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xd0(%rbp)
jmp 0xded6
jmp 0xdf9c
cmpq $0x0, -0x28(%rbp)
je 0xdfbf
movq -0x28(%rbp), %rdi
leaq 0x6ae1(%rip), %rsi      # 0x14a8f
callq 0x75b0
movzbl %al, %eax
cmpl $0x0, %eax
je 0xe0bb
movq $0x0, -0xd8(%rbp)
movq -0xd8(%rbp), %rax
movq -0x98(%rbp), %rcx
movq 0x18(%rcx), %rcx
cmpq 0x8(%rcx), %rax
jae 0xe0b9
movq -0x98(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0xd8(%rbp), %rsi
callq 0x8890
movq %rax, -0x80(%rbp)
movq -0x80(%rbp), %rax
movl 0x8(%rax), %ecx
leaq 0x6ab2(%rip), %rdi      # 0x14ac1
leaq 0x6a89(%rip), %rax      # 0x14a9f
cmpl $0x0, %ecx
cmovgq %rax, %rdi
movq -0x80(%rbp), %rax
movq (%rax), %rsi
callq 0xa9b0
movq %rax, -0x60(%rbp)
movq -0x30(%rbp), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %eax
addl -0x48(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x8890
movq %rax, %rdi
callq 0xad00
movq %rax, -0x68(%rbp)
movq -0x90(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %esi
addl -0x48(%rbp), %esi
movq -0x68(%rbp), %rdx
movq -0x60(%rbp), %rcx
callq 0x6950
movq -0x68(%rbp), %rdi
callq 0x2030
movq -0x60(%rbp), %rdi
callq 0x2030
movq -0x80(%rbp), %rax
movq (%rax), %rdi
callq 0x2030
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
movq -0xd8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xd8(%rbp)
jmp 0xdfca
jmp 0xe0bb
cmpq $0x0, -0x28(%rbp)
je 0xe0de
movq -0x28(%rbp), %rdi
leaq 0x6a15(%rip), %rsi      # 0x14ae2
callq 0x75b0
movzbl %al, %eax
cmpl $0x0, %eax
je 0xe1b9
movq $0x0, -0xe0(%rbp)
movq -0xe0(%rbp), %rax
movq -0x98(%rbp), %rcx
movq 0x10(%rcx), %rcx
cmpq 0x8(%rcx), %rax
jae 0xe1b7
movq -0x98(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0xe0(%rbp), %rsi
callq 0x8890
movq %rax, -0x78(%rbp)
movq -0x78(%rbp), %rax
movq (%rax), %rsi
leaq 0x69cd(%rip), %rdi      # 0x14afb
callq 0xa9b0
movq %rax, -0x60(%rbp)
movq -0x30(%rbp), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %eax
addl -0x48(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x8890
movq %rax, %rdi
callq 0xad00
movq %rax, -0x68(%rbp)
movq -0x90(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %esi
addl -0x48(%rbp), %esi
movq -0x68(%rbp), %rdx
movq -0x60(%rbp), %rcx
callq 0x6950
movq -0x68(%rbp), %rdi
callq 0x2030
movq -0x60(%rbp), %rdi
callq 0x2030
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
movq -0xe0(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xe0(%rbp)
jmp 0xe0e9
jmp 0xe1b9
cmpq $0x0, -0x28(%rbp)
je 0xe1dc
movq -0x28(%rbp), %rdi
leaq 0x6949(%rip), %rsi      # 0x14b14
callq 0x75b0
movzbl %al, %eax
cmpl $0x0, %eax
je 0xe2b5
movq $0x0, -0xe8(%rbp)
movq -0xe8(%rbp), %rax
movq -0x98(%rbp), %rcx
movq 0x20(%rcx), %rcx
cmpq 0x8(%rcx), %rax
jae 0xe2b3
movq -0x98(%rbp), %rax
movq 0x20(%rax), %rdi
movq -0xe8(%rbp), %rsi
callq 0x8890
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rdi
xorl %esi, %esi
callq 0xeaf0
movq %rax, -0x60(%rbp)
movq -0x30(%rbp), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %eax
addl -0x48(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x8890
movq %rax, %rdi
callq 0xad00
movq %rax, -0x68(%rbp)
movq -0x90(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %esi
addl -0x48(%rbp), %esi
movq -0x68(%rbp), %rdx
movq -0x60(%rbp), %rcx
callq 0x6950
movq -0x68(%rbp), %rdi
callq 0x2030
movq -0x60(%rbp), %rdi
callq 0x2030
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
movq -0xe8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xe8(%rbp)
jmp 0xe1e7
jmp 0xe2b5
cmpq $0x0, -0x28(%rbp)
je 0xe2d8
movq -0x28(%rbp), %rdi
leaq 0x6866(%rip), %rsi      # 0x14b2d
callq 0x75b0
movzbl %al, %eax
cmpl $0x0, %eax
je 0xe3b4
movq $0x0, -0xf0(%rbp)
movq -0xf0(%rbp), %rax
movq -0x98(%rbp), %rcx
movq 0x28(%rcx), %rcx
cmpq 0x8(%rcx), %rax
jae 0xe3b2
movq -0x98(%rbp), %rax
movq 0x28(%rax), %rdi
movq -0xf0(%rbp), %rsi
callq 0x8890
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rdi
movl $0x1, %esi
callq 0xeaf0
movq %rax, -0x60(%rbp)
movq -0x30(%rbp), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %eax
addl -0x48(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x8890
movq %rax, %rdi
callq 0xad00
movq %rax, -0x68(%rbp)
movq -0x90(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %esi
addl -0x48(%rbp), %esi
movq -0x68(%rbp), %rdx
movq -0x60(%rbp), %rcx
callq 0x6950
movq -0x68(%rbp), %rdi
callq 0x2030
movq -0x60(%rbp), %rdi
callq 0x2030
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
movq -0xf0(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xf0(%rbp)
jmp 0xe2e3
jmp 0xe3b4
cmpq $0x0, -0x28(%rbp)
je 0xe3d7
movq -0x28(%rbp), %rdi
leaq 0x6773(%rip), %rsi      # 0x14b39
callq 0x75b0
movzbl %al, %eax
cmpl $0x0, %eax
je 0xe4b3
movq $0x0, -0xf8(%rbp)
movq -0xf8(%rbp), %rax
movq -0x98(%rbp), %rcx
movq 0x30(%rcx), %rcx
cmpq 0x8(%rcx), %rax
jae 0xe4b1
movq -0x98(%rbp), %rax
movq 0x30(%rax), %rdi
movq -0xf8(%rbp), %rsi
callq 0x8890
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rdi
movl $0x2, %esi
callq 0xeaf0
movq %rax, -0x60(%rbp)
movq -0x30(%rbp), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %eax
addl -0x48(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x8890
movq %rax, %rdi
callq 0xad00
movq %rax, -0x68(%rbp)
movq -0x90(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %esi
addl -0x48(%rbp), %esi
movq -0x68(%rbp), %rdx
movq -0x60(%rbp), %rcx
callq 0x6950
movq -0x68(%rbp), %rdi
callq 0x2030
movq -0x60(%rbp), %rdi
callq 0x2030
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
movq -0xf8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0xf8(%rbp)
jmp 0xe3e2
jmp 0xe4b3
cmpq $0x0, -0x28(%rbp)
je 0xe4d6
movq -0x28(%rbp), %rdi
leaq 0x6682(%rip), %rsi      # 0x14b47
callq 0x75b0
movzbl %al, %eax
cmpl $0x0, %eax
je 0xe5a9
movq $0x0, -0x100(%rbp)
movq -0x100(%rbp), %rax
movq -0x98(%rbp), %rcx
movq 0x38(%rcx), %rcx
cmpq 0x8(%rcx), %rax
jae 0xe5a7
movq -0x98(%rbp), %rax
movq 0x38(%rax), %rdi
movq -0x100(%rbp), %rsi
callq 0x8890
movq %rax, %rsi
leaq 0x663b(%rip), %rdi      # 0x14b59
callq 0xa9b0
movq %rax, -0x60(%rbp)
movq -0x30(%rbp), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %eax
addl -0x48(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x8890
movq %rax, %rdi
callq 0xad00
movq %rax, -0x68(%rbp)
movq -0x90(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %esi
addl -0x48(%rbp), %esi
movq -0x68(%rbp), %rdx
movq -0x60(%rbp), %rcx
callq 0x6850
movq -0x68(%rbp), %rdi
callq 0x2030
movq -0x60(%rbp), %rdi
callq 0x2030
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
movq -0x100(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x100(%rbp)
jmp 0xe4e1
jmp 0xe5a9
movq -0x98(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x8230
movq -0x98(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x81d0
movq -0x98(%rbp), %rax
movq (%rax), %rdi
movl $0x1, %esi
callq 0x8a00
movq -0x98(%rbp), %rax
movq 0x18(%rax), %rdi
movl $0x1, %esi
callq 0x8a00
movq -0x98(%rbp), %rax
movq 0x38(%rax), %rdi
movl $0x1, %esi
callq 0x8a00
movq -0x98(%rbp), %rax
movq 0x20(%rax), %rdi
callq 0xec20
movq -0x98(%rbp), %rax
movq 0x28(%rax), %rdi
callq 0xec20
movq -0x98(%rbp), %rax
movq 0x30(%rax), %rdi
callq 0xec20
movq -0x40(%rbp), %rdi
callq 0x2030
jmp 0xe642
movl -0x9c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x9c(%rbp)
jmp 0xdb9c
movq -0x8(%rbp), %rax
cmpq $0x0, (%rax)
jne 0xe94b
cmpq $0x0, -0x28(%rbp)
je 0xe687
movq -0x28(%rbp), %rdi
leaq 0x64fe(%rip), %rsi      # 0x14b74
callq 0x75b0
movzbl %al, %eax
cmpl $0x0, %eax
je 0xe7db
movq $0x0, -0x108(%rbp)
movq -0x108(%rbp), %rax
movq -0x98(%rbp), %rcx
movq 0x40(%rcx), %rcx
cmpq 0x8(%rcx), %rax
jae 0xe7d9
movq -0x98(%rbp), %rax
movq 0x40(%rax), %rdi
movq -0x108(%rbp), %rsi
callq 0x8890
movq %rax, -0x78(%rbp)
movq -0x10(%rbp), %rdi
movq -0x78(%rbp), %rax
movl 0x20(%rax), %esi
callq 0x2cb0
movq %rax, -0x90(%rbp)
movq -0x78(%rbp), %rax
movzbl 0x24(%rax), %eax
cmpl $0x0, %eax
je 0xe709
movq -0x78(%rbp), %rax
movq (%rax), %rsi
leaq 0x6489(%rip), %rdi      # 0x14b84
callq 0xa9b0
movq %rax, -0x118(%rbp)
jmp 0xe723
movq -0x78(%rbp), %rax
movq (%rax), %rsi
leaq 0x6480(%rip), %rdi      # 0x14b97
callq 0xa9b0
movq %rax, -0x118(%rbp)
movq -0x118(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0x90(%rbp), %rax
movq (%rax), %rdi
callq 0xa840
movq -0x90(%rbp), %rcx
movl 0x10(%rcx), %esi
xorl %ecx, %ecx
movl $0x1, %edx
cmpl $0x0, %esi
cmovel %edx, %ecx
addl %ecx, %eax
movl %eax, -0x48(%rbp)
movq -0x30(%rbp), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %eax
addl -0x48(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x8890
movq %rax, %rdi
callq 0xad00
movq %rax, -0x68(%rbp)
movq -0x90(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %esi
addl -0x48(%rbp), %esi
movq -0x68(%rbp), %rdx
movq -0x60(%rbp), %rcx
callq 0x6850
movq -0x68(%rbp), %rdi
callq 0x2030
movq -0x60(%rbp), %rdi
callq 0x2030
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
movq -0x108(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x108(%rbp)
jmp 0xe692
jmp 0xe7db
cmpq $0x0, -0x28(%rbp)
je 0xe7fe
movq -0x28(%rbp), %rdi
leaq 0x63bc(%rip), %rsi      # 0x14ba9
callq 0x75b0
movzbl %al, %eax
cmpl $0x0, %eax
je 0xe91b
movq $0x0, -0x110(%rbp)
movq -0x110(%rbp), %rax
movq -0x98(%rbp), %rcx
movq 0x48(%rcx), %rcx
cmpq 0x8(%rcx), %rax
jae 0xe919
movq -0x98(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x110(%rbp), %rsi
callq 0x8890
movq %rax, -0x70(%rbp)
movq -0x10(%rbp), %rdi
movq -0x70(%rbp), %rax
movl 0x28(%rax), %esi
callq 0x2cb0
movq %rax, -0x90(%rbp)
movq -0x70(%rbp), %rax
movq (%rax), %rsi
leaq 0x6354(%rip), %rdi      # 0x14bb9
callq 0xa9b0
movq %rax, -0x60(%rbp)
movq -0x90(%rbp), %rax
movq (%rax), %rdi
callq 0xa840
movq -0x90(%rbp), %rcx
movl 0x10(%rcx), %esi
xorl %ecx, %ecx
movl $0x1, %edx
cmpl $0x0, %esi
cmovel %edx, %ecx
addl %ecx, %eax
movl %eax, -0x48(%rbp)
movq -0x30(%rbp), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %eax
addl -0x48(%rbp), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x8890
movq %rax, %rdi
callq 0xad00
movq %rax, -0x68(%rbp)
movq -0x90(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x90(%rbp), %rax
movl 0x10(%rax), %esi
addl -0x48(%rbp), %esi
movq -0x68(%rbp), %rdx
movq -0x60(%rbp), %rcx
callq 0x6850
movq -0x68(%rbp), %rdi
callq 0x2030
movq -0x60(%rbp), %rdi
callq 0x2030
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
movq -0x110(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x110(%rbp)
jmp 0xe809
jmp 0xe91b
movq -0x98(%rbp), %rax
movq 0x48(%rax), %rdi
xorl %esi, %esi
callq 0x8a00
movq -0x98(%rbp), %rax
movq 0x40(%rax), %rdi
xorl %esi, %esi
callq 0x8a00
movq -0x98(%rbp), %rdi
callq 0x2030
movl -0x44(%rbp), %eax
addq $0x120, %rsp            # imm = 0x120
popq %rbp
retq
nopw (%rax,%rax)