// File: /workspace/github_c_makefile_star2_O0/markdryan[P]subtilis/frontend/builtins_ir.c
// Function: prv_compute_fractional_part
static void prv_compute_fractional_part(subtilis_parser_t *p,
					subtilis_ir_operand_t end_str,
					subtilis_ir_operand_t ptr,
					subtilis_ir_operand_t ret_val,
					subtilis_ir_operand_t factor,
					subtilis_error_t *err)
{
	subtilis_ir_operand_t condee;
	subtilis_ir_operand_t byte;
	subtilis_ir_operand_t bytef;
	subtilis_ir_operand_t op1;
	subtilis_ir_operand_t le_9;
	subtilis_ir_operand_t product;
	subtilis_ir_operand_t have_fractional_label;
	subtilis_ir_operand_t no_fractional_label;
	subtilis_ir_operand_t decimal_point_label;
	subtilis_ir_operand_t process_digit_label;
	subtilis_ir_operand_t keep_looking_label;
	subtilis_ir_operand_t loop_label;

	have_fractional_label.label = subtilis_ir_section_new_label(p->current);
	no_fractional_label.label = subtilis_ir_section_new_label(p->current);
	decimal_point_label.label = subtilis_ir_section_new_label(p->current);
	process_digit_label.label = subtilis_ir_section_new_label(p->current);
	keep_looking_label.label = subtilis_ir_section_new_label(p->current);
	loop_label.label = subtilis_ir_section_new_label(p->current);

	op1.integer = 0;
	condee.reg = subtilis_ir_section_add_instr(
	    p->current, SUBTILIS_OP_INSTR_LT_I32, ptr, end_str, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	subtilis_ir_section_add_instr_reg(p->current, SUBTILIS_OP_INSTR_JMPC,
					  condee, have_fractional_label,
					  no_fractional_label, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	subtilis_ir_section_add_label(p->current, have_fractional_label.label,
				      err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	op1.integer = 0;
	byte.reg = subtilis_ir_section_add_instr(
	    p->current, SUBTILIS_OP_INSTR_LOADO_I8, ptr, op1, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	op1.integer = '.';
	condee.reg = subtilis_ir_section_add_instr(
	    p->current, SUBTILIS_OP_INSTR_EQI_I32, byte, op1, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	subtilis_ir_section_add_instr_reg(p->current, SUBTILIS_OP_INSTR_JMPC,
					  condee, decimal_point_label,
					  no_fractional_label, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	subtilis_ir_section_add_label(p->current, decimal_point_label.label,
				      err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	op1.real = 0.1;
	factor.reg = subtilis_ir_section_add_instr(
	    p->current, SUBTILIS_OP_INSTR_MULI_REAL, factor, op1, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	subtilis_ir_section_add_label(p->current, loop_label.label, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	op1.integer = 1;
	subtilis_ir_section_add_instr_reg(
	    p->current, SUBTILIS_OP_INSTR_ADDI_I32, ptr, ptr, op1, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	condee.reg = subtilis_ir_section_add_instr(
	    p->current, SUBTILIS_OP_INSTR_LT_I32, ptr, end_str, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	subtilis_ir_section_add_instr_reg(p->current, SUBTILIS_OP_INSTR_JMPC,
					  condee, keep_looking_label,
					  no_fractional_label, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	subtilis_ir_section_add_label(p->current, keep_looking_label.label,
				      err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	op1.integer = 0;
	subtilis_ir_section_add_instr_reg(
	    p->current, SUBTILIS_OP_INSTR_LOADO_I8, byte, ptr, op1, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	op1.integer = '0';
	condee.reg = subtilis_ir_section_add_instr(
	    p->current, SUBTILIS_OP_INSTR_GTEI_I32, byte, op1, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	op1.integer = '9';
	le_9.reg = subtilis_ir_section_add_instr(
	    p->current, SUBTILIS_OP_INSTR_LTEI_I32, byte, op1, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	condee.reg = subtilis_ir_section_add_instr(
	    p->current, SUBTILIS_OP_INSTR_AND_I32, condee, le_9, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	subtilis_ir_section_add_instr_reg(p->current, SUBTILIS_OP_INSTR_JMPC,
					  condee, process_digit_label,
					  no_fractional_label, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	subtilis_ir_section_add_label(p->current, process_digit_label.label,
				      err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	op1.integer = '0';
	subtilis_ir_section_add_instr_reg(
	    p->current, SUBTILIS_OP_INSTR_SUBI_I32, byte, byte, op1, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	bytef.reg = subtilis_ir_section_add_instr2(
	    p->current, SUBTILIS_OP_INSTR_MOV_I32_FP, byte, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	product.reg = subtilis_ir_section_add_instr(
	    p->current, SUBTILIS_OP_INSTR_MUL_REAL, bytef, factor, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	op1.real = 0.1;
	subtilis_ir_section_add_instr_reg(
	    p->current, SUBTILIS_OP_INSTR_MULI_REAL, factor, factor, op1, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	subtilis_ir_section_add_instr_reg(p->current,
					  SUBTILIS_OP_INSTR_ADD_REAL, ret_val,
					  ret_val, product, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	subtilis_ir_section_add_instr_no_reg(p->current, SUBTILIS_OP_INSTR_JMP,
					     loop_label, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

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

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rsi, -0x8(%rbp)
movq %rdx, -0x10(%rbp)
movq %rcx, -0x18(%rbp)
movq %r8, -0x20(%rbp)
movq %rdi, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
callq 0x39940
movq %rax, -0x68(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
callq 0x39940
movq %rax, -0x70(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
callq 0x39940
movq %rax, -0x78(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
callq 0x39940
movq %rax, -0x80(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
callq 0x39940
movq %rax, -0x88(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
callq 0x39940
movq %rax, -0x90(%rbp)
movl $0x0, -0x50(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r8
movq -0x10(%rbp), %rdx
movq -0x8(%rbp), %rcx
movl $0x3b, %esi
callq 0x38230
movq %rax, -0x38(%rbp)
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x422e6
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r9
movq -0x38(%rbp), %rdx
movq -0x68(%rbp), %rcx
movq -0x70(%rbp), %r8
movl $0x43, %esi
callq 0x38360
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x42316
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x68(%rbp), %rsi
movq -0x30(%rbp), %rdx
callq 0x39960
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x42339
jmp 0x4277c
movl $0x0, -0x50(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r8
movq -0x10(%rbp), %rdx
movq -0x50(%rbp), %rcx
movl $0x11, %esi
callq 0x38230
movq %rax, -0x40(%rbp)
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x42370
jmp 0x4277c
movl $0x2e, -0x50(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r8
movq -0x40(%rbp), %rdx
movq -0x50(%rbp), %rcx
movl $0x2d, %esi
callq 0x38230
movq %rax, -0x38(%rbp)
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x423a7
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r9
movq -0x38(%rbp), %rdx
movq -0x78(%rbp), %rcx
movq -0x70(%rbp), %r8
movl $0x43, %esi
callq 0x38360
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x423d7
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x78(%rbp), %rsi
movq -0x30(%rbp), %rdx
callq 0x39960
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x423fa
jmp 0x4277c
movsd 0x69e36(%rip), %xmm0    # 0xac238
movsd %xmm0, -0x50(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r8
movq -0x20(%rbp), %rdx
movq -0x50(%rbp), %rcx
movl $0xe, %esi
callq 0x38230
movq %rax, -0x20(%rbp)
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x42437
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x90(%rbp), %rsi
movq -0x30(%rbp), %rdx
callq 0x39960
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x4245d
jmp 0x4277c
movl $0x1, -0x50(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r9
movq -0x10(%rbp), %rdx
movq -0x10(%rbp), %rcx
movq -0x50(%rbp), %r8
movl $0x9, %esi
callq 0x38360
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x42494
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r8
movq -0x10(%rbp), %rdx
movq -0x8(%rbp), %rcx
movl $0x3b, %esi
callq 0x38230
movq %rax, -0x38(%rbp)
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x424c4
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r9
movq -0x38(%rbp), %rdx
movq -0x88(%rbp), %rcx
movq -0x70(%rbp), %r8
movl $0x43, %esi
callq 0x38360
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x424f7
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x88(%rbp), %rsi
movq -0x30(%rbp), %rdx
callq 0x39960
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x4251d
jmp 0x4277c
movl $0x0, -0x50(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r9
movq -0x40(%rbp), %rdx
movq -0x10(%rbp), %rcx
movq -0x50(%rbp), %r8
movl $0x11, %esi
callq 0x38360
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x42554
jmp 0x4277c
movl $0x30, -0x50(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r8
movq -0x40(%rbp), %rdx
movq -0x50(%rbp), %rcx
movl $0x41, %esi
callq 0x38230
movq %rax, -0x38(%rbp)
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x4258b
jmp 0x4277c
movl $0x39, -0x50(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r8
movq -0x40(%rbp), %rdx
movq -0x50(%rbp), %rcx
movl $0x39, %esi
callq 0x38230
movq %rax, -0x58(%rbp)
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x425c2
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r8
movq -0x38(%rbp), %rdx
movq -0x58(%rbp), %rcx
movl $0x24, %esi
callq 0x38230
movq %rax, -0x38(%rbp)
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x425f2
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r9
movq -0x38(%rbp), %rdx
movq -0x80(%rbp), %rcx
movq -0x70(%rbp), %r8
movl $0x43, %esi
callq 0x38360
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x42622
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x80(%rbp), %rsi
movq -0x30(%rbp), %rdx
callq 0x39960
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x42645
jmp 0x4277c
movl $0x30, -0x50(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r9
movq -0x40(%rbp), %rdx
movq -0x40(%rbp), %rcx
movq -0x50(%rbp), %r8
movl $0xb, %esi
callq 0x38360
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x4267c
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %rcx
movq -0x40(%rbp), %rdx
movl $0x51, %esi
callq 0x38490
movq %rax, -0x48(%rbp)
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x426a8
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r8
movq -0x48(%rbp), %rdx
movq -0x20(%rbp), %rcx
movl $0x5, %esi
callq 0x38230
movq %rax, -0x60(%rbp)
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x426d8
jmp 0x4277c
movsd 0x69b58(%rip), %xmm0    # 0xac238
movsd %xmm0, -0x50(%rbp)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r9
movq -0x20(%rbp), %rdx
movq -0x20(%rbp), %rcx
movq -0x50(%rbp), %r8
movl $0xe, %esi
callq 0x38360
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x42712
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %r9
movq -0x18(%rbp), %rdx
movq -0x18(%rbp), %rcx
movq -0x60(%rbp), %r8
movl $0x1, %esi
callq 0x38360
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x4273f
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x30(%rbp), %rcx
movq -0x90(%rbp), %rdx
movl $0x45, %esi
callq 0x38540
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x42767
jmp 0x4277c
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x70(%rbp), %rsi
movq -0x30(%rbp), %rdx
callq 0x39960
addq $0x90, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)