// File: /workspace/github_c_makefile_star2_O0/Ihsoh[P]ilang/compiler/backend/semantics.c
// Function: stat_ref
static void _stat_ref(
	ParserContext *ctx,
	ParserASTNode *node
) {
	assert(ctx);
	assert(node);
	assert(node->type == BE_NODE_STAT_REF);

	ParserASTNode *node_target = node->childs[0];
	assert(node_target->type == BE_NODE_IDENTIFIER);
	ParserSymbol *symbol_target = _get_var_symbol_by_id_node(ctx, node_target);
	ParserASTNode *node_type_target = BE_VAR_SYMBOL_GET_TYPE_NODE(symbol_target);
	if (!_is_pointer_type(BE_VAR_SYMBOL_GET_TYPE(symbol_target))) {
		_SYNERR_NODE(ctx, node_target, "target parameter type must be pointer type.");
	}

	ParserASTNode *node_source = node->childs[1];
	assert(node_source->type == BE_NODE_IDENTIFIER);
	ParserSymbol *symbol_source = _get_var_symbol_by_id_node(ctx, node_source);
	ParserASTNode *node_type_source = BE_VAR_SYMBOL_GET_TYPE_NODE(symbol_source);
	_check_param_combination2(
		ctx,
		node,
		node_type_target->childs[0],
		node_type_source
	);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x450, %rsp            # imm = 0x450
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
cmpq $0x0, -0x8(%rbp)
je 0x5c81c
jmp 0x5c83b
leaq 0x2393e(%rip), %rdi     # 0x80161
leaq 0x26056(%rip), %rsi     # 0x82880
movl $0x1178, %edx           # imm = 0x1178
leaq 0x28818(%rip), %rcx     # 0x8504e
callq 0x30a0
cmpq $0x0, -0x10(%rbp)
je 0x5c844
jmp 0x5c863
leaq 0x19d11(%rip), %rdi     # 0x7655c
leaq 0x2602e(%rip), %rsi     # 0x82880
movl $0x1179, %edx           # imm = 0x1179
leaq 0x287f0(%rip), %rcx     # 0x8504e
callq 0x30a0
movq -0x10(%rbp), %rax
cmpl $0xbea, (%rax)          # imm = 0xBEA
jne 0x5c871
jmp 0x5c890
leaq 0x1abe9(%rip), %rdi     # 0x77461
leaq 0x26001(%rip), %rsi     # 0x82880
movl $0x117a, %edx           # imm = 0x117A
leaq 0x287c3(%rip), %rcx     # 0x8504e
callq 0x30a0
movq -0x10(%rbp), %rax
movq 0x48(%rax), %rax
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x200, (%rax)          # imm = 0x200
jne 0x5c8ad
jmp 0x5c8cc
leaq 0x19b09(%rip), %rdi     # 0x763bd
leaq 0x25fc5(%rip), %rsi     # 0x82880
movl $0x117d, %edx           # imm = 0x117D
leaq 0x28787(%rip), %rcx     # 0x8504e
callq 0x30a0
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x5edc0
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq 0x38(%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movzbl 0x30(%rax), %edi
callq 0x4db90
testb $0x1, %al
jne 0x5c928
leaq -0x430(%rbp), %rdi
leaq 0x28777(%rip), %rsi     # 0x8507f
movb $0x0, %al
callq 0x3160
movq -0x8(%rbp), %rax
movq 0x58(%rax), %rax
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
leaq -0x430(%rbp), %rdx
callq *%rax
movq -0x10(%rbp), %rax
movq 0x48(%rax), %rax
movq 0x8(%rax), %rax
movq %rax, -0x438(%rbp)
movq -0x438(%rbp), %rax
cmpl $0x200, (%rax)          # imm = 0x200
jne 0x5c94c
jmp 0x5c96b
leaq 0x1ab2d(%rip), %rdi     # 0x77480
leaq 0x25f26(%rip), %rsi     # 0x82880
movl $0x1185, %edx           # imm = 0x1185
leaq 0x286e8(%rip), %rcx     # 0x8504e
callq 0x30a0
movq -0x8(%rbp), %rdi
movq -0x438(%rbp), %rsi
callq 0x5edc0
movq %rax, -0x440(%rbp)
movq -0x440(%rbp), %rax
movq 0x38(%rax), %rax
movq %rax, -0x448(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rax
movq (%rax), %rdx
movq -0x448(%rbp), %rcx
callq 0x5f150
addq $0x450, %rsp            # imm = 0x450
popq %rbp
retq
nopl (%rax)