// File: /workspace/github_c_makefile_star2_O1/markdryan[P]subtilis/arch/arm32/assembler.c
// Function: prv_parse_fpa_stran_pre
static void prv_parse_fpa_stran_pre(subtilis_arm_ass_context_t *c,
				    subtilis_arm_instr_type_t itype,
				    subtilis_arm_ccode_type_t ccode,
				    size_t size, subtilis_arm_reg_t dest,
				    subtilis_arm_reg_t base,
				    subtilis_error_t *err)
{
	const char *tbuf;
	uint8_t offset;
	bool sub = false;
	subtilis_fpa_stran_instr_t *stran;
	subtilis_arm_instr_t *instr;
	bool write_back = false;

	offset = prv_get_fpa_stran_offset(c, &sub, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	tbuf = subtilis_token_get_text(c->t);
	if ((c->t->type != SUBTILIS_TOKEN_OPERATOR) || strcmp(tbuf, "]")) {
		subtilis_error_set_expected(err, "]", tbuf, c->l->stream->name,
					    c->l->line);
		return;
	}

	subtilis_lexer_get(c->l, c->t, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	tbuf = subtilis_token_get_text(c->t);
	if ((c->t->type == SUBTILIS_TOKEN_OPERATOR) && !strcmp(tbuf, "!")) {
		if (base == 15) {
			subtilis_error_set_ass_bad_reg(
			    err, "R15", c->l->stream->name, c->l->line);
			return;
		}
		write_back = true;
		subtilis_lexer_get(c->l, c->t, err);
		if (err->type != SUBTILIS_ERROR_OK)
			return;
	}

	instr = subtilis_arm_section_add_instr(c->arm_s, itype, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	stran = &instr->operands.fpa_stran;
	stran->ccode = ccode;
	stran->size = size;
	stran->dest = dest;
	stran->base = base;
	stran->offset = offset;
	stran->pre_indexed = true;
	stran->write_back = write_back;
	stran->subtract = sub;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r9, 0x8(%rsp)
movq %r8, %rbp
movq %rcx, %r13
movl %edx, %ebx
movl %esi, %r14d
movq %rdi, %r12
movq 0x50(%rsp), %r15
leaq 0x7(%rsp), %rsi
movb $0x0, (%rsi)
movq %r15, %rdx
callq 0x6726b
cmpl $0x0, (%r15)
je 0x66fa1
addq $0x18, %rsp
jmp 0x6700c
movb %al, 0x6(%rsp)
movq %rbp, 0x10(%rsp)
movq 0x10(%r12), %rdi
callq 0x12ad0
movq %rax, %r15
movq 0x10(%r12), %rbp
cmpl $0x2, (%rbp)
jne 0x66fd5
leaq 0xfe6b(%rip), %rsi      # 0x76e34
movq %r15, %rdi
callq 0x12160
testl %eax, %eax
je 0x67017
movq 0x8(%r12), %rax
movq 0x30(%rax), %r8
movl 0x38(%rax), %r9d
leaq 0xfd27(%rip), %rax      # 0x76d10
leaq 0xfe44(%rip), %rdx      # 0x76e34
movq 0x50(%rsp), %rdi
movl $0x1d, %esi
movq %r15, %rcx
pushq $0x938                  # imm = 0x938
pushq %rax
callq 0x1442a
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x8(%r12), %rdi
movq %rbp, %rsi
movq %r12, %rbp
movq 0x50(%rsp), %r15
movq %r15, %rdx
callq 0x12eda
cmpl $0x0, (%r15)
jne 0x66f9b
movq 0x10(%rbp), %rdi
callq 0x12ad0
movq 0x10(%rbp), %r12
cmpl $0x2, (%r12)
movq %rbp, %r15
jne 0x67063
leaq 0xc462(%rip), %rsi      # 0x734b9
movq %rax, %rdi
callq 0x12160
testl %eax, %eax
je 0x670b6
xorl %ebp, %ebp
movq 0x8(%rsp), %r12
movq 0x50(%rsp), %rdx
movq (%r15), %rdi
movl %r14d, %esi
movq %rdx, %r14
callq 0x4f73a
cmpl $0x0, (%r14)
movq 0x10(%rsp), %rcx
movb 0x6(%rsp), %dl
jne 0x66f9b
movl %ebx, 0x8(%rax)
movq %r13, 0x10(%rax)
movq %rcx, 0x18(%rax)
movq %r12, 0x20(%rax)
movb %dl, 0x28(%rax)
movb $0x1, 0x29(%rax)
movb %bpl, 0x2a(%rax)
movb 0x7(%rsp), %cl
movb %cl, 0x2b(%rax)
jmp 0x66f9b
movq 0x8(%r15), %rdi
cmpq $0xf, 0x8(%rsp)
jne 0x670f3
movq 0x30(%rdi), %r8
movl 0x38(%rdi), %r9d
leaq 0xfc3f(%rip), %rax      # 0x76d10
leaq 0xfcc8(%rip), %rdx      # 0x76da0
leaq 0xcd16(%rip), %rcx      # 0x73df5
movq 0x50(%rsp), %rdi
movl $0x58, %esi
pushq $0x944                  # imm = 0x944
jmp 0x67002
movq %r12, %rsi
movq %r15, %rbp
movq 0x50(%rsp), %r15
movq %r15, %rdx
callq 0x12eda
cmpl $0x0, (%r15)
movq 0x8(%rsp), %r12
jne 0x66f9b
movq %rbp, %rax
movb $0x1, %bpl
movq %r15, %rdx
movq %rax, %r15
jmp 0x6706f