// File: /workspace/github_c_makefile_star2_O0/lucvoo[P]sparse-dev/parse.c
// Function: apply_k_r_types
static void apply_k_r_types(struct symbol_list *argtypes, struct symbol *fn)
{
	struct symbol_list *real_args = fn->ctype.base_type->arguments;
	struct symbol *arg;

	FOR_EACH_PTR(real_args, arg) {
		struct symbol *type;

		/* This is quadratic in the number of arguments. We _really_ don't care */
		FOR_EACH_PTR(argtypes, type) {
			if (type->ident == arg->ident)
				goto match;
		} END_FOR_EACH_PTR(type);
		if (Wimplicit_int) {
			warning(arg->pos, "missing type declaration for parameter '%s'",
				show_ident(arg->ident));
		}
		type = alloc_symbol(arg->pos, SYM_NODE);
		type->ident = arg->ident;
		type->ctype.base_type = &int_ctype;
match:
		type->used = 1;
		/* "char" and "short" promote to "int" */
		promote_k_r_types(type);

		arg->ctype = type->ctype;
	} END_FOR_EACH_PTR(arg);

	FOR_EACH_PTR(argtypes, arg) {
		if (!arg->used)
			warning(arg->pos, "nonsensical parameter declaration '%s'", show_ident(arg->ident));
	} END_FOR_EACH_PTR(arg);

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x60(%rax), %rax
movq 0x88(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x28(%rbp), %rax
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x28(%rbp)
jne 0x29dca
jmp 0x29fa7
jmp 0x29dcc
movl $0x0, -0x3c(%rbp)
movl -0x3c(%rbp), %eax
movq -0x30(%rbp), %rcx
movw (%rcx), %cx
shlw $0x8, %cx
sarw $0x8, %cx
movswl %cx, %ecx
cmpl %ecx, %eax
jge 0x29f8f
movq -0x30(%rbp), %rax
movslq -0x3c(%rbp), %rcx
movq 0x18(%rax,%rcx,8), %rax
movq %rax, -0x20(%rbp)
movq -0x30(%rbp), %rax
movw (%rax), %ax
sarw $0x8, %ax
cwtl
cmpl $0x0, %eax
je 0x29e1e
cmpq $0x0, -0x20(%rbp)
jne 0x29e1e
jmp 0x29f81
jmp 0x29e20
movq -0x8(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x60(%rbp)
cmpq $0x0, -0x50(%rbp)
jne 0x29e44
jmp 0x29ecd
jmp 0x29e46
movl $0x0, -0x64(%rbp)
movl -0x64(%rbp), %eax
movq -0x58(%rbp), %rcx
movw (%rcx), %cx
shlw $0x8, %cx
sarw $0x8, %cx
movswl %cx, %ecx
cmpl %ecx, %eax
jge 0x29eb5
movq -0x58(%rbp), %rax
movslq -0x64(%rbp), %rcx
movq 0x18(%rax,%rcx,8), %rax
movq %rax, -0x48(%rbp)
movq -0x58(%rbp), %rax
movw (%rax), %ax
sarw $0x8, %ax
cwtl
cmpl $0x0, %eax
je 0x29e91
cmpq $0x0, -0x48(%rbp)
jne 0x29e91
jmp 0x29eaa
movq -0x48(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x20(%rbp), %rcx
cmpq 0x18(%rcx), %rax
jne 0x29ea8
jmp 0x29f42
jmp 0x29eaa
movl -0x64(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x64(%rbp)
jmp 0x29e4d
jmp 0x29eb7
movq -0x58(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x58(%rbp)
cmpq -0x50(%rbp), %rax
jne 0x29e46
leaq 0x5a95c(%rip), %rax     # 0x84830
cmpl $0x0, (%rax)
je 0x29f0d
movq -0x20(%rbp), %rax
movq %rax, -0x90(%rbp)
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x44150
movq %rax, %rdx
movq -0x90(%rbp), %rax
movq 0x4(%rax), %rdi
leaq 0x3cfe2(%rip), %rsi     # 0x66ee8
movb $0x0, %al
callq 0x16d80
movq -0x20(%rbp), %rax
movq 0x4(%rax), %rdi
movl $0x3, %esi
callq 0x3f4d0
movq %rax, -0x48(%rbp)
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rcx
movq -0x48(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x48(%rbp), %rax
leaq 0x67bda(%rip), %rcx     # 0x91b18
movq %rcx, 0x60(%rax)
movq -0x48(%rbp), %rax
movl (%rax), %ecx
andl $0xfffdffff, %ecx       # imm = 0xFFFDFFFF
orl $0x20000, %ecx          # imm = 0x20000
movl %ecx, (%rax)
movq -0x48(%rbp), %rdi
callq 0x2a0b0
movq -0x20(%rbp), %rdi
addq $0x48, %rdi
addq $0x18, %rdi
movq -0x48(%rbp), %rsi
addq $0x48, %rsi
addq $0x18, %rsi
movl $0x28, %edx
callq 0x111d0
movl -0x3c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x3c(%rbp)
jmp 0x29dd3
jmp 0x29f91
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x30(%rbp)
cmpq -0x28(%rbp), %rax
jne 0x29dcc
jmp 0x29fa9
movq -0x8(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x70(%rbp), %rax
movq %rax, -0x78(%rbp)
movq -0x70(%rbp), %rax
movq %rax, -0x80(%rbp)
cmpq $0x0, -0x70(%rbp)
jne 0x29fcd
jmp 0x2a099
jmp 0x29fcf
movl $0x0, -0x84(%rbp)
movl -0x84(%rbp), %eax
movq -0x78(%rbp), %rcx
movw (%rcx), %cx
shlw $0x8, %cx
sarw $0x8, %cx
movswl %cx, %ecx
cmpl %ecx, %eax
jge 0x2a081
movq -0x78(%rbp), %rax
movslq -0x84(%rbp), %rcx
movq 0x18(%rax,%rcx,8), %rax
movq %rax, -0x20(%rbp)
movq -0x78(%rbp), %rax
movw (%rax), %ax
sarw $0x8, %ax
cwtl
cmpl $0x0, %eax
je 0x2a027
cmpq $0x0, -0x20(%rbp)
jne 0x2a027
jmp 0x2a06d
movq -0x20(%rbp), %rax
movl (%rax), %eax
shrl $0x11, %eax
andl $0x1, %eax
cmpb $0x0, %al
jne 0x2a06b
movq -0x20(%rbp), %rax
movq %rax, -0x98(%rbp)
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x44150
movq %rax, %rdx
movq -0x98(%rbp), %rax
movq 0x4(%rax), %rdi
leaq 0x3ceb0(%rip), %rsi     # 0x66f14
movb $0x0, %al
callq 0x16d80
jmp 0x2a06d
movl -0x84(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x84(%rbp)
jmp 0x29fd9
jmp 0x2a083
movq -0x78(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x78(%rbp)
cmpq -0x70(%rbp), %rax
jne 0x29fcf
addq $0xa0, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)