// File: /workspace/github_c_makefile_star2_O1/Ihsoh[P]ilang/compiler/frontend/semantics.c
// Function: expr_shift
static void _expr_shift(
	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_SHIFT_LEFT:
		case FE_NODE_EXPR_SHIFT_RIGHT: {
			_CHECK
			ParserASTNode *node_oprd1 = node->childs[0];
			ParserASTNode *node_oprd2 = node->childs[1];
			_expr_add(ctx, node_oprd1);
			_expr_add(ctx, node_oprd2);

			const char *operator = NULL;
			if (node_type == FE_NODE_EXPR_SHIFT_LEFT) {
				operator = "<<";
			} else if (node_type == FE_NODE_EXPR_SHIFT_RIGHT) {
				operator = ">>";
			} else {
				assert(0);
			}

			_check_expr_shift_operands(
				ctx, node, node_oprd1, node_oprd2, operator, true
			);

			FE_EXPR_AST_NODE_COPY_CONSTANT2(node, node_oprd1, node_oprd2);
			if (FE_EXPR_AST_NODE_GET_CONSTANT(node)) {
				_calc_shift_constexpr(ctx, node_type, node, node_oprd1, node_oprd2);
			}
			break;
		}
		default: {
			_expr_add(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 0x2fff3
movq %rsi, %rbx
movq %rdi, %r12
movl (%rsi), %r13d
movl %r13d, %eax
andl $-0x2, %eax
cmpl $0xe90, %eax            # imm = 0xE90
jne 0x2fd7e
cmpl $0x2, 0x44(%rbx)
jne 0x30012
movq 0x48(%rbx), %rax
movq (%rax), %r14
movq 0x8(%rax), %r15
movq %r12, %rdi
movq %r14, %rsi
callq 0x30167
movq %r12, %rdi
movq %r15, %rsi
callq 0x30167
cmpl $0xe90, %r13d           # imm = 0xE90
je 0x2fd97
cmpl $0xe91, %r13d           # imm = 0xE91
jne 0x30031
leaq 0x1c4cc(%rip), %r8      # 0x4c248
jmp 0x2fd9e
movq %r12, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x30167
leaq 0x1c4a7(%rip), %r8      # 0x4c245
movq %r12, %rdi
movq %rbx, %rsi
movq %r14, %rdx
movq %r15, %rcx
movl $0x1, %r9d
callq 0x2dfba
cmpb $0x1, 0x70(%r14)
jne 0x2fe6a
movb 0x70(%r15), %al
movb %al, 0x70(%rbx)
cmpb $0x1, %al
jne 0x2fe6e
testq %r14, %r14
je 0x30050
movzbl 0x1(%r14), %eax
shll $0x8, %eax
cmpl $0xe00, %eax            # imm = 0xE00
jne 0x3006f
cmpb $0x0, 0x70(%r14)
je 0x3008e
testq %r15, %r15
je 0x300ad
movzbl 0x1(%r15), %eax
shll $0x8, %eax
cmpl $0xe00, %eax            # imm = 0xE00
jne 0x300cc
cmpb $0x0, 0x70(%r15)
je 0x300eb
movzbl 0x60(%r14), %r12d
movq %r15, %rdi
callq 0x32cd8
cmpl $0xe91, %r13d           # imm = 0xE91
je 0x2fe7d
cmpl $0xe90, %r13d           # imm = 0xE90
jne 0x3010a
decl %r12d
cmpl $0x8, %r12d
ja 0x30129
leaq 0x1b210(%rip), %rcx     # 0x4b064
movslq (%rcx,%r12,4), %rdx
addq %rcx, %rdx
jmpq *%rdx
movl 0x88(%r14), %edx
movl %eax, %ecx
shll %cl, %edx
jmp 0x2fea6
movb $0x0, 0x70(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
decl %r12d
cmpl $0x8, %r12d
ja 0x30148
leaq 0x1b1af(%rip), %rcx     # 0x4b040
movslq (%rcx,%r12,4), %rdx
addq %rcx, %rdx
jmpq *%rdx
movsbl 0x88(%r14), %edx
movl %eax, %ecx
sarl %cl, %edx
movb %dl, 0x88(%rbx)
movb $0x1, 0x71(%rbx)
jmp 0x2fe6e
movq 0x88(%r14), %rdx
movl %eax, %ecx
sarq %cl, %rdx
jmp 0x2fecc
movq 0x88(%r14), %rdx
movl %eax, %ecx
shlq %cl, %rdx
movq %rdx, 0x88(%rbx)
movb $0x5, 0x71(%rbx)
jmp 0x2fe6e
movswl 0x88(%r14), %edx
movl %eax, %ecx
sarl %cl, %edx
jmp 0x2fef2
movl 0x88(%r14), %edx
movl %eax, %ecx
shll %cl, %edx
movw %dx, 0x88(%rbx)
movb $0x3, 0x71(%rbx)
jmp 0x2fe6e
movl 0x88(%r14), %edx
movl %eax, %ecx
sarl %cl, %edx
jmp 0x2ff1a
movl 0x88(%r14), %edx
movl %eax, %ecx
shll %cl, %edx
movl %edx, 0x88(%rbx)
movb $0x4, 0x71(%rbx)
jmp 0x2fe6e
movl 0x88(%r14), %edx
movl %eax, %ecx
shrl %cl, %edx
jmp 0x2ff41
movl 0x88(%r14), %edx
movl %eax, %ecx
shll %cl, %edx
movl %edx, 0x88(%rbx)
movb $0x8, 0x71(%rbx)
jmp 0x2fe6e
movsbl 0x88(%r14), %edx
movl %eax, %ecx
sarl %cl, %edx
jmp 0x2ff69
movl 0x88(%r14), %edx
movl %eax, %ecx
shll %cl, %edx
movb %dl, 0x88(%rbx)
movb $0x2, 0x71(%rbx)
jmp 0x2fe6e
movzbl 0x88(%r14), %edx
movl %eax, %ecx
shrl %cl, %edx
jmp 0x2ff91
movl 0x88(%r14), %edx
movl %eax, %ecx
shll %cl, %edx
movb %dl, 0x88(%rbx)
movb $0x6, 0x71(%rbx)
jmp 0x2fe6e
movzwl 0x88(%r14), %edx
movl %eax, %ecx
shrl %cl, %edx
jmp 0x2ffb9
movl 0x88(%r14), %edx
movl %eax, %ecx
shll %cl, %edx
movw %dx, 0x88(%rbx)
movb $0x7, 0x71(%rbx)
jmp 0x2fe6e
movq 0x88(%r14), %rdx
movl %eax, %ecx
shrq %cl, %rdx
jmp 0x2ffe3
movq 0x88(%r14), %rdx
movl %eax, %ecx
shlq %cl, %rdx
movq %rdx, 0x88(%rbx)
movb $0x9, 0x71(%rbx)
jmp 0x2fe6e
leaq 0x13d9c(%rip), %rdi     # 0x43d96
leaq 0x1b859(%rip), %rsi     # 0x4b85a
leaq 0x1c20a(%rip), %rcx     # 0x4c212
movl $0x1066, %edx           # imm = 0x1066
callq 0x30a0
leaq 0x1bc3c(%rip), %rdi     # 0x4bc55
leaq 0x1b83a(%rip), %rsi     # 0x4b85a
leaq 0x1c1eb(%rip), %rcx     # 0x4c212
movl $0x1072, %edx           # imm = 0x1072
callq 0x30a0
leaq 0x1034c(%rip), %rdi     # 0x40384
leaq 0x1b81b(%rip), %rsi     # 0x4b85a
leaq 0x1c1cc(%rip), %rcx     # 0x4c212
movl $0x107e, %edx           # imm = 0x107E
callq 0x30a0
leaq 0x1cb85(%rip), %rdi     # 0x4cbdc
leaq 0x1b7fc(%rip), %rsi     # 0x4b85a
leaq 0x1cb0e(%rip), %rcx     # 0x4cb73
movl $0xb88, %edx            # imm = 0xB88
callq 0x30a0
leaq 0x1cb6e(%rip), %rdi     # 0x4cbe4
leaq 0x1b7dd(%rip), %rsi     # 0x4b85a
leaq 0x1caef(%rip), %rcx     # 0x4cb73
movl $0xb89, %edx            # imm = 0xB89
callq 0x30a0
leaq 0x1cb6e(%rip), %rdi     # 0x4cc03
leaq 0x1b7be(%rip), %rsi     # 0x4b85a
leaq 0x1cad0(%rip), %rcx     # 0x4cb73
movl $0xb8a, %edx            # imm = 0xB8A
callq 0x30a0
leaq 0x1cb76(%rip), %rdi     # 0x4cc2a
leaq 0x1b79f(%rip), %rsi     # 0x4b85a
leaq 0x1cab1(%rip), %rcx     # 0x4cb73
movl $0xb8b, %edx            # imm = 0xB8B
callq 0x30a0
leaq 0x1cb5f(%rip), %rdi     # 0x4cc32
leaq 0x1b780(%rip), %rsi     # 0x4b85a
leaq 0x1ca92(%rip), %rcx     # 0x4cb73
movl $0xb8c, %edx            # imm = 0xB8C
callq 0x30a0
leaq 0x1cb5f(%rip), %rdi     # 0x4cc51
leaq 0x1b761(%rip), %rsi     # 0x4b85a
leaq 0x1ca73(%rip), %rcx     # 0x4cb73
movl $0xb8d, %edx            # imm = 0xB8D
callq 0x30a0
leaq 0x10273(%rip), %rdi     # 0x40384
leaq 0x1b742(%rip), %rsi     # 0x4b85a
leaq 0x1ca54(%rip), %rcx     # 0x4cb73
movl $0xbb3, %edx            # imm = 0xBB3
callq 0x30a0
leaq 0x10254(%rip), %rdi     # 0x40384
leaq 0x1b723(%rip), %rsi     # 0x4b85a
leaq 0x1ca35(%rip), %rcx     # 0x4cb73
movl $0xbb0, %edx            # imm = 0xBB0
callq 0x30a0
leaq 0x10235(%rip), %rdi     # 0x40384
leaq 0x1b704(%rip), %rsi     # 0x4b85a
leaq 0x1ca16(%rip), %rcx     # 0x4cb73
movl $0xbb1, %edx            # imm = 0xBB1
callq 0x30a0