// File: /workspace/github_c_makefile_star2_O0/hsjoihs[P]c-compiler/typecheck_expression.c
// Function: typecheck_binary_expression
struct Expr typecheck_binary_expression(const struct AnalyzerState *ptr_ps,
                                        const struct Expr *ref_expr,
                                        const struct Expr *ref_expr2,
                                        enum TokenKind op)
{
	const struct Expr expr = *ref_expr;
	const struct Expr expr2 = *ref_expr2;

	if (isAssign(op)) {
		if (expr.details.type.type_category == ARRAY ||
		    (expr.details.type.type_category == PTR_ &&
		     expr.details.true_type.type_category == ARRAY)) {
			fprintf(stderr, "array is not an lvalue\n");
			exit(EXIT_FAILURE);
		}

		struct Expr new_expr;
		new_expr.details = expr.details;
		struct Expr *ptr_expr1 = calloc(1, sizeof(struct Expr));
		struct Expr *ptr_expr2 = calloc(1, sizeof(struct Expr));
		*ptr_expr1 = expr;
		new_expr.ptr1 = ptr_expr1;
		new_expr.ptr3 = 0;

		if (op == OP_EQ) {
			struct Expr expr2_new = expr2;

			if (expr.details.type.type_category == PTR_) {
				/* automatically convert function name to function pointer */
				if_function_cast_to_pointer(&expr2_new);
				cast_to_null_pointer_if_possible(&expr2_new, &expr.details);
			}

			expect_type(ptr_ps, &expr2_new.details.type, &expr.details.type,
			            "mismatch in assignment operator");

			*ptr_expr2 = expr2_new;
			new_expr.ptr2 = ptr_expr2;

			if (is_struct_or_union(&expr.details.type)) {
				new_expr.category = STRUCT_OR_UNION_ASSIGNMENT_EXPR;
				new_expr.size_info_for_struct_or_union_assign =
				    size_of(ptr_ps, &expr.details.type);
			} else {
				new_expr.category = ASSIGNMENT_EXPR;
			}
			return new_expr;
		}

		/* op != OP_EQ */
		if (is_struct_or_union(&expr.details.type)) {
			fprintf(stderr, "invalid compound assignment operator used on a "
			                "value of type `");
			debug_print_type(&expr.details.type);
			fprintf(stderr, "`\n");
			exit(EXIT_FAILURE);
		}

		if (expr.details.type.type_category == PTR_ &&
		    (op == OP_PLUS_EQ || op == OP_MINUS_EQ)) {

			expect_integral(&expr2.details.type,
			                "right side of += or -= to a pointer");

			*ptr_expr2 = expr2;

			new_expr.category = COMPOUND_ASSIGNMENT_EXPR;
			new_expr.simple_binary_operator = op_before_assign(op);

			new_expr.ptr2 = ptr_expr2;

			const struct Type deref = deref_type(&expr.details.type);
			new_expr.size_info_for_pointer_arith = size_of(ptr_ps, &deref);

			return new_expr;
		}

		if (expr.details.type.type_category == PTR_) {
			fprintf(stderr, "invalid compound assignment operator "
			                "used on a pointer\n");
			exit(EXIT_FAILURE);
		}

		expect_type(ptr_ps, &expr.details.type, &expr2.details.type,
		            "mismatch in assignment operator");

		*ptr_expr2 = expr2;

		new_expr.category = COMPOUND_ASSIGNMENT_EXPR;
		new_expr.simple_binary_operator = op_before_assign(op);

		new_expr.ptr2 = ptr_expr2;

		if (expr.details.type.type_category == PTR_ &&
		    (op == OP_PLUS_EQ || op == OP_MINUS_EQ)) {
			const struct Type deref = deref_type(&expr.details.type);
			new_expr.size_info_for_pointer_arith = size_of(ptr_ps, &deref);
		}

		return new_expr;
	}

