// File: /workspace/github_cpp_makefile_star2_O2/millanek[P]Dsuite/D.cpp
// Function: parseAbbaBabaOptions(int, char**)
void parseAbbaBabaOptions(int argc, char** argv) {
    bool die = false;
    std::vector<string> windowSizeStep;
    for (char c; (c = getopt_long(argc, argv, shortopts, longopts, NULL)) != -1;)
    {
        std::istringstream arg(optarg != NULL ? optarg : "");
        switch (c)
        {
            case '?': die = true; break;
            case 'w':
                windowSizeStep = split(arg.str(), ',');
                if(windowSizeStep.size() != 2) {std::cerr << "The -w option requires two arguments, separated by a comma ','\n"; exit(EXIT_FAILURE);}
                opt::windowSize = atoi(windowSizeStep[0].c_str());
                opt::windowStep = atoi(windowSizeStep[1].c_str());
                break;
            case 'n': arg >> opt::runName; break;
            case 'g': opt::useGenotypeProbabilities = true; break;
            case 'h':
                std::cout << ABBA_USAGE_MESSAGE;
                exit(EXIT_SUCCESS);
        }
    }
    
    if (argc - optind < 3) {
        std::cerr << "missing arguments\n";
        die = true;
    }
    else if (argc - optind > 3)
    {
        std::cerr << "too many arguments\n";
        die = true;
    }
    
    if (die) {
        std::cout << "\n" << ABBA_USAGE_MESSAGE;
        exit(EXIT_FAILURE);
    }
    
    // Parse the input filenames
    opt::vcfFile = argv[optind++];
    opt::setsFile = argv[optind++];
    opt::testTriosFile = argv[optind++];
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1e8, %rsp            # imm = 0x1E8
movq %rsi, %rbx
movl %edi, %ebp
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %rax
movaps %xmm0, (%rax)
andq $0x0, 0x10(%rax)
movq $0x0, 0x8(%rsp)
leaq 0x30(%rsp), %r15
leaq 0x50(%rsp), %r14
leaq 0x68(%rsp), %r12
movl %ebp, %edi
movq %rbx, %rsi
leaq 0x26c8c(%rip), %rdx     # 0x36c99
leaq 0x4043c(%rip), %rcx     # 0x50450
xorl %r8d, %r8d
callq 0x76b0
movl %eax, %r13d
shll $0x18, %eax
cmpl $0xff000000, %eax       # imm = 0xFF000000
je 0x10131
movq 0x40f34(%rip), %rax     # 0x50f68
movq (%rax), %rsi
testq %rsi, %rsi
leaq 0x28f90(%rip), %rax     # 0x38fd1
cmoveq %rax, %rsi
movq %r15, %rdi
movq %r14, %rdx
callq 0x8102
movq %r12, %rdi
movq %r15, %rsi
pushq $0x8
popq %rdx
callq 0x76c0
movsbl %r13b, %r13d
movq %r15, %rdi
callq 0x7898
cmpl $0x3f, %r13d
je 0x1009d
cmpl $0x67, %r13d
je 0x10091
cmpl $0x6e, %r13d
je 0x100a6
cmpl $0x77, %r13d
je 0x100b7
cmpl $0x68, %r13d
jne 0x10124
jmp 0x101bb
movb $0x1, 0x41918(%rip)     # 0x519b0
jmp 0x10124
movb $0x1, %al
movq %rax, 0x8(%rsp)
jmp 0x10124
movq %r12, %rdi
leaq 0x418e0(%rip), %rsi     # 0x51990
callq 0x7520
jmp 0x10124
movq %r15, %rdi
leaq 0x78(%rsp), %rsi
callq 0x7650
movq %r14, %rdi
movq %r15, %rsi
pushq $0x2c
popq %rdx
callq 0x88f1
leaq 0x10(%rsp), %rdi
movq %r14, %rsi
callq 0x1455c
movq %r14, %rdi
callq 0xb80c
movq %r15, %rdi
callq 0x7898
movq 0x10(%rsp), %r13
movq 0x18(%rsp), %rax
subq %r13, %rax
cmpq $0x40, %rax
jne 0x101d5
movq (%r13), %rdi
callq 0x7640
movl %eax, 0x4135b(%rip)     # 0x51470
movq 0x20(%r13), %rdi
callq 0x7640
movl %eax, 0x41350(%rip)     # 0x51474
movq %r12, %rdi
callq 0x71d0
jmp 0x10001
movq 0x40e68(%rip), %r14     # 0x50fa0
movslq (%r14), %rax
subl %eax, %ebp
cmpl $0x3, %ebp
jl 0x101f0
jne 0x101f9
testb $0x1, 0x8(%rsp)
jne 0x1020c
leal 0x1(%rax), %ecx
movl %ecx, (%r14)
movq (%rbx,%rax,8), %rsi
leaq 0x417c8(%rip), %rdi     # 0x51930
callq 0x7800
movslq (%r14), %rax
leal 0x1(%rax), %ecx
movl %ecx, (%r14)
movq (%rbx,%rax,8), %rsi
leaq 0x417cf(%rip), %rdi     # 0x51950
callq 0x7800
movslq (%r14), %rax
leal 0x1(%rax), %ecx
movl %ecx, (%r14)
movq (%rbx,%rax,8), %rsi
leaq 0x417d6(%rip), %rdi     # 0x51970
callq 0x7800
leaq 0x10(%rsp), %rdi
callq 0xb80c
addq $0x1e8, %rsp            # imm = 0x1E8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x40dd6(%rip), %rdi     # 0x50f98
leaq 0x26afb(%rip), %rsi     # 0x36cc4
callq 0x7400
xorl %edi, %edi
callq 0x74f0
movq 0x40e0c(%rip), %rdi     # 0x50fe8
leaq 0x26817(%rip), %rsi     # 0x369fa
callq 0x7400
pushq $0x1
popq %rdi
callq 0x74f0
leaq 0x26843(%rip), %rsi     # 0x36a3a
jmp 0x10200
leaq 0x2684d(%rip), %rsi     # 0x36a4d
movq 0x40de1(%rip), %rdi     # 0x50fe8
callq 0x7400
movq 0x40d85(%rip), %rdi     # 0x50f98
leaq 0x26220(%rip), %rsi     # 0x3643a
callq 0x7400
leaq 0x26a9e(%rip), %rsi     # 0x36cc4
movq %rax, %rdi
callq 0x7400
jmp 0x101e8
jmp 0x10254
jmp 0x10245
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0x7898
jmp 0x10248
jmp 0x10245
movq %rax, %rbx
leaq 0x68(%rsp), %rdi
callq 0x71d0
jmp 0x10266
movq %rax, %rbx
jmp 0x10266
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0x7898
leaq 0x10(%rsp), %rdi
callq 0xb80c
movq %rbx, %rdi
callq 0x7750