// File: /workspace/github_cpp_makefile_star2_O2/joncampbell123[P]haxcc/haxpp.cpp
// Function: main
int main(int argc,char **argv) {
    if (parse_argv(argc,argv))
        return 1;

    in_src_stk.alloc();
    in_src_stk.push();
    if (in_file == "-")
        in_src_stk.top().set(stdin);
    else
        in_src_stk.top().set(in_file);

    in_src_stk.top().open();
    if (!in_src_stk.top().is_open()) {
        fprintf(stderr,"Unable to open source\n");
        return 1;
    }

    if (out_file == "-")
        out_dst.set(stdout);
    else
        out_dst.set(out_file);

    out_dst.open();
    if (!out_dst.is_open()) {
        fprintf(stderr,"Unable to open dest\n");
        return 1;
    }

    string line;
    bool emit_line = false;
    int32_t lineno_expect = -1;
    token_string tokens;

    while (!in_src_stk.empty()) {
        const int32_t lineno = in_src_stk.top().current_line();
        const string &source = in_src_stk.top().get_path();

        if (read_line(/*&*/line,in_src_stk.top())) {
            if (ppp_only) {
                if (lineno_expect != lineno)
                    emit_line = true;

                if (emit_line) {
                    out_dst.puts(string("#line ") + to_string(lineno) + " " + source + "\n");
                    emit_line = false;
                }

                out_dst.puts(line);
                out_dst.putc('\n');
                lineno_expect = lineno + int32_t(1);
            }
            else {
                tokens.clear();
                parse_tokens(tokens,line.begin(),line.end(),lineno,source);
                if (accept_tokens(tokens.begin(),tokens.end())) {
                    if (ppt_only) {
                        if (lineno_expect != lineno)
                            emit_line = true;

                        if (emit_line) {
                            out_dst.puts(string("#line ") + to_string(lineno) + " " + source + "\n");
                            emit_line = false;
                        }

                        for (const auto &t : tokens)
                            out_dst.puts(to_string(t));

                        out_dst.putc('\n');
                        lineno_expect = lineno + int32_t(1);
                    }
                    else if (pp_only) {
                        if (pp_allow_token_display(tokens)) {
                            if (lineno_expect != lineno)
                                emit_line = true;

                            if (emit_line) {
                                out_dst.puts(string("#line ") + to_string(lineno) + " " + source + "\n");
                                emit_line = false;
                            }

                            for (const auto &t : tokens)
                                out_dst.puts(to_string_pp(t));

                            out_dst.putc('\n');
                            lineno_expect = lineno + int32_t(1);
                        }
                    }
                }
            }
        }
        else if (in_src_stk.top().eof()) {
            emit_line = true;
            in_src_stk.pop();
        }
    }

    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x108, %rsp            # imm = 0x108
movq %rsi, %rbx
movslq %edi, %rbp
xorl %r14d, %r14d
pushq $0x1
popq %r15
cmpq %rbp, %r15
jge 0xa7a6
movq (%rbx,%r15,8), %r13
incq %r15
cmpb $0x2d, (%r13)
jne 0xa767
cmpb $0x0, 0x1(%r13)
je 0xa767
movzbl 0x1(%r13), %eax
incq %r13
cmpl $0x2d, %eax
je 0xa6cc
cmpl $0x45, %eax
je 0xa6f3
cmpl $0x68, %eax
jne 0xa6ee
cmpb $0x0, 0x1(%r13)
je 0xada1
xorl %r12d, %r12d
jmp 0xa6f6
movb $0x1, %r12b
movq %r13, %rdi
leaq 0x6059(%rip), %rsi      # 0x10759
callq 0x2280
testl %eax, %eax
je 0xada1
testb %r12b, %r12b
je 0xad84
movzbl 0x1(%r13), %eax
testl %eax, %eax
je 0xa744
cmpl $0x54, %eax
je 0xa750
cmpl $0x45, %eax
jne 0xad84
cmpb $0x0, 0x2(%r13)
jne 0xad84
movb $0x1, 0xdc52(%rip)      # 0x18391
jmp 0xa6a6
movb $0x1, 0xdc47(%rip)      # 0x18392
jmp 0xa6a6
cmpb $0x0, 0x2(%r13)
jne 0xad84
movb $0x1, 0xdc2e(%rip)      # 0x18390
jmp 0xa6a6
cmpl $0x1, %r14d
je 0xa78e
testl %r14d, %r14d
jne 0xadfc
leaq 0xdb83(%rip), %rdi      # 0x18300
movq %r13, %rsi
callq 0x23c0
pushq $0x1
popq %r14
jmp 0xa6a6
leaq 0xdb8b(%rip), %rdi      # 0x18320
movq %r13, %rsi
callq 0x23c0
pushq $0x2
popq %r14
jmp 0xa6a6
leaq 0xdb03(%rip), %rbx      # 0x182b0
movq %rbx, %rdi
callq 0xb6ca
movq %rbx, %rdi
callq 0xb6d2
leaq 0xdb3c(%rip), %rdi      # 0x18300
leaq 0x4ff9(%rip), %rsi      # 0xf7c4
callq 0xb1f3
movl %eax, %ebp
movq %rbx, %rdi
callq 0xb740
testb %bpl, %bpl
je 0xa7f3
movq 0xd7b2(%rip), %rcx      # 0x17f98
movq (%rcx), %rsi
movq %rax, %rdi
callq 0x2a06
jmp 0xa802
leaq 0xdb06(%rip), %rsi      # 0x18300
movq %rax, %rdi
callq 0x2a56
leaq 0xdaa7(%rip), %rbx      # 0x182b0
movq %rbx, %rdi
callq 0xb740
movq %rax, %rdi
callq 0x2a82
movq %rbx, %rdi
callq 0xb740
cmpq $0x0, (%rax)
je 0xadb6
leaq 0xdaee(%rip), %rdi      # 0x18320
leaq 0x4f8b(%rip), %rsi      # 0xf7c4
callq 0xb1f3
testb %al, %al
je 0xa85a
movq 0xd71f(%rip), %rax      # 0x17f68
movq (%rax), %rsi
leaq 0xda7d(%rip), %rdi      # 0x182d0
callq 0x2b68
jmp 0xa86d
leaq 0xda6f(%rip), %rdi      # 0x182d0
leaq 0xdab8(%rip), %rsi      # 0x18320
callq 0x2bb0
leaq 0xda5c(%rip), %rdi      # 0x182d0
callq 0x2bd6
cmpq $0x0, 0xda4f(%rip)      # 0x182d0
je 0xadcb
leaq 0xf8(%rsp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
xorps %xmm0, %xmm0
leaq 0x30(%rsp), %rax
movaps %xmm0, (%rax)
andq $0x0, 0x10(%rax)
pushq $-0x1
popq %rax
movl %eax, 0xc(%rsp)
xorl %r14d, %r14d
cmpq $-0x1, 0xda0b(%rip)     # 0x182c8
je 0xad69
leaq 0xd9e6(%rip), %r15      # 0x182b0
movq %r15, %rdi
callq 0xb740
movl 0x30(%rax), %ebx
movq %r15, %rdi
callq 0xb740
movq %rax, %r12
leaq 0xd9c9(%rip), %rdi      # 0x182b0
callq 0xb740
leaq 0xe8(%rsp), %rdi
movq %rax, %rsi
callq 0x2e42
testb %al, %al
je 0xaa32
addq $0x10, %r12
cmpb $0x1, 0xda82(%rip)      # 0x18391
movzbl %r14b, %r13d
jne 0xaa62
cmpl %ebx, 0xc(%rsp)
pushq $0x1
popq %rax
cmovnel %eax, %r13d
movl %r13d, %r14d
testb $0x1, %r13b
je 0xaa04
leaq 0x88(%rsp), %rdi
leaq 0x5d34(%rip), %rsi      # 0x10674
leaq 0xb(%rsp), %rdx
callq 0xb1b8
leaq 0xa8(%rsp), %r15
movq %r15, %rdi
movl %ebx, %esi
callq 0xb7b9
leaq 0xc8(%rsp), %r13
movq %r13, %rdi
leaq 0x88(%rsp), %rsi
movq %r15, %rdx
callq 0xb282
leaq 0x68(%rsp), %rbp
movq %rbp, %rdi
movq %r13, %rsi
leaq 0x52a6(%rip), %rdx      # 0xfc2f
callq 0xb244
leaq 0x48(%rsp), %r14
movq %r14, %rdi
movq %rbp, %rsi
movq %r12, %rdx
callq 0xb263
leaq 0x10(%rsp), %rdi
movq %r14, %rsi
leaq 0x58ef(%rip), %rdx      # 0x1029f
callq 0xb244
movq 0x10(%rsp), %rsi
leaq 0xd90f(%rip), %rdi      # 0x182d0
callq 0x2c84
leaq 0x10(%rsp), %rdi
callq 0x2408
leaq 0x48(%rsp), %rdi
callq 0x2408
leaq 0x68(%rsp), %rdi
callq 0x2408
movq %r13, %rdi
callq 0x2408
movq %r15, %rdi
callq 0x2408
leaq 0x88(%rsp), %rdi
callq 0x2408
xorl %r14d, %r14d
movq 0xe8(%rsp), %rsi
leaq 0xd8bd(%rip), %rdi      # 0x182d0
callq 0x2c84
leaq 0xd8b1(%rip), %rdi      # 0x182d0
pushq $0xa
popq %rsi
callq 0x2c0e
incl %ebx
movl %ebx, 0xc(%rsp)
jmp 0xa8b5
leaq 0xd877(%rip), %rdi      # 0x182b0
callq 0xb740
movq %rax, %rdi
callq 0x2ab4
testb %al, %al
je 0xa8b5
movb $0x1, %r14b
leaq 0xd858(%rip), %rdi      # 0x182b0
callq 0xb81a
jmp 0xa8b5
leaq 0x30(%rsp), %r15
movq %r15, %rdi
callq 0xb812
movq 0xe8(%rsp), %rsi
movq 0xf0(%rsp), %rdx
addq %rsi, %rdx
movq %r15, %rdi
movl %ebx, %ecx
movq %r12, %r8
callq 0x5dab
movq 0x30(%rsp), %rax
movq 0x38(%rsp), %rcx
movq %rax, 0x10(%rsp)
movq %rcx, 0x48(%rsp)
leaq 0x10(%rsp), %rdi
leaq 0x48(%rsp), %rsi
callq 0x9ed9
testb %al, %al
je 0xa8b5
cmpb $0x1, 0xd8cf(%rip)      # 0x18390
jne 0xabf1
cmpl %ebx, 0xc(%rsp)
pushq $0x1
popq %rax
cmovnel %eax, %r13d
movl %r13d, %r14d
testb $0x1, %r13b
leaq 0xc8(%rsp), %r13
je 0xabb0
leaq 0x88(%rsp), %r14
movq %r14, %rdi
leaq 0x5b7b(%rip), %rsi      # 0x10674
leaq 0xb(%rsp), %rdx
callq 0xb1b8
leaq 0xa8(%rsp), %r15
movq %r15, %rdi
movl %ebx, %esi
callq 0xb7b9
movq %r13, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0xb282
leaq 0x68(%rsp), %rbp
movq %rbp, %rdi
movq %r13, %rsi
leaq 0x50fa(%rip), %rdx      # 0xfc2f
callq 0xb244
leaq 0x48(%rsp), %r15
movq %r15, %rdi
movq %rbp, %rsi
movq %r12, %rdx
callq 0xb263
leaq 0x10(%rsp), %rdi
movq %r15, %rsi
leaq 0x5743(%rip), %rdx      # 0x1029f
callq 0xb244
movq 0x10(%rsp), %rsi
leaq 0xd763(%rip), %rdi      # 0x182d0
callq 0x2c84
leaq 0x10(%rsp), %rdi
callq 0x2408
leaq 0x48(%rsp), %rdi
callq 0x2408
leaq 0x68(%rsp), %rdi
callq 0x2408
movq %r13, %rdi
callq 0x2408
leaq 0xa8(%rsp), %rdi
callq 0x2408
movq %r14, %rdi
callq 0x2408
xorl %r14d, %r14d
movq 0x30(%rsp), %r15
movq 0x38(%rsp), %r12
cmpq %r12, %r15
je 0xad55
leaq 0x10(%rsp), %rdi
movq %r15, %rsi
callq 0x47a7
movq 0x10(%rsp), %rsi
leaq 0xd6f4(%rip), %rdi      # 0x182d0
callq 0x2c84
leaq 0x10(%rsp), %rdi
callq 0x2408
addq $0x70, %r15
jmp 0xabba
cmpb $0x1, 0xd79a(%rip)      # 0x18392
jne 0xa8b5
movq 0x30(%rsp), %r15
movq 0x38(%rsp), %rbp
cmpq %rbp, %r15
je 0xa8b5
cmpl $0x2, (%r15)
je 0xa8b5
cmpl %ebx, 0xc(%rsp)
pushq $0x1
popq %rax
cmovnel %eax, %r13d
movl %r13d, %r14d
testb $0x1, %r13b
leaq 0xa8(%rsp), %r13
je 0xad3c
leaq 0x88(%rsp), %r14
movq %r14, %rdi
leaq 0x5a27(%rip), %rsi      # 0x10674
leaq 0xb(%rsp), %rdx
callq 0xb1b8
movq %r13, %rdi
movl %ebx, %esi
callq 0xb7b9
leaq 0xc8(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
movq %r13, %rdx
callq 0xb282
leaq 0x68(%rsp), %rbp
movq %rbp, %rdi
movq %r15, %rsi
leaq 0x4fa6(%rip), %rdx      # 0xfc2f
callq 0xb244
leaq 0x48(%rsp), %r15
movq %r15, %rdi
movq %rbp, %rsi
movq %r12, %rdx
callq 0xb263
leaq 0x10(%rsp), %rdi
movq %r15, %rsi
leaq 0x55ef(%rip), %rdx      # 0x1029f
callq 0xb244
movq 0x10(%rsp), %rsi
leaq 0xd60f(%rip), %rdi      # 0x182d0
callq 0x2c84
leaq 0x10(%rsp), %rdi
callq 0x2408
leaq 0x48(%rsp), %rdi
callq 0x2408
leaq 0x68(%rsp), %rdi
callq 0x2408
leaq 0xc8(%rsp), %rdi
callq 0x2408
movq %r13, %rdi
callq 0x2408
movq %r14, %rdi
callq 0x2408
movq 0x30(%rsp), %r15
movq 0x38(%rsp), %rbp
xorl %r14d, %r14d
jmp 0xad3c
leaq 0x10(%rsp), %rdi
movq %r15, %rsi
callq 0x50ea
movq 0x10(%rsp), %rsi
leaq 0xd5a7(%rip), %rdi      # 0x182d0
callq 0x2c84
leaq 0x10(%rsp), %rdi
callq 0x2408
addq $0x70, %r15
cmpq %rbp, %r15
jne 0xad10
leaq 0xd588(%rip), %rdi      # 0x182d0
pushq $0xa
popq %rsi
callq 0x2c0e
jmp 0xaa27
leaq 0xd574(%rip), %rdi      # 0x182d0
pushq $0xa
popq %rsi
callq 0x2c0e
jmp 0xaa27
leaq 0x30(%rsp), %rdi
callq 0xb886
leaq 0xe8(%rsp), %rdi
callq 0x2408
xorl %eax, %eax
jmp 0xadea
movq 0xd22d(%rip), %rax      # 0x17fb8
movq (%rax), %rdi
leaq 0x59c9(%rip), %rsi      # 0x1075e
movq %r13, %rdx
xorl %eax, %eax
callq 0x2290
jmp 0xade7
movq 0xd210(%rip), %rax      # 0x17fb8
movq (%rax), %rcx
leaq 0x59d2(%rip), %rdi      # 0x10784
pushq $0x15
jmp 0xadde
movq 0xd1fb(%rip), %rax      # 0x17fb8
movq (%rax), %rcx
leaq 0x5881(%rip), %rdi      # 0x10648
pushq $0x16
jmp 0xadde
movq 0xd1e6(%rip), %rax      # 0x17fb8
movq (%rax), %rcx
leaq 0x5883(%rip), %rdi      # 0x1065f
pushq $0x14
popq %rsi
pushq $0x1
popq %rdx
callq 0x23d0
pushq $0x1
popq %rax
addq $0x108, %rsp            # imm = 0x108
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0xd1b5(%rip), %rax      # 0x17fb8
movq (%rax), %rdi
leaq 0x5964(%rip), %rsi      # 0x10771
jmp 0xad95
jmp 0xae2e
jmp 0xae3d
jmp 0xae4c
jmp 0xae5b
jmp 0xae6d
jmp 0xae87
jmp 0xaea7
jmp 0xae2e
jmp 0xae3d
jmp 0xae4c
jmp 0xae5b
jmp 0xae6d
jmp 0xae87
jmp 0xaea7
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x2408
jmp 0xae40
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0x2408
jmp 0xae4f
movq %rax, %rbx
leaq 0x68(%rsp), %rdi
callq 0x2408
jmp 0xae5e
movq %rax, %rbx
leaq 0xc8(%rsp), %rdi
callq 0x2408
jmp 0xae70
movq %rax, %rbx
leaq 0xa8(%rsp), %rdi
callq 0x2408
leaq 0x88(%rsp), %rdi
jmp 0xae9e
movq %rax, %rbx
jmp 0xae7d
jmp 0xaea7
jmp 0xaea7
jmp 0xae96
jmp 0xaea7
jmp 0xaea7
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x2408
jmp 0xaeaa
jmp 0xaea7
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0xb886
leaq 0xe8(%rsp), %rdi
callq 0x2408
movq %rbx, %rdi
callq 0x2370
nop