	switch (op) {
	case OP_PLUS: {
		const struct Type type1 = expr.details.type;
		const struct Type type2 = expr2.details.type;

		if (is_integral(&type1)) {
			if (is_integral(&type2)) {
				const struct Type t = INT_TYPE();
				return simple_binary_op(&expr, &expr2, OP_PLUS, &t);
			} else if (type2.type_category == PTR_) {
				/* swapped */
				return pointer_plusorminus_int(ptr_ps, &expr2, &expr, OP_PLUS);
			} else {
				fprintf(stderr, "invalid type `");
				debug_print_type(&type2);
				fprintf(stderr, "` as the right operand of a binary +\n");
				exit(EXIT_FAILURE);
			}
		} else if (type1.type_category == PTR_) {
			expect_integral(&expr2.details.type,
			                "cannot add a pointer/struct to a pointer");
			return pointer_plusorminus_int(ptr_ps, &expr, &expr2, OP_PLUS);
		} else {
			fprintf(stderr, "invalid type `");
			debug_print_type(&type1);
			fprintf(stderr, "`as the left operand of binary +\n");
			exit(EXIT_FAILURE);
		}
	}
	case OP_MINUS: {

		struct Type type1 = expr.details.type;
		struct Type type2 = expr2.details.type;

		if (is_integral(&type1)) {
			if (is_integral(&type2)) {
				const struct Type t = INT_TYPE();
				return simple_binary_op(&expr, &expr2, OP_MINUS, &t);
			} else if (type2.type_category == PTR_) {

				fprintf(stderr, "cannot subtract a pointer "
				                "from an integer.\n");
				exit(EXIT_FAILURE);
			} else {
				fprintf(stderr, "invalid type `");
				debug_print_type(&type2);
				fprintf(stderr, "` as the right operand of a binary -\n");
				exit(EXIT_FAILURE);
			}

		} else if (type1.type_category == PTR_) {
			if (is_integral(&type2)) {

				/* pointer minus int */
				return pointer_plusorminus_int(ptr_ps, &expr, &expr2, OP_MINUS);
			} else {
				/* pointer minus pointer */

				struct Expr *ptr_expr1 = calloc(1, sizeof(struct Expr));
				struct Expr *ptr_expr2 = calloc(1, sizeof(struct Expr));
				*ptr_expr1 = expr;
				*ptr_expr2 = expr2;

				struct Expr new_expr;
				new_expr.details.type = INT_TYPE();
				new_expr.details.true_type = INT_TYPE();
				new_expr.category = POINTER_MINUS_POINTER;
				new_expr.ptr1 = ptr_expr1;
				new_expr.ptr2 = ptr_expr2;
				new_expr.ptr3 = 0;
				const struct Type deref = deref_type(&expr.details.type);
				new_expr.size_info_for_pointer_arith = size_of(ptr_ps, &deref);

				return new_expr;
			}
		} else {
			fprintf(stderr, "invalid type `");
			debug_print_type(&type1);
			fprintf(stderr, "`as the left operand of binary -\n");
			exit(EXIT_FAILURE);
		}
	}
	case OP_AND_AND: {
		expect_scalar(&expr.details.type, "operand of logical AND");
		expect_scalar(&expr2.details.type, "operand of logical AND");
		const struct Type t = INT_TYPE();
		return binary_op(&expr, &expr2, LOGICAL_AND_EXPR, &t);
	}
	case OP_OR_OR: {
		expect_scalar(&expr.details.type, "operand of logical OR");
		expect_scalar(&expr2.details.type, "operand of logical OR");
		const struct Type t = INT_TYPE();
		return binary_op(&expr, &expr2, LOGICAL_OR_EXPR, &t);
	}
	case OP_OR:
	case OP_AND:
	case OP_LSHIFT:
	case OP_RSHIFT:
	case OP_HAT:
	case OP_ASTERISK:
	case OP_SLASH:
	case OP_PERCENT: {
		expect_integral(&expr.details.type, "left operand of an operator");
		expect_integral(&expr2.details.type, "right operand of an operator");
		return simple_binary_op(&expr, &expr2, op, &expr2.details.type);
	}
	case OP_GT:
	case OP_GT_EQ:
	case OP_LT:
	case OP_LT_EQ:
	case OP_NOT_EQ:
	case OP_EQ_EQ: {
		struct Expr expr_new = expr;
		struct Expr expr2_new = expr2;

		if (expr.details.type.type_category == PTR_) {
			cast_to_null_pointer_if_possible(&expr2_new, &expr.details);
		} else if (expr2.details.type.type_category == PTR_) {

			cast_to_null_pointer_if_possible(&expr_new, &expr2.details);
		}

		expect_type(ptr_ps, &expr_new.details.type, &expr2_new.details.type,
		            "mismatch in operands of an "
		            "equality/comparison operator");
		const struct Type t = INT_TYPE();
		return simple_binary_op(&expr_new, &expr2_new, op, &t);
	}
	case OP_COMMA: {
		return comma_op(&expr, &expr2, &expr2.details.type);
	}
	default: {
		fprintf(stderr, "FAILURE::::::: INVALID TOKEN %d in binary expr\n", op);
		exit(EXIT_FAILURE);
	}
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x9c0, %rsp            # imm = 0x9C0
movq %rdi, -0x9b0(%rbp)
movq %rdi, -0x9a8(%rbp)
movq %rsi, -0x8(%rbp)
movq %rdx, -0x10(%rbp)
movq %rcx, -0x18(%rbp)
movl %r8d, -0x1c(%rbp)
movq -0x10(%rbp), %rsi
leaq -0x120(%rbp), %rdi
movl $0x100, %edx            # imm = 0x100
callq 0x10e0
movq -0x18(%rbp), %rsi
leaq -0x220(%rbp), %rdi
movl $0x100, %edx            # imm = 0x100
callq 0x10e0
movl -0x1c(%rbp), %edi
callq 0x6ae0
cmpl $0x0, %eax
je 0x898a
cmpl $0x2, -0x120(%rbp)
je 0x860f
cmpl $0x1, -0x120(%rbp)
jne 0x8631
cmpl $0x2, -0xd0(%rbp)
jne 0x8631
movq 0x139e2(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xc6ee(%rip), %rsi      # 0x14d0e
movb $0x0, %al
callq 0x10d0
movl $0x1, %edi
callq 0x1150
movq -0x9b0(%rbp), %rdi
leaq -0x120(%rbp), %rsi
movl $0xa0, %edx
callq 0x10e0
movl $0x1, %edi
movl $0x100, %esi            # imm = 0x100
callq 0x10b0
movq %rax, -0x228(%rbp)
movl $0x1, %edi
movl $0x100, %esi            # imm = 0x100
callq 0x10b0
movq %rax, -0x230(%rbp)
movq -0x228(%rbp), %rdi
leaq -0x120(%rbp), %rsi
movl $0x100, %edx            # imm = 0x100
callq 0x10e0
movq -0x9b0(%rbp), %rax
movq -0x228(%rbp), %rcx
movq %rcx, 0xb0(%rax)
movq $0x0, 0xc0(%rax)
cmpl $0x17, -0x1c(%rbp)
jne 0x879b
leaq -0x330(%rbp), %rdi
leaq -0x220(%rbp), %rsi
movl $0x100, %edx            # imm = 0x100
callq 0x10e0
cmpl $0x1, -0x120(%rbp)
jne 0x86f7
leaq -0x330(%rbp), %rdi
callq 0x6bc0
leaq -0x120(%rbp), %rsi
leaq -0x330(%rbp), %rdi
callq 0x6b70
movq -0x8(%rbp), %rdi
leaq -0x330(%rbp), %rsi
leaq -0x120(%rbp), %rdx
leaq 0xc616(%rip), %rcx      # 0x14d26
callq 0x6630
movq -0x230(%rbp), %rdi
leaq -0x330(%rbp), %rsi
movl $0x100, %edx            # imm = 0x100
callq 0x10e0
movq -0x9b0(%rbp), %rax
movq -0x230(%rbp), %rcx
movq %rcx, 0xb8(%rax)
leaq -0x120(%rbp), %rdi
callq 0xb250
cmpl $0x0, %eax
je 0x8785
movq -0x9b0(%rbp), %rax
movl $0x14, 0xa0(%rax)
movq -0x8(%rbp), %rdi
leaq -0x120(%rbp), %rsi
callq 0x2570
movl %eax, %ecx
movq -0x9b0(%rbp), %rax
movl %ecx, 0xf8(%rax)
jmp 0x8796
movq -0x9b0(%rbp), %rax
movl $0xe, 0xa0(%rax)
jmp 0x8ff9
leaq -0x120(%rbp), %rdi
callq 0xb250
cmpl $0x0, %eax
je 0x87f2
movq 0x13845(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xc589(%rip), %rsi      # 0x14d46
movb $0x0, %al
callq 0x10d0
leaq -0x120(%rbp), %rdi
callq 0xb390
movq 0x13821(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xb7c0(%rip), %rsi      # 0x13fa1
movb $0x0, %al
callq 0x10d0
movl $0x1, %edi
callq 0x1150
cmpl $0x1, -0x120(%rbp)
jne 0x88a7
cmpl $0x22, -0x1c(%rbp)
je 0x880f
cmpl $0x23, -0x1c(%rbp)
jne 0x88a7
leaq -0x220(%rbp), %rdi
leaq 0xc568(%rip), %rsi      # 0x14d85
callq 0x6a10
movq -0x230(%rbp), %rdi
leaq -0x220(%rbp), %rsi
movl $0x100, %edx            # imm = 0x100
callq 0x10e0
movq -0x9b0(%rbp), %rax
movl $0xd, 0xa0(%rax)
movl -0x1c(%rbp), %edi
callq 0x9010
movl %eax, %ecx
movq -0x9b0(%rbp), %rax
movl %ecx, 0xa4(%rax)
movq -0x230(%rbp), %rcx
movq %rcx, 0xb8(%rax)
leaq -0x120(%rbp), %rsi
leaq -0x380(%rbp), %rdi
callq 0xb800
movq -0x8(%rbp), %rdi
leaq -0x380(%rbp), %rsi
callq 0x2570
movl %eax, %ecx
movq -0x9b0(%rbp), %rax
movl %ecx, 0xf4(%rax)
jmp 0x8ff9
cmpl $0x1, -0x120(%rbp)
jne 0x88d2
movq 0x13741(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xc4e8(%rip), %rsi      # 0x14da9
movb $0x0, %al
callq 0x10d0
movl $0x1, %edi
callq 0x1150
movq -0x8(%rbp), %rdi
leaq -0x120(%rbp), %rsi
leaq -0x220(%rbp), %rdx
leaq 0xc43b(%rip), %rcx      # 0x14d26
callq 0x6630
movq -0x230(%rbp), %rdi
leaq -0x220(%rbp), %rsi
movl $0x100, %edx            # imm = 0x100
callq 0x10e0
movq -0x9b0(%rbp), %rax
movl $0xd, 0xa0(%rax)
movl -0x1c(%rbp), %edi
callq 0x9010
movl %eax, %ecx
movq -0x9b0(%rbp), %rax
movl %ecx, 0xa4(%rax)
movq -0x230(%rbp), %rcx
movq %rcx, 0xb8(%rax)
cmpl $0x1, -0x120(%rbp)
jne 0x8985
cmpl $0x22, -0x1c(%rbp)
je 0x8953
cmpl $0x23, -0x1c(%rbp)
jne 0x8985
leaq -0x120(%rbp), %rsi
leaq -0x3d0(%rbp), %rdi
callq 0xb800
movq -0x8(%rbp), %rdi
leaq -0x3d0(%rbp), %rsi
callq 0x2570
movl %eax, %ecx
movq -0x9b0(%rbp), %rax
movl %ecx, 0xf4(%rax)
jmp 0x8ff9
movl -0x1c(%rbp), %eax
movq %rax, -0x9b8(%rbp)
subq $0x21, %rax
ja 0x8fd4
movq -0x9b8(%rbp), %rax
leaq 0xbd08(%rip), %rcx      # 0x146b4
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq -0x120(%rbp), %rsi
leaq -0x420(%rbp), %rdi
movl $0x50, %edx
callq 0x10e0
leaq -0x220(%rbp), %rsi
leaq -0x470(%rbp), %rdi
movl $0x50, %edx
callq 0x10e0
leaq -0x420(%rbp), %rdi
callq 0x6aa0
cmpl $0x0, %eax
je 0x8ab4
leaq -0x470(%rbp), %rdi
callq 0x6aa0
cmpl $0x0, %eax
je 0x8a3f
leaq -0x4c0(%rbp), %rdi
callq 0xb230
movq -0x9b0(%rbp), %rdi
leaq -0x120(%rbp), %rsi
leaq -0x220(%rbp), %rdx
xorl %ecx, %ecx
leaq -0x4c0(%rbp), %r8
callq 0x90d0
jmp 0x8ff9
cmpl $0x1, -0x470(%rbp)
jne 0x8a6e
movq -0x9b0(%rbp), %rdi
movq -0x8(%rbp), %rsi
leaq -0x220(%rbp), %rdx
leaq -0x120(%rbp), %rcx
xorl %r8d, %r8d
callq 0x91b0
jmp 0x8ff9
movq 0x13583(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xc362(%rip), %rsi      # 0x14de1
movb $0x0, %al
callq 0x10d0
leaq -0x470(%rbp), %rdi
callq 0xb390
movq 0x1355f(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xc34d(%rip), %rsi      # 0x14df0
movb $0x0, %al
callq 0x10d0
movl $0x1, %edi
callq 0x1150
cmpl $0x1, -0x420(%rbp)
jne 0x8af6
leaq -0x220(%rbp), %rdi
leaq 0xc34b(%rip), %rsi      # 0x14e16
callq 0x6a10
movq -0x9b0(%rbp), %rdi
movq -0x8(%rbp), %rsi
leaq -0x120(%rbp), %rdx
leaq -0x220(%rbp), %rcx
xorl %r8d, %r8d
callq 0x91b0
jmp 0x8ff9
movq 0x134fb(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xc2da(%rip), %rsi      # 0x14de1
movb $0x0, %al
callq 0x10d0
leaq -0x420(%rbp), %rdi
callq 0xb390
movq 0x134d7(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xc314(%rip), %rsi      # 0x14e3f
movb $0x0, %al
callq 0x10d0
movl $0x1, %edi
callq 0x1150
leaq -0x120(%rbp), %rsi
leaq -0x510(%rbp), %rdi
movl $0x50, %edx
callq 0x10e0
leaq -0x220(%rbp), %rsi
leaq -0x560(%rbp), %rdi
movl $0x50, %edx
callq 0x10e0
leaq -0x510(%rbp), %rdi
callq 0x6aa0
cmpl $0x0, %eax
je 0x8c3a
leaq -0x560(%rbp), %rdi
callq 0x6aa0
cmpl $0x0, %eax
je 0x8bc9
leaq -0x5b0(%rbp), %rdi
callq 0xb230
movq -0x9b0(%rbp), %rdi
leaq -0x120(%rbp), %rsi
leaq -0x220(%rbp), %rdx
movl $0x1, %ecx
leaq -0x5b0(%rbp), %r8
callq 0x90d0
jmp 0x8ff9
cmpl $0x1, -0x560(%rbp)
jne 0x8bf4
movq 0x1341f(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xc27e(%rip), %rsi      # 0x14e61
movb $0x0, %al
callq 0x10d0
movl $0x1, %edi
callq 0x1150
movq 0x133fd(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xc1dc(%rip), %rsi      # 0x14de1
movb $0x0, %al
callq 0x10d0
leaq -0x560(%rbp), %rdi
callq 0xb390
movq 0x133d9(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xc264(%rip), %rsi      # 0x14e8d
movb $0x0, %al
callq 0x10d0
movl $0x1, %edi
callq 0x1150
cmpl $0x1, -0x510(%rbp)
jne 0x8da6
leaq -0x560(%rbp), %rdi
callq 0x6aa0
cmpl $0x0, %eax
je 0x8c81
movq -0x9b0(%rbp), %rdi
movq -0x8(%rbp), %rsi
leaq -0x120(%rbp), %rdx
leaq -0x220(%rbp), %rcx
movl $0x1, %r8d
callq 0x91b0
jmp 0x8ff9
movl $0x1, %edi
movl $0x100, %esi            # imm = 0x100
callq 0x10b0
movq %rax, -0x5b8(%rbp)
movl $0x1, %edi
movl $0x100, %esi            # imm = 0x100
callq 0x10b0
movq %rax, -0x5c0(%rbp)
movq -0x5b8(%rbp), %rdi
leaq -0x120(%rbp), %rsi
movl $0x100, %edx            # imm = 0x100
callq 0x10e0
movq -0x5c0(%rbp), %rdi
leaq -0x220(%rbp), %rsi
movl $0x100, %edx            # imm = 0x100
callq 0x10e0
leaq -0x610(%rbp), %rdi
callq 0xb230
movq -0x9b0(%rbp), %rdi
leaq -0x610(%rbp), %rsi
movl $0x50, %edx
callq 0x10e0
movq -0x9b0(%rbp), %rax
addq $0x50, %rax
movq %rax, -0x9c0(%rbp)
leaq -0x660(%rbp), %rdi
callq 0xb230
movq -0x9c0(%rbp), %rdi
leaq -0x660(%rbp), %rsi
movl $0x50, %edx
callq 0x10e0
movq -0x9b0(%rbp), %rax
movl $0x4, 0xa0(%rax)
movq -0x5b8(%rbp), %rcx
movq %rcx, 0xb0(%rax)
movq -0x5c0(%rbp), %rcx
movq %rcx, 0xb8(%rax)
movq $0x0, 0xc0(%rax)
leaq -0x120(%rbp), %rsi
leaq -0x6b0(%rbp), %rdi
callq 0xb800
movq -0x8(%rbp), %rdi
leaq -0x6b0(%rbp), %rsi
callq 0x2570
movl %eax, %ecx
movq -0x9b0(%rbp), %rax
movl %ecx, 0xf4(%rax)
jmp 0x8ff9
movq 0x1324b(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xc02a(%rip), %rsi      # 0x14de1
movb $0x0, %al
callq 0x10d0
leaq -0x510(%rbp), %rdi
callq 0xb390
movq 0x13227(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
leaq 0xc0d8(%rip), %rsi      # 0x14eb3
movb $0x0, %al
callq 0x10d0
movl $0x1, %edi
callq 0x1150
leaq -0x120(%rbp), %rdi
leaq 0xc0db(%rip), %rsi      # 0x14ed5
callq 0x6960
leaq -0x220(%rbp), %rdi
leaq 0xc0c8(%rip), %rsi      # 0x14ed5
callq 0x6960
leaq -0x700(%rbp), %rdi
callq 0xb230
movq -0x9b0(%rbp), %rdi
leaq -0x120(%rbp), %rsi
leaq -0x220(%rbp), %rdx
movl $0x10, %ecx
leaq -0x700(%rbp), %r8
callq 0x92d0
jmp 0x8ff9
leaq -0x120(%rbp), %rdi
leaq 0xc095(%rip), %rsi      # 0x14eec
callq 0x6960
leaq -0x220(%rbp), %rdi
leaq 0xc082(%rip), %rsi      # 0x14eec
callq 0x6960
leaq -0x750(%rbp), %rdi
callq 0xb230
movq -0x9b0(%rbp), %rdi
leaq -0x120(%rbp), %rsi
leaq -0x220(%rbp), %rdx
movl $0xf, %ecx
leaq -0x750(%rbp), %r8
callq 0x92d0
jmp 0x8ff9
leaq -0x120(%rbp), %rdi
leaq 0xc04e(%rip), %rsi      # 0x14f02
callq 0x6a10
leaq -0x220(%rbp), %rdi
leaq 0xc057(%rip), %rsi      # 0x14f1e
callq 0x6a10
movq -0x9b0(%rbp), %rdi
movl -0x1c(%rbp), %ecx
leaq -0x220(%rbp), %r8
leaq -0x120(%rbp), %rsi
leaq -0x220(%rbp), %rdx
callq 0x90d0
jmp 0x8ff9
leaq -0x850(%rbp), %rdi
leaq -0x120(%rbp), %rsi
movl $0x100, %edx            # imm = 0x100
callq 0x10e0
leaq -0x950(%rbp), %rdi
leaq -0x220(%rbp), %rsi
movl $0x100, %edx            # imm = 0x100
callq 0x10e0
cmpl $0x1, -0x120(%rbp)
jne 0x8f43
leaq -0x120(%rbp), %rsi
leaq -0x950(%rbp), %rdi
callq 0x6b70
jmp 0x8f61
cmpl $0x1, -0x220(%rbp)
jne 0x8f5f
leaq -0x220(%rbp), %rsi
leaq -0x850(%rbp), %rdi
callq 0x6b70
jmp 0x8f61
movq -0x8(%rbp), %rdi
leaq -0x850(%rbp), %rsi
leaq -0x950(%rbp), %rdx
leaq 0xbfc1(%rip), %rcx      # 0x14f3b
callq 0x6630
leaq -0x9a0(%rbp), %rdi
callq 0xb230
movq -0x9b0(%rbp), %rdi
movl -0x1c(%rbp), %ecx
leaq -0x850(%rbp), %rsi
leaq -0x950(%rbp), %rdx
leaq -0x9a0(%rbp), %r8
callq 0x90d0
jmp 0x8ff9
movq -0x9b0(%rbp), %rdi
leaq -0x220(%rbp), %rcx
leaq -0x120(%rbp), %rsi
leaq -0x220(%rbp), %rdx
callq 0x93a0
jmp 0x8ff9
movq 0x1301d(%rip), %rax     # 0x1bff8
movq (%rax), %rdi
movl -0x1c(%rbp), %edx
leaq 0xbf8b(%rip), %rsi      # 0x14f73
movb $0x0, %al
callq 0x10d0
movl $0x1, %edi
callq 0x1150
movq -0x9a8(%rbp), %rax
addq $0x9c0, %rsp            # imm = 0x9C0
popq %rbp
retq
nopl (%rax)