// File: /workspace/github_c_makefile_star2_O2/Oric4ever[P]lcc65/6502/build/../src/expr.c
// Function: postfix
static Tree postfix(p) Tree p; {
	Tree q;
	Type ty;

	for (;;)
		switch (t) {
		case INCR: case DECR:
			p = tree(RIGHT, p->type,
				tree(RIGHT, p->type, p, root(incr(t, p, constnode(1, inttype)))),
				p);
			t = gettok();
			continue;
		case '[':
			t = gettok();
			q = expr(']');
			if (YYnull)
				if (isptr(p->type))
					p = nullcheck(p);
				else if (isptr(q->type))
					q = nullcheck(q);
			q = pointer(q);
			p = (*opnode['+'])(ADD, pointer(p), q);
			if (isptr(p->type) && isarray(p->type->type))
				p = retype(p, p->type->type);
			else
				p = rvalue(p);
			continue;
		case '(': {
			Coordinate pt;
			p = pointer(p);
			if (isptr(p->type) && isfunc(p->type->type))
				ty = p->type->type;
			else {
				error("found `%t' expected a function\n", p->type);
				ty = func(voidtype, 0);
			}
			pt = src;
			t = gettok();
			p = call(p, ty, pt);
			continue;
			}
		case '.':
			t = gettok();
			if (t == ID) {
				if (isstruct(p->type)) {
					q = addrof(p);
					p = field(q, token);	/* refme */
					q = rightkid(q);
					if (isaddrop(q->op) && q->u.sym->temporary) {
						p = tree(RIGHT, p->type, p, 0);
						p->u.sym = q->u.sym;
					}
				} else
					error("left operand of . has incompatible type `%t'\n",
						p->type);
				t = gettok();
			} else
				error("field name expected\n");
			continue;
		case DEREF:
			t = gettok();
			p = pointer(p);
			if (t == ID) {
				if (isptr(p->type))
					ty = deref(p->type);
				if (isptr(p->type) && isstruct(ty)) {
					if (YYnull)
						p = nullcheck(p);
					p = field(p, token);	/* refme */
				} else
					error("left operand of -> has incompatible type `%t'\n",
						p->type);
				t = gettok();
			} else
				error("field name expected\n");
			continue;
		default:
			return p;
		}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
leaq 0x20411(%rip), %r14     # 0x2b9e0
leaq 0x2048a(%rip), %rbp     # 0x2ba60
leaq 0x11867(%rip), %r12     # 0x1ce44
movl (%r14), %r15d
leal -0x27(%r15), %eax
cmpl $0xa, %eax
ja 0xb654
movslq (%r12,%rax,4), %rax
addq %r12, %rax
jmpq *%rax
movq 0x8(%rbx), %r13
leaq 0x2699b(%rip), %rax     # 0x31f98
movq (%rax), %rsi
pushq $0x1
popq %rdi
callq 0x8726
movl %r15d, %edi
movq %rbx, %rsi
movq %rax, %rdx
callq 0xa65e
movq %rax, %rdi
callq 0x16750
movl $0x2a0, %edi            # imm = 0x2A0
movq %r13, %rsi
movq %rbx, %rdx
movq %rax, %rcx
callq 0x165eb
movl $0x2a0, %edi            # imm = 0x2A0
movq %r13, %rsi
movq %rax, %rdx
movq %rbx, %rcx
callq 0x165eb
movq %rax, %rbx
callq 0xd3c9
movl %eax, %r15d
movl %eax, (%r14)
jmp 0xb5e0
cmpl $0x5b, %r15d
jne 0xbce5
callq 0xd3c9
movl %eax, (%r14)
pushq $0x5d
popq %rdi
callq 0xa33c
movq %rax, %r15
cmpq $0x0, (%rbp)
je 0xbc46
movq 0x8(%rbx), %rcx
movl (%rcx), %eax
cmpl $0xf, %eax
jb 0xb68d
movq 0x10(%rcx), %rax
movl (%rax), %eax
cmpl $0x7, %eax
jne 0xbc25
movq %rbx, %rdi
callq 0xb4bf
movq %rax, %rbx
jmp 0xbc46
callq 0xd3c9
movl %eax, (%r14)
movq %rbx, %rdi
callq 0xa22f
movq %rax, %rbx
cmpl $0x20, (%r14)
jne 0xb800
movq 0x8(%rbx), %rsi
movl (%rsi), %edx
movl %edx, %ecx
cmpl $0xf, %edx
movq 0x8(%rsp), %rax
jb 0xb6db
movq 0x10(%rsi), %rcx
movl (%rcx), %ecx
cmpl $0x7, %ecx
jne 0xb6ee
movq %rsi, %rdi
callq 0x17af2
movq 0x8(%rbx), %rsi
movl (%rsi), %edx
cmpl $0xf, %edx
jb 0xb6f9
movq 0x10(%rsi), %rcx
movl (%rcx), %edx
cmpl $0x7, %edx
movq %rax, 0x8(%rsp)
jne 0xbcdc
movl (%rax), %ecx
cmpl $0xf, %ecx
jb 0xb714
movq 0x10(%rax), %rcx
movl (%rcx), %ecx
cmpl $0x9, %ecx
je 0xb722
cmpl $0xa, %ecx
jne 0xbcdc
cmpq $0x0, (%rbp)
je 0xb734
movq %rbx, %rdi
callq 0xb4bf
movq %rax, %rbx
leaq 0x2020d(%rip), %rax     # 0x2b948
movq (%rax), %rsi
movq %rbx, %rdi
callq 0xa68b
movq %rax, %rbx
jmp 0xbccf
callq 0xd3c9
movl %eax, (%r14)
cmpl $0x20, %eax
jne 0xb800
movq 0x8(%rbx), %rsi
movl (%rsi), %eax
cmpl $0xf, %eax
jb 0xb770
movq 0x10(%rsi), %rax
movl (%rax), %eax
cmpl $0x9, %eax
je 0xb77e
cmpl $0xa, %eax
jne 0xbcc1
movq %rbx, %rdi
callq 0x92ec
movq %rax, %r15
leaq 0x201b8(%rip), %rax     # 0x2b948
movq (%rax), %rsi
movq %r15, %rdi
callq 0xa68b
movq %rax, %rbx
movq %r15, %rdi
callq 0xa1c2
movq %rax, %r15
movl (%rax), %eax
movl $0xfffffef9, %ecx       # imm = 0xFFFFFEF9
addl %ecx, %eax
cmpl $0x20, %eax
ja 0xbccf
movabsq $0x100010001, %rcx      # imm = 0x100010001
btq %rax, %rcx
jae 0xbccf
movq 0x28(%r15), %rax
testb $0x2, 0x1b(%rax)
je 0xbccf
movq 0x8(%rbx), %rsi
movl $0x2a0, %edi            # imm = 0x2A0
movq %rbx, %rdx
xorl %ecx, %ecx
callq 0x165eb
movq %rax, %rbx
movq 0x28(%r15), %rax
movq %rax, 0x28(%rbx)
jmp 0xbccf
leaq 0x11b8e(%rip), %rdi     # 0x1d395
xorl %eax, %eax
callq 0x8dd4
jmp 0xb5dd
movq %rbx, %rdi
callq 0xa22f
movq %rax, %rbx
movq 0x8(%rax), %rsi
movl (%rsi), %eax
cmpl $0xf, %eax
jb 0xb82f
movq 0x10(%rsi), %rax
movl (%rax), %eax
cmpl $0x7, %eax
jne 0xb84b
movq 0x10(%rsi), %r15
movl (%r15), %eax
cmpl $0xf, %eax
jb 0xb846
movq 0x10(%r15), %rax
movl (%rax), %eax
cmpl $0xb, %eax
je 0xb86d
leaq 0x11af5(%rip), %rdi     # 0x1d347
xorl %eax, %eax
callq 0x8dd4
leaq 0x26780(%rip), %rax     # 0x31fe0
movq (%rax), %rdi
xorl %esi, %esi
callq 0x179be
movq %rax, %r15
leaq 0x200c4(%rip), %rax     # 0x2b938
movups (%rax), %xmm0
movaps %xmm0, 0x10(%rsp)
callq 0xd3c9
movl %eax, (%r14)
movaps 0x10(%rsp), %xmm0
movups %xmm0, 0x28(%rsp)
movq %rbx, (%rsp)
movq 0x18(%r15), %rax
testq %rax, %rax
je 0xb8b4
movq (%rax), %rcx
leaq 0x2673b(%rip), %rdx     # 0x31fe0
cmpq (%rdx), %rcx
movl $0x0, %r13d
cmovneq %rax, %r13
jmp 0xb8b7
xorl %r13d, %r13d
movq %rbx, %rdi
callq 0x16672
movl $0x0, %ecx
movq %rcx, 0x10(%rsp)
testl %eax, %eax
je 0xb8d6
movq (%rsp), %rax
movq %rax, 0x10(%rsp)
movq %r15, 0x8(%rsp)
cmpl $0x29, (%r14)
jne 0xb8e8
xorl %ebx, %ebx
jmp 0xbb7d
pushq $0x1
popq %rbp
xorl %ebx, %ebx
xorl %edi, %edi
callq 0xa439
movq %rax, %rdi
callq 0xa22f
movq %rax, %r15
testq %r13, %r13
je 0xb9a9
movq (%r13), %rax
testq %rax, %rax
je 0xb9b7
leaq 0x266c4(%rip), %rcx     # 0x31fe0
cmpq (%rcx), %rax
je 0xb9b7
movq %r15, %rdi
callq 0x94a3
movq %rax, %r15
movq (%r13), %rdi
movq %rax, %rsi
callq 0x9610
testq %rax, %rax
je 0xba83
movq %r15, %rdi
movq %rax, %rsi
callq 0x9912
movq %rax, %r15
movq 0x8(%rax), %rdi
movl (%rdi), %eax
cmpl $0xf, %eax
jb 0xb964
movq 0x10(%rdi), %rax
movl (%rax), %eax
cmpl $0x2, %eax
jbe 0xbaa7
cmpl $0x7, %eax
jb 0xb97b
cmpl $0xd, %eax
jne 0xbaa7
movl 0x8(%rdi), %eax
leaq 0x26613(%rip), %rcx     # 0x31f98
movq (%rcx), %rcx
cmpl 0x8(%rcx), %eax
je 0xbaa7
callq 0xa287
movq %r15, %rdi
movq %rax, %rsi
callq 0x9912
movq %rax, %r15
jmp 0xbaa7
movq 0x8(%rsp), %rax
cmpq $0x0, 0x18(%rax)
jne 0xb9c8
jmp 0xb9e2
movq 0x8(%rsp), %rcx
cmpq $0x0, 0x18(%rcx)
je 0xb9e2
testq %rax, %rax
jne 0xb9e2
movq (%rsp), %rdi
callq 0xa3ec
leaq 0x11a3c(%rip), %rdi     # 0x1d414
movq %rax, %rsi
xorl %eax, %eax
callq 0x8dd4
movq %r15, %rdi
callq 0x94a3
movq %rax, %r15
movq 0x8(%rax), %rdi
leaq 0x26598(%rip), %rax     # 0x31f90
cmpq (%rax), %rdi
je 0xba16
movl (%rdi), %eax
cmpl $0xf, %eax
jb 0xba28
movq 0x10(%rdi), %rcx
movl (%rcx), %ecx
cmpl $0x2, %ecx
jbe 0xba50
cmpl $0x7, %ecx
jae 0xba34
jmp 0xba39
leaq 0x2656b(%rip), %rax     # 0x31f88
movq (%rax), %rsi
movq %r15, %rdi
jmp 0xbab8
cmpl $0x2, %eax
jbe 0xba5b
movl %eax, %ecx
cmpl $0x7, %eax
jb 0xba39
cmpl $0xd, %ecx
jne 0xba4b
movl 0x8(%rdi), %ecx
leaq 0x26555(%rip), %rdx     # 0x31f98
movq (%rdx), %rdx
cmpl 0x8(%rdx), %ecx
jne 0xbaad
cmpl $0xf, %eax
jb 0xba56
movq 0x10(%rdi), %rax
movl (%rax), %eax
cmpl $0xc, %eax
je 0xba61
cmpl $0x0, 0x8(%rdi)
jne 0xbac0
movq (%rsp), %rdi
callq 0xa3ec
movq 0x8(%r15), %rcx
leaq 0x119b9(%rip), %rdi     # 0x1d42e
movl %ebp, %esi
movq %rax, %rdx
xorl %eax, %eax
callq 0x8dd4
jmp 0xbac0
movq (%rsp), %rdi
callq 0xa3ec
movq 0x8(%r15), %rcx
movq (%r13), %r8
leaq 0x1193e(%rip), %rdi     # 0x1d3d9
movl %ebp, %esi
movq %rax, %rdx
xorl %eax, %eax
callq 0x8dd4
addq $0x8, %r13
jmp 0xbac0
callq 0xa287
movq %r15, %rdi
movq %rax, %rsi
callq 0x9912
movq %rax, %r15
movq %r15, %rdi
callq 0x16672
testl %eax, %eax
je 0xbaed
leaq 0x2650d(%rip), %rax     # 0x31fe0
movq (%rax), %rsi
movl $0x2a0, %edi            # imm = 0x2A0
movq 0x10(%rsp), %rdx
movq %r15, %rcx
callq 0x165eb
movq %rax, 0x10(%rsp)
movq 0x8(%r15), %rsi
movl (%rsi), %eax
cmpl $0xf, %eax
jb 0xbafe
movq 0x10(%rsi), %rax
movl (%rax), %eax
cmpl $0x2, %eax
jbe 0xbb12
cmpl $0x7, %eax
jb 0xbb0d
cmpl $0xd, %eax
jne 0xbb12
pushq $0x25
popq %rdi
jmp 0xbb23
movq %rsi, %rdi
callq 0x18b82
movl %eax, %edi
addl $0x20, %edi
movq 0x8(%r15), %rsi
movq %r15, %rdx
movq %rbx, %rcx
callq 0x165eb
movq %rax, %rbx
leaq 0x1ff20(%rip), %rax     # 0x2ba58
cmpl $0x2, (%rax)
setge %al
cmpl $0x20, %ebp
sete %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0xbb65
movq (%rsp), %rdi
callq 0xa3ec
leaq 0x11905(%rip), %rdi     # 0x1d460
movq %rax, %rsi
xorl %eax, %eax
callq 0x9239
cmpl $0x2c, (%r14)
jne 0xbb7d
callq 0xd3c9
movl %eax, (%r14)
incl %ebp
testl %eax, %eax
jne 0xb8ed
pushq $0x29
popq %rdi
callq 0x8ee9
testq %r13, %r13
je 0xbbb9
movq (%r13), %rax
testq %rax, %rax
je 0xbbb9
leaq 0x26446(%rip), %rcx     # 0x31fe0
cmpq (%rcx), %rax
je 0xbbb9
movq (%rsp), %rdi
callq 0xa3ec
leaq 0x118d9(%rip), %rdi     # 0x1d488
movq %rax, %rsi
xorl %eax, %eax
callq 0x8dd4
movq 0x10(%rsp), %rdx
testq %rdx, %rdx
leaq 0x1fe98(%rip), %rbp     # 0x2ba60
je 0xbbe4
leaq 0x2640f(%rip), %rax     # 0x31fe0
movq (%rax), %rsi
movl $0x2a0, %edi            # imm = 0x2A0
movq %rbx, %rcx
callq 0x165eb
movq %rax, %rbx
leaq 0x1fe15(%rip), %rax     # 0x2ba00
movq 0x20(%rax), %rdi
testq %rdi, %rdi
je 0xbc01
leaq 0x28(%rsp), %rsi
movq %rsp, %rdx
callq 0xf206
movq (%rsp), %r15
movq 0x8(%rsp), %rdi
callq 0x18021
movq %r15, %rdi
movq %rax, %rsi
movq %rbx, %rdx
callq 0x87f6
movq %rax, %rbx
jmp 0xb5dd
movq 0x8(%r15), %rcx
movl (%rcx), %eax
cmpl $0xf, %eax
jb 0xbc36
movq 0x10(%rcx), %rax
movl (%rax), %eax
cmpl $0x7, %eax
jne 0xbc46
movq %r15, %rdi
callq 0xb4bf
movq %rax, %r15
movq %r15, %rdi
callq 0xa22f
movq %rax, %r15
leaq 0x1c508(%rip), %rax     # 0x28160
movq 0x158(%rax), %r13
movq %rbx, %rdi
callq 0xa22f
movl $0x130, %edi            # imm = 0x130
movq %rax, %rsi
movq %r15, %rdx
callq *%r13
movq 0x8(%rax), %rcx
movl (%rcx), %edx
cmpl $0xf, %edx
jb 0xbc86
movq 0x10(%rcx), %rdx
movl (%rdx), %edx
cmpl $0x7, %edx
jne 0xbcb1
movq 0x10(%rcx), %rsi
movl (%rsi), %ecx
cmpl $0xf, %ecx
jb 0xbc9c
movq 0x10(%rsi), %rcx
movl (%rcx), %ecx
cmpl $0xc, %ecx
jne 0xbcb1
movq %rax, %rdi
callq 0x16727
movq %rax, %rbx
jmp 0xb5dd
movq %rax, %rdi
callq 0xa0b9
movq %rax, %rbx
jmp 0xb5dd
leaq 0x1169f(%rip), %rdi     # 0x1d367
xorl %eax, %eax
callq 0x8dd4
callq 0xd3c9
movl %eax, (%r14)
jmp 0xb5dd
leaq 0x116c7(%rip), %rdi     # 0x1d3aa
jmp 0xbcc8
movq %rbx, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop