// File: /workspace/github_c_makefile_star2_O0/Oric4ever[P]lcc65/6502/build/../src/enode.c
// Function: callnode
Tree callnode(Tree f, Type ty, Tree args) {
	Tree p;

	if (args)
		f = tree(RIGHT, f->type, args, f);
	if (isstruct(ty)) {
		Symbol t1 = temporary(AUTO, unqual(ty));
		if (ty->size == 0)
			error("illegal use of incomplete type `%t'\n", ty);
		p = tree(RIGHT, ty, tree(CALL+B, ty, f, lvalue(idnode(t1))),
			idnode(t1));
	} else {
		Type rty = ty;
		if (isenum(ty))
			rty = unqual(ty)->type;
		else if (isptr(ty))
			rty = unsignedtype;
		p = tree(CALL + widen(rty), rty, f, 0);
		if (isptr(ty))
			p = cast(p, ty);
	}
	return p;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xb0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
je 0xc99c
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rsi
movq -0x18(%rbp), %rdx
movq -0x8(%rbp), %rcx
movl $0x2a0, %edi            # imm = 0x2A0
callq 0x256f0
movq %rax, -0x8(%rbp)
movq -0x10(%rbp), %rax
cmpl $0xf, (%rax)
jb 0xc9b3
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x38(%rbp)
jmp 0xc9bb
movq -0x10(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
cmpl $0x9, (%rax)
je 0xc9f0
movq -0x10(%rbp), %rax
cmpl $0xf, (%rax)
jb 0xc9db
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x40(%rbp)
jmp 0xc9e3
movq -0x10(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
cmpl $0xa, (%rax)
jne 0xcaa6
movq -0x10(%rbp), %rax
cmpl $0xf, (%rax)
jb 0xca07
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x48(%rbp)
jmp 0xca0f
movq -0x10(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x48(%rbp), %rsi
movl $0x43, %edi
callq 0x250c0
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x0, 0x8(%rax)
jne 0xca3d
movq -0x10(%rbp), %rsi
leaq 0x22c03(%rip), %rdi     # 0x2f639
movb $0x0, %al
callq 0xd530
movq -0x10(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x68(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0x28(%rbp), %rdi
callq 0xddf0
movq %rax, %rdi
callq 0x10510
movq -0x68(%rbp), %rsi
movq -0x60(%rbp), %rdx
movq %rax, %rcx
movl $0xd9, %edi
callq 0x256f0
movq %rax, -0x50(%rbp)
movq -0x28(%rbp), %rdi
callq 0xddf0
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq %rax, %rcx
movl $0x2a0, %edi            # imm = 0x2A0
callq 0x256f0
movq %rax, -0x20(%rbp)
jmp 0xcc4f
movq -0x10(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
cmpl $0xf, (%rax)
jb 0xcac5
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x70(%rbp)
jmp 0xcacd
movq -0x10(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x70(%rbp), %rax
cmpl $0xd, (%rax)
jne 0xcb03
movq -0x10(%rbp), %rax
cmpl $0xf, (%rax)
jb 0xcaed
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x78(%rbp)
jmp 0xcaf5
movq -0x10(%rbp), %rax
movq %rax, -0x78(%rbp)
movq -0x78(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x30(%rbp)
jmp 0xcb3b
movq -0x10(%rbp), %rax
cmpl $0xf, (%rax)
jb 0xcb1a
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x80(%rbp)
jmp 0xcb22
movq -0x10(%rbp), %rax
movq %rax, -0x80(%rbp)
movq -0x80(%rbp), %rax
cmpl $0x7, (%rax)
jne 0xcb39
leaq 0x37706(%rip), %rax     # 0x44238
movq (%rax), %rax
movq %rax, -0x30(%rbp)
jmp 0xcb3b
movq -0x30(%rbp), %rax
cmpl $0xf, (%rax)
jb 0xcb55
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x88(%rbp)
jmp 0xcb60
movq -0x30(%rbp), %rax
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rax
cmpl $0x3, (%rax)
jb 0xcb9d
movq -0x30(%rbp), %rax
cmpl $0xf, (%rax)
jb 0xcb86
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x90(%rbp)
jmp 0xcb91
movq -0x30(%rbp), %rax
movq %rax, -0x90(%rbp)
movq -0x90(%rbp), %rax
cmpl $0x6, (%rax)
jbe 0xcbce
movq -0x30(%rbp), %rax
cmpl $0xf, (%rax)
jb 0xcbb7
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x98(%rbp)
jmp 0xcbc2
movq -0x30(%rbp), %rax
movq %rax, -0x98(%rbp)
movq -0x98(%rbp), %rax
cmpl $0xd, (%rax)
jne 0xcbdb
movl $0x5, %eax
movl %eax, -0x9c(%rbp)
jmp 0xcbea
movq -0x30(%rbp), %rdi
callq 0x29e30
movl %eax, -0x9c(%rbp)
movl -0x9c(%rbp), %edi
addl $0xd0, %edi
movq -0x30(%rbp), %rsi
movq -0x8(%rbp), %rdx
xorl %eax, %eax
movl %eax, %ecx
callq 0x256f0
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
cmpl $0xf, (%rax)
jb 0xcc25
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0xa8(%rbp)
jmp 0xcc30
movq -0x10(%rbp), %rax
movq %rax, -0xa8(%rbp)
movq -0xa8(%rbp), %rax
cmpl $0x7, (%rax)
jne 0xcc4d
movq -0x20(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0xe9b0
movq %rax, -0x20(%rbp)
jmp 0xcc4f
movq -0x20(%rbp), %rax
addq $0xb0, %rsp
popq %rbp
retq
nopl (%rax)