// File: /workspace/github_c_makefile_star2_O0/Oric4ever[P]lcc65/6502/build/../src/main.c
// Function: main
int main(int argc, char *argv[]) {
	Symbol symroot = 0;		/* root of the global symbols */
	static Events z;

	assert(MAXKIDS >= 2);
	assert(MAXSYMS >= 2);
	progname = argv[0];
	typeInit();
	level = GLOBAL;
	argc = doargs(argc, argv);
	assert(inttype->size >= voidptype->size);
	if (infile && *infile != '-') {
		close(0);
		if (open(infile, 0) != 0) {
			fprint(2, "%s: can't read %s\n", argv[0], infile);
			exit(1);
		}
	}
	if (outfile && *outfile != '-') {
		close(1);
		if (creat(outfile, 0666) != 1) {
			fprint(2, "%s: can't write %s\n", argv[0], outfile);
			exit(1);
		}
	}
	inputInit(0);
	t = gettok();
	progbeg(argc, argv);
	stabinit(firstfile, argc, argv);
	program();
	if (events.end)
		apply(events.end, (Generic)0, (Generic)0);
	events = z;
	emitYYnull();
	finalize();
	if (glevel || xref) {
		Coordinate src;
		foreach(types, GLOBAL, typestab, (Generic)&symroot);
		foreach(identifiers, GLOBAL, typestab, (Generic)&symroot);
		src.file = firstfile;
		src.x = 0;
		src.y = lineno;
		if (glevel > 2 || xref)
			stabend(&src, symroot, (Coordinate **)list_to_a(append((Generic)0, loci), 0),
				(Symbol *)list_to_a(append((Generic)0, tables), 0),
				symbols ? (Symbol *)list_to_a(symbols, 0) : 0);
		else
			stabend(&src, 0, 0, 0, 0);
	}
#ifdef progend
	progend(0);
#else
	progend();
#endif
	outflush();
	exit(errcnt > 0);
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq $0x0, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, 0x25e0c(%rip)     # 0x3dbb8
callq 0x26510
leaq 0x291d8(%rip), %rax     # 0x40f90
movl $0x3, (%rax)
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
callq 0x17ff0
movl %eax, -0x8(%rbp)
leaq 0x2c424(%rip), %rax     # 0x441f8
movq (%rax), %rax
movl 0x8(%rax), %eax
leaq 0x2c46f(%rip), %rcx     # 0x44250
movq (%rcx), %rcx
cmpl 0x8(%rcx), %eax
jl 0x17deb
jmp 0x17e0a
leaq 0x18f8a(%rip), %rdi     # 0x30d7c
leaq 0x18fa4(%rip), %rsi     # 0x30d9d
movl $0x29, %edx
leaq 0x18fa6(%rip), %rcx     # 0x30dab
callq 0x30c0
cmpq $0x0, 0x25dae(%rip)     # 0x3dbc0
je 0x17e6c
movq 0x25da5(%rip), %rax     # 0x3dbc0
movsbl (%rax), %eax
cmpl $0x2d, %eax
je 0x17e6c
xorl %edi, %edi
callq 0x30d0
movq 0x25d8f(%rip), %rdi     # 0x3dbc0
xorl %esi, %esi
movb $0x0, %al
callq 0x3140
cmpl $0x0, %eax
je 0x17e6a
movq -0x10(%rbp), %rax
movq (%rax), %rdx
movq 0x25d73(%rip), %rcx     # 0x3dbc0
movl $0x2, %edi
leaq 0x18f69(%rip), %rsi     # 0x30dc2
movb $0x0, %al
callq 0x1a630
movl $0x1, %edi
callq 0x3180
jmp 0x17e6c
cmpq $0x0, 0x25d54(%rip)     # 0x3dbc8
je 0x17ed2
movq 0x25d4b(%rip), %rax     # 0x3dbc8
movsbl (%rax), %eax
cmpl $0x2d, %eax
je 0x17ed2
movl $0x1, %edi
callq 0x30d0
movq 0x25d32(%rip), %rdi     # 0x3dbc8
movl $0x1b6, %esi            # imm = 0x1B6
callq 0x3160
cmpl $0x1, %eax
je 0x17ed0
movq -0x10(%rbp), %rax
movq (%rax), %rdx
movq 0x25d15(%rip), %rcx     # 0x3dbc8
movl $0x2, %edi
leaq 0x18f16(%rip), %rsi     # 0x30dd5
movb $0x0, %al
callq 0x1a630
movl $0x1, %edi
callq 0x3180
jmp 0x17ed2
xorl %edi, %edi
callq 0x146a0
callq 0x15170
movl %eax, %ecx
leaq 0x25c99(%rip), %rax     # 0x3db80
movl %ecx, (%rax)
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
callq 0x2a180
callq 0x79b0
cmpq $0x0, 0x25cf6(%rip)     # 0x3dbf8
je 0x17f17
movq 0x25ced(%rip), %rdi     # 0x3dbf8
xorl %eax, %eax
movl %eax, %edx
movq %rdx, %rsi
callq 0x18640
leaq 0x25cb2(%rip), %rdi     # 0x3dbd0
leaq 0x25c63(%rip), %rsi     # 0x3db88
movl $0x30, %edx
callq 0x3120
callq 0x186b0
callq 0x76b0
cmpl $0x0, 0x25cc0(%rip)     # 0x3dc00
jne 0x17f4b
cmpl $0x0, 0x25cbb(%rip)     # 0x3dc04
je 0x17fc2
leaq 0x2360e(%rip), %rax     # 0x3b560
movq (%rax), %rdi
movl $0x3, %esi
leaq 0x7df(%rip), %rdx       # 0x18740
leaq -0x18(%rbp), %rcx
callq 0x243f0
leaq 0x231c7(%rip), %rax     # 0x3b138
movq (%rax), %rdi
movl $0x3, %esi
leaq 0x7c0(%rip), %rdx       # 0x18740
leaq -0x18(%rbp), %rcx
callq 0x243f0
leaq 0x24b38(%rip), %rax     # 0x3cac8
movq (%rax), %rax
movq %rax, -0x28(%rbp)
movw $0x0, -0x20(%rbp)
leaq 0x24b04(%rip), %rax     # 0x3caa8
movl (%rax), %eax
movw %ax, -0x1e(%rbp)
cmpl $0x2, 0x25c4f(%rip)     # 0x3dc00
jg 0x17fbc
cmpl $0x0, 0x25c4a(%rip)     # 0x3dc04
je 0x17fbe
jmp 0x17fc0
jmp 0x17fc0
jmp 0x17fc2
callq 0x2a450
callq 0x1a770
leaq 0x23a69(%rip), %rax     # 0x3ba3c
cmpl $0x0, (%rax)
setg %al
andb $0x1, %al
movzbl %al, %edi
callq 0x3180
nopw %cs:(%rax,%rax)