// File: /workspace/github_c_makefile_star2_O0/markdryan[P]subtilis/frontend/parser_output.c
// Function: prv_spc
static void prv_spc(subtilis_parser_t *p, subtilis_exp_t *e,
		    subtilis_error_t *err)
{
	subtilis_ir_operand_t start_label;
	subtilis_ir_operand_t end_label;
	subtilis_ir_operand_t next_label;
	subtilis_ir_operand_t counter_reg;
	subtilis_exp_t *one = NULL;
	subtilis_exp_t *zero = NULL;
	subtilis_exp_t *space = NULL;
	subtilis_exp_t *cond = NULL;
	subtilis_exp_t *e_dup = NULL;

	start_label.label = subtilis_ir_section_new_label(p->current);
	next_label.label = subtilis_ir_section_new_label(p->current);
	end_label.label = subtilis_ir_section_new_label(p->current);

	e = subtilis_type_if_exp_to_var(p, e, err);
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;

	counter_reg = e->exp.ir_op;

	subtilis_ir_section_add_label(p->current, start_label.label, err);
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;

	zero = subtilis_exp_new_int32(0, err);
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;

	one = subtilis_exp_new_int32(1, err);
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;

	space = subtilis_exp_new_int32(32, err);
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;

	e_dup = subtilis_type_if_dup(e, err);
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;

	cond = subtilis_type_if_gte(p, zero, e_dup, err);
	zero = NULL;
	e_dup = NULL;
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;
	subtilis_ir_section_add_instr_reg(p->current, SUBTILIS_OP_INSTR_JMPC,
					  cond->exp.ir_op, end_label,
					  next_label, err);
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;

	subtilis_ir_section_add_label(p->current, next_label.label, err);
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;

	prv_vdu_byte(p, space, err);
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;

	e = subtilis_type_if_sub(p, e, one, err);
	one = NULL;
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;

	subtilis_ir_section_add_instr_no_reg2(p->current, SUBTILIS_OP_INSTR_MOV,
					      counter_reg, e->exp.ir_op, err);
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;

	subtilis_ir_section_add_instr_no_reg(p->current, SUBTILIS_OP_INSTR_JMP,
					     start_label, err);
	if (err->type != SUBTILIS_ERROR_OK)
		goto cleanup;

	subtilis_ir_section_add_label(p->current, end_label.label, err);

cleanup:

	subtilis_exp_delete(cond);
	subtilis_exp_delete(space);
	subtilis_exp_delete(one);
	subtilis_exp_delete(e_dup);
	subtilis_exp_delete(zero);
	subtilis_exp_delete(e);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq $0x0, -0x40(%rbp)
movq $0x0, -0x48(%rbp)
movq $0x0, -0x50(%rbp)
movq $0x0, -0x58(%rbp)
movq $0x0, -0x60(%rbp)
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
callq 0x39940
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
callq 0x39940
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
callq 0x39940
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq 0x47c10
movq %rax, -0x10(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x312b2
jmp 0x314a6
movq -0x10(%rbp), %rax
movq 0x148(%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x20(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq 0x39960
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x312e4
jmp 0x314a6
movq -0x18(%rbp), %rsi
xorl %edi, %edi
callq 0x37800
movq %rax, -0x48(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x31301
jmp 0x314a6
movq -0x18(%rbp), %rsi
movl $0x1, %edi
callq 0x37800
movq %rax, -0x40(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x31321
jmp 0x314a6
movq -0x18(%rbp), %rsi
movl $0x20, %edi
callq 0x37800
movq %rax, -0x50(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x31341
jmp 0x314a6
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x47d20
movq %rax, -0x60(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x31360
jmp 0x314a6
movq -0x8(%rbp), %rdi
movq -0x48(%rbp), %rsi
movq -0x60(%rbp), %rdx
movq -0x18(%rbp), %rcx
callq 0x497e0
movq %rax, -0x58(%rbp)
movq $0x0, -0x48(%rbp)
movq $0x0, -0x60(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x31397
jmp 0x314a6
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x58(%rbp), %rax
movq -0x18(%rbp), %r9
movq 0x148(%rax), %rdx
movq -0x28(%rbp), %rcx
movq -0x30(%rbp), %r8
movl $0x43, %esi
callq 0x38360
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x313ce
jmp 0x314a6
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq 0x39960
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x313f1
jmp 0x314a6
movq -0x8(%rbp), %rdi
movq -0x50(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq 0x30660
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x31410
jmp 0x314a6
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x40(%rbp), %rdx
movq -0x18(%rbp), %rcx
callq 0x492c0
movq %rax, -0x10(%rbp)
movq $0x0, -0x40(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x3143c
jmp 0x314a6
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x10(%rbp), %rax
movq -0x18(%rbp), %r8
movq -0x38(%rbp), %rdx
movq 0x148(%rax), %rcx
movl $0x1d, %esi
callq 0x385a0
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x3146c
jmp 0x314a6
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x18(%rbp), %rcx
movq -0x20(%rbp), %rdx
movl $0x45, %esi
callq 0x38540
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x31491
jmp 0x314a6
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x28(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq 0x39960
movq -0x58(%rbp), %rdi
callq 0x36ee0
movq -0x50(%rbp), %rdi
callq 0x36ee0
movq -0x40(%rbp), %rdi
callq 0x36ee0
movq -0x60(%rbp), %rdi
callq 0x36ee0
movq -0x48(%rbp), %rdi
callq 0x36ee0
movq -0x10(%rbp), %rdi
callq 0x36ee0
addq $0x60, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)