// File: /workspace/github_cpp_makefile_star2_O3/zeeev[P]DASVC/src/main.cpp
// Function: main
int main(int argc, char ** argv)
{
    errorHandler EH;

    std::map< std::string, int > PROGS;

    PROGS[ "annotate" ] = 1;
    PROGS[ "varcall"  ] = 2;

    if(argc < 2){
        EH.croak(EH.USAGE, true);
    }

    std::string prog = argv[1];

    if(PROGS.find(prog) == PROGS.end()){
        EH.croak(EH.BAD_COMMAND_LINE_OPTION, true, prog);
    }

    switch(PROGS[argv[1]]){
    case 1:
        {
            return annotate((std::string)argv[2],
                            (std::string)argv[3],
                            (std::string)argv[4]);
            break;
        }
    case 2:
        {
            std::string bf = argv[2];
            std::string tf = argv[3];
            std::string qf = argv[4];

            return varcall(bf, tf, qf);
            break;
        }

    default:
        {
            /* should never hit here */
        }
    }

    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x190, %rsp            # imm = 0x190
movq %rsi, %rbx
movl %edi, %ebp
leaq 0x140(%rsp), %rdi
callq 0xec74
leaq 0x118(%rsp), %r15
movl $0x0, (%r15)
xorl %eax, %eax
movq %rax, 0x8(%r15)
movq %r15, 0x10(%r15)
movq %r15, 0x18(%r15)
movq %rax, 0x20(%r15)
leaq 0x20(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x29d1b(%rip), %rsi     # 0x391b9
leaq 0x29d1c(%rip), %rdx     # 0x391c1
leaq 0x10(%rsp), %rdi
callq 0xbdac
leaq 0x110(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0xf954
movl $0x1, (%rax)
movq 0x10(%rsp), %rdi
cmpq %r14, %rdi
je 0xf4de
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x5470
leaq 0x10(%rsp), %rdi
movq %r14, (%rdi)
leaq 0x29da1(%rip), %rsi     # 0x3928e
leaq 0x29da1(%rip), %rdx     # 0x39295
callq 0xbdac
leaq 0x110(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0xf954
movl $0x2, (%rax)
movq 0x10(%rsp), %rdi
cmpq %r14, %rdi
je 0xf528
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x5470
cmpl $0x1, %ebp
jg 0xf544
leaq 0x140(%rsp), %rdi
movl $0x5, %esi
movl $0x1, %edx
callq 0xeea0
movq 0x8(%rbx), %rsi
leaq 0x10(%rsp), %rdi
leaq 0x30(%rsp), %rdx
callq 0xf9d0
leaq 0x110(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0xfdaa
cmpq %r15, %rax
jne 0xf5d0
leaq 0xa0(%rsp), %r15
movq %r15, -0x10(%r15)
movq 0x10(%rsp), %rsi
movq 0x18(%rsp), %rdx
addq %rsi, %rdx
leaq 0x90(%rsp), %rdi
callq 0xbd16
leaq 0x140(%rsp), %rdi
leaq 0x90(%rsp), %rcx
movl $0x3, %esi
movl $0x1, %edx
callq 0xef04
movq 0x90(%rsp), %rdi
cmpq %r15, %rdi
je 0xf5d0
movq 0xa0(%rsp), %rsi
incq %rsi
callq 0x5470
movq 0x8(%rbx), %rsi
leaq 0x30(%rsp), %rdi
leaq 0x50(%rsp), %rdx
callq 0xf9d0
leaq 0x110(%rsp), %rdi
leaq 0x30(%rsp), %rsi
callq 0xf954
movl (%rax), %r12d
leaq 0x40(%rsp), %r15
movq -0x10(%r15), %rdi
cmpq %r15, %rdi
je 0xf613
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x5470
cmpl $0x1, %r12d
je 0xf6cc
xorl %ebp, %ebp
cmpl $0x2, %r12d
jne 0xf790
movq 0x10(%rbx), %rsi
leaq 0x30(%rsp), %rdi
leaq 0x50(%rsp), %rdx
callq 0xf9d0
movq 0x18(%rbx), %rsi
leaq 0x50(%rsp), %rdi
leaq 0x70(%rsp), %rdx
callq 0xf9d0
movq 0x20(%rbx), %rsi
leaq 0x70(%rsp), %rdi
leaq 0xf(%rsp), %rdx
callq 0xf9d0
leaq 0x30(%rsp), %rdi
leaq 0x50(%rsp), %rsi
leaq 0x70(%rsp), %rdx
callq 0x12004
movl %eax, %ebp
leaq 0x80(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf699
movq 0x80(%rsp), %rsi
incq %rsi
callq 0x5470
leaq 0x60(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf6b4
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x5470
movq 0x30(%rsp), %rdi
cmpq %r15, %rdi
je 0xf790
movq 0x40(%rsp), %rsi
jmp 0xf788
movq 0x10(%rbx), %rsi
leaq 0xf0(%rsp), %rdi
leaq 0x30(%rsp), %rdx
callq 0xf9d0
movq 0x18(%rbx), %rsi
leaq 0xd0(%rsp), %rdi
leaq 0x50(%rsp), %rdx
callq 0xf9d0
movq 0x20(%rbx), %rsi
leaq 0xb0(%rsp), %rdi
leaq 0x70(%rsp), %rdx
callq 0xf9d0
leaq 0xf0(%rsp), %rdi
leaq 0xd0(%rsp), %rsi
leaq 0xb0(%rsp), %rdx
callq 0xb01d
movl %eax, %ebp
leaq 0xc0(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf74e
movq 0xc0(%rsp), %rsi
incq %rsi
callq 0x5470
leaq 0xe0(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf76f
movq 0xe0(%rsp), %rsi
incq %rsi
callq 0x5470
leaq 0x100(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf790
movq 0x100(%rsp), %rsi
incq %rsi
callq 0x5470
movq 0x10(%rsp), %rdi
cmpq %r14, %rdi
je 0xf7a7
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x5470
leaq 0x110(%rsp), %rdi
callq 0xfa0e
leaq 0x180(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf7d5
movq 0x180(%rsp), %rsi
incq %rsi
callq 0x5470
leaq 0x158(%rsp), %rdi
callq 0xba86
leaq 0x140(%rsp), %rdi
callq 0xba86
movl %ebp, %eax
addq $0x190, %rsp            # imm = 0x190
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0xc0(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf850
movq 0xc0(%rsp), %rsi
incq %rsi
callq 0x5470
jmp 0xf850
movq %rax, %rbx
leaq 0x80(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf876
movq 0x80(%rsp), %rsi
incq %rsi
callq 0x5470
jmp 0xf876
movq %rax, %rbx
leaq 0xe0(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf896
movq 0xe0(%rsp), %rsi
incq %rsi
callq 0x5470
jmp 0xf896
movq %rax, %rbx
leaq 0x60(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf8b4
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x5470
jmp 0xf8b4
movq %rax, %rbx
leaq 0x100(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf90f
movq 0x100(%rsp), %rsi
jmp 0xf8f8
movq %rax, %rbx
movq 0x30(%rsp), %rdi
cmpq %r15, %rdi
jne 0xf8f3
jmp 0xf90f
jmp 0xf90c
jmp 0xf90c
movq %rax, %rbx
movq 0x90(%rsp), %rdi
cmpq %r15, %rdi
je 0xf90f
movq 0xa0(%rsp), %rsi
jmp 0xf8f8
jmp 0xf90c
jmp 0xf928
movq %rax, %rbx
leaq 0x40(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf90f
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x5470
jmp 0xf90f
jmp 0xf90c
jmp 0xf90c
jmp 0xf928
jmp 0xf90c
jmp 0xf928
movq %rax, %rbx
movq 0x10(%rsp), %rdi
cmpq %r14, %rdi
je 0xf92b
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x5470
jmp 0xf92b
movq %rax, %rbx
leaq 0x110(%rsp), %rdi
callq 0xfa0e
leaq 0x140(%rsp), %rdi
callq 0xbbdc
movq %rbx, %rdi
callq 0x57b0
nop