// File: /workspace/github_c_makefile_star2_O3/markdryan[P]subtilis/frontend/parser_call.c
// Function: prv_init_block_variables
static size_t prv_init_block_variables(subtilis_parser_t *p,
				       subtilis_type_section_t *stype,
				       subtilis_symbol_table_t *local_st,
				       const subtilis_symbol_t **symbols,
				       subtilis_error_t *err)
{
	size_t i;
	const subtilis_type_t *t;
	subtilis_ir_operand_t dest_op;
	subtilis_ir_operand_t source_op;
	size_t rs;
	size_t blocks = 0;
	size_t source_reg = SUBTILIS_IR_REG_TEMP_START;

	dest_op.reg = SUBTILIS_IR_REG_LOCAL;
	for (i = 0; i < stype->type.params.fn.num_params; i++) {
		t = stype->type.params.fn.params[i];
		if (subtilis_type_if_is_array(t) ||
		    subtilis_type_if_is_vector(t)) {
			blocks++;
			source_op.reg = source_reg++;
			subtlis_array_type_copy_param_ref(
			    p, t, dest_op, symbols[i]->loc, source_op, 0, err);
		} else if (t->type == SUBTILIS_TYPE_STRING) {
			blocks++;
			subtilis_reference_type_copy_ref(p, t, dest_op.reg,
							 symbols[i]->loc,
							 source_reg++, err);
		} else if (t->type == SUBTILIS_TYPE_REC) {
			subtilis_rec_type_copy(p, t, dest_op.reg,
					       symbols[i]->loc, source_reg++,
					       true, err);
			if (err->type != SUBTILIS_ERROR_OK)
				return 0;
			if (subtilis_type_rec_need_deref(t)) {
				blocks++;
				rs = subtilis_reference_get_pointer(
				    p, dest_op.reg, symbols[i]->loc, err);
				if (err->type != SUBTILIS_ERROR_OK)
					return 0;
				subtilis_reference_push_ref(p, t, rs, err);
			}
		} else if (subtilis_type_if_reg_type(t) ==
			   SUBTILIS_IR_REG_TYPE_INTEGER) {
			source_reg++;
		}
		if (err->type != SUBTILIS_ERROR_OK)
			return 0;
	}

	return blocks;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, 0x18(%rsp)
cmpq $0x0, 0x10(%rsi)
je 0x1d80b
movq %rcx, %rbx
movq %rdi, 0x10(%rsp)
movl $0x4, %r12d
xorl %ebp, %ebp
xorl %r13d, %r13d
movq %rsi, 0x20(%rsp)
movq 0x18(%rsi,%r13,8), %r14
movq %r14, %rdi
callq 0x376b5
testb %al, %al
jne 0x1d6d4
movq %r14, %rdi
callq 0x376d3
testb %al, %al
je 0x1d729
incq %rbp
movq %rbp, %r15
leaq 0x1(%r12), %rbp
movq 0x18(%rsp), %rax
movq (%rax,%r13,8), %rax
movq (%rax), %rcx
movq %rbx, (%rsp)
movl $0x2, %edx
movq 0x10(%rsp), %rdi
movq %r14, %rsi
movq %r12, %r8
xorl %r9d, %r9d
callq 0x42deb
movq %rbp, %r12
cmpl $0x0, (%rbx)
movq 0x20(%rsp), %rsi
jne 0x1d80b
incq %r13
cmpq 0x10(%rsi), %r13
movq %r15, %rbp
jb 0x1d6b7
jmp 0x1d80d
movl (%r14), %eax
cmpl $0x16, %eax
je 0x1d76b
cmpl $0x7, %eax
jne 0x1d7ec
incq %rbp
movq %rbp, %r15
movq 0x18(%rsp), %rax
movq (%rax,%r13,8), %rax
movq (%rax), %rcx
leaq 0x1(%r12), %rbp
movl $0x2, %edx
movq 0x10(%rsp), %rdi
movq %r14, %rsi
movq %r12, %r8
movq %rbx, %r9
callq 0x4d076
jmp 0x1d707
movq 0x18(%rsp), %rax
movq (%rax,%r13,8), %rax
movq (%rax), %rcx
movq %rbx, (%rsp)
movl $0x2, %edx
movq 0x10(%rsp), %rdi
movq %r14, %rsi
movq %r12, %r8
movl $0x1, %r9d
callq 0x45fae
cmpl $0x0, (%rbx)
jne 0x1d80b
incq %r12
movq %r14, %rdi
callq 0x30171
testb %al, %al
je 0x1d803
movq 0x18(%rsp), %rax
movq (%rax,%r13,8), %rax
movq (%rax), %rdx
movl $0x2, %esi
movq 0x10(%rsp), %r15
movq %r15, %rdi
movq %rbx, %rcx
callq 0x4d71f
cmpl $0x0, (%rbx)
jne 0x1d80b
incq %rbp
movq %r15, %rdi
movq %rbp, %r15
movq %r14, %rsi
movq %rax, %rdx
movq %rbx, %rcx
callq 0x4cfe9
jmp 0x1d70a
movq %rbp, %r15
movq %r14, %rdi
callq 0x379a7
cmpl $0x1, %eax
adcq $0x0, %r12
jmp 0x1d70a
movq %rbp, %r15
jmp 0x1d70a
xorl %ebp, %ebp
movq %rbp, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq