// File: /workspace/github_c_makefile_star2_O0/markdryan[P]subtilis/frontend/parser_output.c
// Function: prv_vdu_2bytes
static void prv_vdu_2bytes(subtilis_parser_t *p, subtilis_exp_t *e,
			   subtilis_error_t *err)
{
	subtilis_ir_operand_t op1;
	subtilis_ir_operand_t op2;

	if (e->type.type == SUBTILIS_TYPE_INTEGER) {
		op2.integer = 0xff;
		op1.reg = subtilis_ir_section_add_instr(
		    p->current, SUBTILIS_OP_INSTR_ANDI_I32, e->exp.ir_op, op2,
		    err);
		if (err->type != SUBTILIS_ERROR_OK)
			return;
		subtilis_ir_section_add_instr_no_reg(
		    p->current, SUBTILIS_OP_INSTR_VDU, op1, err);
		if (err->type != SUBTILIS_ERROR_OK)
			return;
		if (!p->settings.ignore_graphics_errors) {
			subtilis_exp_handle_errors(p, err);
			if (err->type != SUBTILIS_ERROR_OK)
				return;
		}
		op2.integer = 8;
		op1.reg = subtilis_ir_section_add_instr(
		    p->current, SUBTILIS_OP_INSTR_LSRI_I32, e->exp.ir_op, op2,
		    err);
		if (err->type != SUBTILIS_ERROR_OK)
			return;
		subtilis_ir_section_add_instr_no_reg(
		    p->current, SUBTILIS_OP_INSTR_VDU, op1, err);
		if (err->type != SUBTILIS_ERROR_OK)
			return;
	} else if (e->type.type == SUBTILIS_TYPE_CONST_INTEGER) {
		op1.integer = e->exp.ir_op.integer & 0xff;
		subtilis_ir_section_add_instr_no_reg(
		    p->current, SUBTILIS_OP_INSTR_VDUI, op1, err);
		if (err->type != SUBTILIS_ERROR_OK)
			return;
		if (!p->settings.ignore_graphics_errors) {
			subtilis_exp_handle_errors(p, err);
			if (err->type != SUBTILIS_ERROR_OK)
				return;
		}
		op1.integer = (e->exp.ir_op.integer >> 8) & 0xff;
		subtilis_ir_section_add_instr_no_reg(
		    p->current, SUBTILIS_OP_INSTR_VDUI, op1, err);
	} else {
		subtilis_error_set_assertion_failed(err);
		return;
	}
	if (!p->settings.ignore_graphics_errors)
		subtilis_exp_handle_errors(p, err);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x5, (%rax)
jne 0x3081c
movl $0xff, -0x28(%rbp)
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x10(%rbp), %rax
movq -0x18(%rbp), %r8
movq 0x148(%rax), %rdx
movq -0x28(%rbp), %rcx
movl $0x25, %esi
callq 0x38230
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x3075f
jmp 0x308f3
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x18(%rbp), %rcx
movq -0x20(%rbp), %rdx
movl $0x71, %esi
callq 0x38540
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x30787
jmp 0x308f3
movq -0x8(%rbp), %rax
testb $0x1, 0xb9(%rax)
jne 0x307b1
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x36ce0
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x307af
jmp 0x308f3
jmp 0x307b1
movl $0x8, -0x28(%rbp)
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x10(%rbp), %rax
movq -0x18(%rbp), %r8
movq 0x148(%rax), %rdx
movq -0x28(%rbp), %rcx
movl $0x4e, %esi
callq 0x38230
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x307ef
jmp 0x308f3
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x18(%rbp), %rcx
movq -0x20(%rbp), %rdx
movl $0x71, %esi
callq 0x38540
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x30817
jmp 0x308f3
jmp 0x308d9
movq -0x10(%rbp), %rax
cmpl $0x1, (%rax)
jne 0x308bb
movq -0x10(%rbp), %rax
movl 0x148(%rax), %eax
andl $0xff, %eax
movl %eax, -0x20(%rbp)
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x18(%rbp), %rcx
movq -0x20(%rbp), %rdx
movl $0x70, %esi
callq 0x38540
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x30863
jmp 0x308f3
movq -0x8(%rbp), %rax
testb $0x1, 0xb9(%rax)
jne 0x3088a
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x36ce0
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x30888
jmp 0x308f3
jmp 0x3088a
movq -0x10(%rbp), %rax
movl 0x148(%rax), %eax
sarl $0x8, %eax
andl $0xff, %eax
movl %eax, -0x20(%rbp)
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x18(%rbp), %rcx
movq -0x20(%rbp), %rdx
movl $0x70, %esi
callq 0x38540
jmp 0x308d7
movq -0x18(%rbp), %rdi
movl $0xf, %esi
leaq 0x7a19e(%rip), %rdx     # 0xaaa69
movl $0x5d, %ecx
callq 0x158e0
jmp 0x308f3
jmp 0x308d9
movq -0x8(%rbp), %rax
testb $0x1, 0xb9(%rax)
jne 0x308f3
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x36ce0
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)