// File: /workspace/github_c_makefile_star2_O1/lucvoo[P]sparse-dev/parse.c
// Function: parse_function_body
static struct token *parse_function_body(struct token *token, struct symbol *decl,
	struct symbol_list **list)
{
	struct symbol_list **old_symbol_list;
	struct symbol *base_type = decl->ctype.base_type;
	struct statement *stmt, **p;
	struct symbol *prev;
	struct symbol *arg;

	old_symbol_list = function_symbol_list;
	if (decl->ctype.modifiers & MOD_INLINE) {
		function_symbol_list = &decl->inline_symbol_list;
		p = &base_type->inline_stmt;
	} else {
		function_symbol_list = &decl->symbol_list;
		p = &base_type->stmt;
	}
	function_computed_target_list = NULL;
	function_computed_goto_list = NULL;

	if ((decl->ctype.modifiers & (MOD_EXTERN|MOD_INLINE)) == MOD_EXTERN) {
		if (Wexternal_function_has_definition)
			warning(decl->pos, "function '%s' with external linkage has definition", show_ident(decl->ident));
	}
	if (!(decl->ctype.modifiers & MOD_STATIC))
		decl->ctype.modifiers |= MOD_EXTERN;

	stmt = start_function(decl);
	*p = stmt;

	FOR_EACH_PTR (base_type->arguments, arg) {
		declare_argument(arg, base_type);
	} END_FOR_EACH_PTR(arg);

	token = statement_list(token->next, &stmt->stmts);
	end_function(decl);

