// File: /workspace/github_c_makefile_star2_O1/Ihsoh[P]ilang/compiler/frontend/semantics.c
// Function: expr_add
static void _expr_add(
	ParserContext *ctx,
	ParserASTNode *node
) {
	assert(ctx);
	assert(node);

	#define	_CHECK	\
	{	\
		assert(node->nchilds == 2);	\
	}

	uint32_t node_type = node->type;

	switch (node_type) {
		case FE_NODE_EXPR_ADD: {
			_CHECK
			ParserASTNode *node_oprd1 = node->childs[0];
			ParserASTNode *node_oprd2 = node->childs[1];
			_expr_unary(ctx, node_oprd1);
			_expr_unary(ctx, node_oprd2);

			_check_expr_add_operands(
				ctx, node, node_oprd1, node_oprd2, "+", true
			);

			FE_EXPR_AST_NODE_COPY_CONSTANT2(node, node_oprd1, node_oprd2);
			if (FE_EXPR_AST_NODE_GET_CONSTANT(node)) {
				_calc_binary_constexpr(ctx, node_type, node, node_oprd1, node_oprd2);
			}
			break;
		}
		case FE_NODE_EXPR_SUB: {
			_CHECK
			ParserASTNode *node_oprd1 = node->childs[0];
			ParserASTNode *node_oprd2 = node->childs[1];
			_expr_unary(ctx, node_oprd1);
			_expr_unary(ctx, node_oprd2);

			_check_expr_sub_operands(
				ctx, node, node_oprd1, node_oprd2, "-", true
			);

			FE_EXPR_AST_NODE_COPY_CONSTANT2(node, node_oprd1, node_oprd2);
			if (FE_EXPR_AST_NODE_GET_CONSTANT(node)) {
				_calc_binary_constexpr(ctx, node_type, node, node_oprd1, node_oprd2);
			}
			break;
		}
		default: {
			_expr_mul(ctx, node);
			break;
		}
	}

	#undef	_CHECK
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testq %rsi, %rsi
je 0x303e6
movq %rsi, %rbx
movq %rdi, %r14
movl (%rsi), %r15d
cmpl $0xeaf, %r15d           # imm = 0xEAF
jle 0x301f1
leal -0xeb0(%r15), %eax
cmpl $0x2, %eax
jae 0x3027c
cmpl $0x2, 0x44(%rbx)
jne 0x30405
movq 0x48(%rbx), %rax
movq (%rax), %r12
movq 0x8(%rax), %r13
movq %r14, %rdi
movq %r12, %rsi
callq 0x304a0
movq %r14, %rdi
movq %r13, %rsi
callq 0x304a0
cmpl $0xeb0, %r15d           # imm = 0xEB0
je 0x30380
cmpl $0xeb1, %r15d           # imm = 0xEB1
jne 0x30481
leaq 0x1c985(%rip), %r8      # 0x4cb71
jmp 0x30387
cmpl $0xea0, %r15d           # imm = 0xEA0
je 0x302f0
cmpl $0xea1, %r15d           # imm = 0xEA1
jne 0x30367
cmpl $0x2, 0x44(%rbx)
jne 0x30462
movq 0x48(%rbx), %rax
movq (%rax), %r15
movq 0x8(%rax), %r12
movq %r14, %rdi
movq %r15, %rsi
callq 0x304a0
movq %r14, %rdi
movq %r12, %rsi
callq 0x304a0
leaq 0x14b73(%rip), %r8      # 0x44db0
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
movq %r12, %rcx
movl $0x1, %r9d
callq 0x2d659
cmpb $0x1, 0x70(%r15)
jne 0x303d3
movb 0x70(%r12), %al
movb %al, 0x70(%rbx)
cmpb $0x1, %al
jne 0x303d7
movq %r14, %rdi
movl $0xea1, %esi            # imm = 0xEA1
jmp 0x3035c
cmpl $0xeb2, %r15d           # imm = 0xEB2
jne 0x30367
cmpl $0x2, 0x44(%rbx)
jne 0x30424
movq 0x48(%rbx), %rax
movq (%rax), %r15
movq 0x8(%rax), %r12
movq %r14, %rdi
movq %r15, %rsi
callq 0x304a0
movq %r14, %rdi
movq %r12, %rsi
callq 0x304a0
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
movq %r12, %rcx
movl $0x1, %r8d
callq 0x2d9e5
cmpb $0x1, 0x70(%r15)
jne 0x303d3
movb 0x70(%r12), %al
movb %al, 0x70(%rbx)
cmpb $0x1, %al
jne 0x303d7
movq %r14, %rdi
movl $0xeb2, %esi            # imm = 0xEB2
jmp 0x3035c
cmpl $0x2, 0x44(%rbx)
jne 0x30443
movq 0x48(%rbx), %rax
movq (%rax), %r15
movq 0x8(%rax), %r12
movq %r14, %rdi
movq %r15, %rsi
callq 0x304a0
movq %r14, %rdi
movq %r12, %rsi
callq 0x304a0
leaq 0x14a8b(%rip), %r8      # 0x44dad
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
movq %r12, %rcx
movl $0x1, %r9d
callq 0x2d44d
cmpb $0x1, 0x70(%r15)
jne 0x303d3
movb 0x70(%r12), %al
movb %al, 0x70(%rbx)
cmpb $0x1, %al
jne 0x303d7
movq %r14, %rdi
movl $0xea0, %esi            # imm = 0xEA0
movq %rbx, %rdx
movq %r15, %rcx
movq %r12, %r8
jmp 0x303c0
movq %r14, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x304a0
leaq 0x14650(%rip), %r8      # 0x449d7
movq %r14, %rdi
movq %rbx, %rsi
movq %r12, %rdx
movq %r13, %rcx
movl $0x1, %r9d
callq 0x2d865
cmpb $0x1, 0x70(%r12)
jne 0x303d3
movb 0x70(%r13), %al
movb %al, 0x70(%rbx)
cmpb $0x1, %al
jne 0x303d7
movq %r14, %rdi
movl %r15d, %esi
movq %rbx, %rdx
movq %r12, %rcx
movq %r13, %r8
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x2e578
movb $0x0, 0x70(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x139a9(%rip), %rdi     # 0x43d96
leaq 0x1b466(%rip), %rsi     # 0x4b85a
leaq 0x1be50(%rip), %rcx     # 0x4c24b
movl $0x1010, %edx           # imm = 0x1010
callq 0x30a0
leaq 0x1b849(%rip), %rdi     # 0x4bc55
leaq 0x1b447(%rip), %rsi     # 0x4b85a
leaq 0x1c726(%rip), %rcx     # 0x4cb40
movl $0xf8c, %edx            # imm = 0xF8C
callq 0x30a0
leaq 0x1b82a(%rip), %rdi     # 0x4bc55
leaq 0x1b428(%rip), %rsi     # 0x4b85a
leaq 0x1c707(%rip), %rcx     # 0x4cb40
movl $0xfa6, %edx            # imm = 0xFA6
callq 0x30a0
leaq 0x1b80b(%rip), %rdi     # 0x4bc55
leaq 0x1b409(%rip), %rsi     # 0x4b85a
leaq 0x1bdf3(%rip), %rcx     # 0x4c24b
movl $0x101b, %edx           # imm = 0x101B
callq 0x30a0
leaq 0x1b7ec(%rip), %rdi     # 0x4bc55
leaq 0x1b3ea(%rip), %rsi     # 0x4b85a
leaq 0x1bdd4(%rip), %rcx     # 0x4c24b
movl $0x102c, %edx           # imm = 0x102C
callq 0x30a0
leaq 0xfefc(%rip), %rdi      # 0x40384
leaq 0x1b3cb(%rip), %rsi     # 0x4b85a
leaq 0x1c6aa(%rip), %rcx     # 0x4cb40
movl $0xf98, %edx            # imm = 0xF98
callq 0x30a0