	if (!(decl->ctype.modifiers & MOD_INLINE))
		add_symbol(list, decl);
	check_declaration(decl);
	decl->definition = decl;
	prev = decl->same_symbol;
	if (prev && prev->definition) {
		warning(decl->pos, "multiple definitions for function '%s'",
			show_ident(decl->ident));
		info(prev->definition->pos, " the previous one is here");
	} else {
		while (prev) {
			rebind_scope(prev, decl->scope);
			prev->definition = decl;
			prev = prev->same_symbol;
		}
	}
	function_symbol_list = old_symbol_list;
	if (function_computed_goto_list) {
		if (!function_computed_target_list)
			warning(decl->pos, "function '%s' has computed goto but no targets?", show_ident(decl->ident));
		else {
			FOR_EACH_PTR(function_computed_goto_list, stmt) {
				stmt->target_list = function_computed_target_list;
			} END_FOR_EACH_PTR(stmt);
		}
	}
	return expect(token, '}', "at end of function");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdx, 0x10(%rsp)
movq %rsi, %r15
movq %rdi, 0x20(%rsp)
movq 0x60(%rsi), %r13
movq 0x4cc46(%rip), %rax     # 0x67f30
movq %rax, 0x28(%rsp)
movl 0x68(%rsi), %eax
movl %eax, %ebp
andl $0x40, %ebp
shrl $0x2, %ebp
leaq (%rsi,%rbp), %rcx
addq $0x98, %rcx
movq %rcx, 0x4cc24(%rip)     # 0x67f30
xorl %ecx, %ecx
movq %rcx, 0x4cc0b(%rip)     # 0x67f20
movq %rcx, 0x4cc0c(%rip)     # 0x67f28
andl $0x48, %eax
cmpl $0x8, %eax
jne 0x1b34e
leaq 0x4627d(%rip), %rax     # 0x615a8
cmpl $0x0, (%rax)
je 0x1b34e
movq 0x18(%r15), %rdi
callq 0x2e465
movq 0x4(%r15), %rdi
leaq 0x2b2c3(%rip), %rsi     # 0x46607
movq %rax, %rdx
xorl %eax, %eax
callq 0x118b4
movq 0x68(%r15), %rax
testb $0x4, %al
jne 0x1b35e
orq $0x8, %rax
movq %rax, 0x68(%r15)
addq $0x90, %rbp
movq 0x4(%r15), %rbx
xorl %edi, %edi
callq 0x3008c
movq %rax, %r12
movl $0x3, (%rax)
movq %rbx, 0x4(%rax)
callq 0x22ddf
movq 0x4(%r15), %rdi
movl $0x3, %esi
callq 0x2b547
movq %rax, %r14
movq 0x60(%r15), %rax
movups 0x60(%rax), %xmm0
movups 0x70(%rax), %xmm1
movups %xmm0, 0x60(%r14)
movups %xmm1, 0x70(%r14)
movq 0x80(%rax), %rax
movq %rax, 0x80(%r14)
movq $-0xc001000, %rax       # imm = 0xF3FFF000
andq 0x68(%r14), %rax
orq $0x3, %rax
movq %rax, 0x68(%r14)
leaq 0x49a27(%rip), %rsi     # 0x64df8
movq %r14, %rdi
movl $0x20, %edx
callq 0x2c3dd
movq %r14, 0x18(%r12)
movq 0x4cb46(%rip), %rdi     # 0x67f30
testq %rdi, %rdi
je 0x1b3f7
movq %r14, %rsi
callq 0x2285b
leaq 0x75b72(%rip), %rax     # 0x90f70
movq %r15, 0x30(%rsp)
movq %r15, (%rax)
movq %r12, 0x18(%rsp)
movq %r12, (%r13,%rbp)
movq 0x88(%r13), %rax
movq %rax, 0x8(%rsp)
testq %rax, %rax
je 0x1b4da
leaq 0x2b292(%rip), %r13     # 0x466be
leaq 0x522c5(%rip), %r12     # 0x6d6f8
leaq 0x46176(%rip), %rbp     # 0x615b0
movq 0x8(%rsp), %r15
movzwl (%r15), %eax
testb %al, %al
jle 0x1b4cb
xorl %ebx, %ebx
movq 0x18(%r15,%rbx,8), %r14
movzwl %ax, %eax
cmpl $0x100, %eax            # imm = 0x100
jb 0x1b461
testq %r14, %r14
je 0x1b4bc
movq 0x18(%r14), %rdi
testq %rdi, %rdi
je 0x1b4ae
cmpq %r12, 0x60(%r14)
jne 0x1b49b
leaq 0x512c1(%rip), %rax     # 0x6c738
movq %rax, 0x60(%r14)
cmpl $0x0, (%rbp)
je 0x1b49b
callq 0x2e465
movq 0x4(%r14), %rdi
leaq 0x2b123(%rip), %rsi     # 0x465b4
movq %rax, %rdx
xorl %eax, %eax
callq 0x11a38
movq 0x18(%r14), %rsi
movq %r14, %rdi
movl $0x10, %edx
callq 0x2c3dd
jmp 0x1b4bc
movq 0x4(%r14), %rdi
movq %r13, %rsi
xorl %eax, %eax
callq 0x11a38
incq %rbx
movl (%r15), %eax
movsbq %al, %rcx
cmpq %rcx, %rbx
jl 0x1b44d
movq 0x10(%r15), %r15
cmpq 0x8(%rsp), %r15
jne 0x1b43f
movq 0x20(%rsp), %rax
movq 0x8(%rax), %rdi
movq 0x18(%rsp), %rsi
addq $0x10, %rsi
callq 0x1a2fd
movq %rax, %r15
leaq 0x75a75(%rip), %rax     # 0x90f70
movq $0x0, (%rax)
callq 0x22ee0
movq 0x30(%rsp), %rbx
testb $0x40, 0x68(%rbx)
jne 0x1b51f
movq 0x10(%rsp), %rdi
movq %rbx, %rsi
callq 0x2285b
movq %rbx, %rdi
callq 0x2c15d
movq %rbx, 0xc8(%rbx)
movq 0x38(%rbx), %r14
testq %r14, %r14
je 0x1b596
cmpq $0x0, 0xc8(%r14)
je 0x1b57a
movq 0x18(%rbx), %rdi
callq 0x2e465
movq 0x4(%rbx), %rdi
leaq 0x2b0e5(%rip), %rsi     # 0x4663a
movq %rax, %rdx
xorl %eax, %eax
callq 0x118b4
movq 0xc8(%r14), %rax
movq 0x4(%rax), %rdi
leaq 0x2b0f0(%rip), %rsi     # 0x46661
xorl %eax, %eax
callq 0x11744
jmp 0x1b596
movq 0x30(%rbx), %rsi
movq %r14, %rdi
callq 0x22d56
movq %rbx, 0xc8(%r14)
movq 0x38(%r14), %r14
testq %r14, %r14
jne 0x1b57a
movq 0x28(%rsp), %rax
movq %rax, 0x4c98e(%rip)     # 0x67f30
movq 0x4c97f(%rip), %rax     # 0x67f28
testq %rax, %rax
je 0x1b617
movq 0x4c96b(%rip), %rcx     # 0x67f20
testq %rcx, %rcx
je 0x1b5f9
movq %rax, %rdx
movzwl (%rdx), %edi
testb %dil, %dil
jle 0x1b5ee
xorl %esi, %esi
movq 0x18(%rdx,%rsi,8), %r8
movzwl %di, %edi
cmpl $0x100, %edi            # imm = 0x100
jb 0x1b5dc
testq %r8, %r8
je 0x1b5e0
movq %rcx, 0x20(%r8)
incq %rsi
movl (%rdx), %edi
movsbq %dil, %r8
cmpq %r8, %rsi
jl 0x1b5c7
movq 0x10(%rdx), %rdx
cmpq %rax, %rdx
jne 0x1b5bd
jmp 0x1b617
movq 0x18(%rbx), %rdi
callq 0x2e465
movq 0x4(%rbx), %rdi
leaq 0x2b06e(%rip), %rsi     # 0x4667b
movq %rax, %rdx
xorl %eax, %eax
callq 0x118b4
leaq 0x2b08d(%rip), %rdx     # 0x466ab
movq %r15, %rdi
movl $0x7d, %esi
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x195d7