// File: /workspace/github_cpp_makefile_star2_O1/millanek[P]evo/./process_vcf_seq_utils.h
// Function: returnGenotypeBaseAndZeroOne(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::vector<char, std::allocator<char>> const&, char)
inline std::vector<std::string> returnGenotypeBaseAndZeroOne(const std::string& ref, const std::string& alt, const std::vector<char>& genotype, char hetTreatment) {
    std::vector<std::string> baseZeroOne;
    if (genotype[0] == '0' && genotype[1] == '0') {
        baseZeroOne.push_back(ref); baseZeroOne.push_back("0");
        return baseZeroOne;
    } else if (genotype[0] == '1' && genotype[1] == '1') {
        baseZeroOne.push_back(alt); baseZeroOne.push_back("1");
        return baseZeroOne;
    } else if (genotype[0] == '.' && genotype[1] == '.') { // Missing data
        baseZeroOne.push_back("."); baseZeroOne.push_back("0");
        return baseZeroOne;
    } else {
        if (hetTreatment == 'r') {
            double rn = ((double) rand() / RAND_MAX);
            if (rn <= 0.5) {
                baseZeroOne.push_back(ref); baseZeroOne.push_back("0");
                return baseZeroOne;
            } else {
                baseZeroOne.push_back(alt); baseZeroOne.push_back("1");
                return baseZeroOne;
            }
        } else if(hetTreatment == 'p') {
            if (genotype[0] == '0') {
                baseZeroOne.push_back(ref); baseZeroOne.push_back("0");
                return baseZeroOne;
            } else if (genotype[0] == '1') {
                baseZeroOne.push_back(alt); baseZeroOne.push_back("1");
                return baseZeroOne;
            }
        } else if (hetTreatment == 'b') {
            if (genotype[1] == '0') {
                baseZeroOne.push_back(ref); baseZeroOne.push_back("0");
                return baseZeroOne;
            } else if (genotype[1] == '1') {
                baseZeroOne.push_back(alt); baseZeroOne.push_back("1");
                return baseZeroOne;
            }
        } else {
            exit(1);
        }
    }
    exit(1);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
xorpd %xmm0, %xmm0
movupd %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movq (%rcx), %rcx
movb (%rcx), %al
cmpb $0x30, %al
jne 0x6e74b
cmpb $0x30, 0x1(%rcx)
jne 0x6e74b
movq %rbx, %rdi
movq %r15, %rsi
callq 0x33db0
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x60d61(%rip), %rsi     # 0xcf48d
leaq 0x60d5b(%rip), %rdx     # 0xcf48e
movq %rsp, %rdi
callq 0x28952
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x416a6
jmp 0x6e9ba
cmpb $0x31, %al
jne 0x6e78f
cmpb $0x31, 0x1(%rcx)
jne 0x6e78f
movq %rbx, %rdi
movq %r14, %rsi
callq 0x33db0
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x7b244(%rip), %rsi     # 0xe99b4
leaq 0x7b23e(%rip), %rdx     # 0xe99b5
movq %rsp, %rdi
callq 0x28952
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x416a6
jmp 0x6e9ba
cmpb $0x2e, %al
jne 0x6e802
cmpb $0x2e, 0x1(%rcx)
jne 0x6e802
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x71abc(%rip), %rsi     # 0xe0265
leaq 0x71ab6(%rip), %rdx     # 0xe0266
movq %rsp, %rdi
callq 0x28952
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x416a6
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x6e7d9
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x8480
movq %rsp, %rdi
movq %r15, (%rdi)
leaq 0x60ca7(%rip), %rsi     # 0xcf48d
leaq 0x60ca1(%rip), %rdx     # 0xcf48e
callq 0x28952
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x416a6
jmp 0x6e9ba
movsbl %r8b, %edx
cmpl $0x62, %edx
je 0x6e8bf
cmpl $0x70, %edx
je 0x6e87d
cmpl $0x72, %edx
jne 0x6e9dd
callq 0x8140
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd 0x5b8d7(%rip), %xmm0    # 0xca108
movsd 0x60c17(%rip), %xmm1    # 0xcf450
ucomisd %xmm0, %xmm1
jae 0x6e94e
movq %rbx, %rdi
movq %r14, %rsi
callq 0x33db0
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x7b156(%rip), %rsi     # 0xe99b4
leaq 0x7b150(%rip), %rdx     # 0xe99b5
movq %rsp, %rdi
callq 0x28952
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x416a6
jmp 0x6e9ba
cmpb $0x30, %al
jne 0x6e90f
movq %rbx, %rdi
movq %r15, %rsi
callq 0x33db0
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x60bed(%rip), %rsi     # 0xcf48d
leaq 0x60be7(%rip), %rdx     # 0xcf48e
movq %rsp, %rdi
callq 0x28952
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x416a6
jmp 0x6e9ba
movzbl 0x1(%rcx), %eax
cmpl $0x31, %eax
je 0x6e985
cmpl $0x30, %eax
jne 0x6e9dd
movq %rbx, %rdi
movq %r15, %rsi
callq 0x33db0
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x60b9d(%rip), %rsi     # 0xcf48d
leaq 0x60b97(%rip), %rdx     # 0xcf48e
movq %rsp, %rdi
callq 0x28952
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x416a6
jmp 0x6e9ba
cmpb $0x31, %al
jne 0x6e9dd
movq %rbx, %rdi
movq %r14, %rsi
callq 0x33db0
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x7b082(%rip), %rsi     # 0xe99b4
leaq 0x7b07c(%rip), %rdx     # 0xe99b5
movq %rsp, %rdi
callq 0x28952
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x416a6
jmp 0x6e9ba
movq %rbx, %rdi
movq %r15, %rsi
callq 0x33db0
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x60b24(%rip), %rsi     # 0xcf48d
leaq 0x60b1e(%rip), %rdx     # 0xcf48e
movq %rsp, %rdi
callq 0x28952
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x416a6
jmp 0x6e9ba
movq %rbx, %rdi
movq %r14, %rsi
callq 0x33db0
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x7b014(%rip), %rsi     # 0xe99b4
leaq 0x7b00e(%rip), %rdx     # 0xe99b5
movq %rsp, %rdi
callq 0x28952
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x416a6
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x6e9d0
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x8480
movq %rbx, %rax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movl $0x1, %edi
callq 0x8530
jmp 0x6ea0d
jmp 0x6ea0d
jmp 0x6ea0d
jmp 0x6ea0d
jmp 0x6ea0d
jmp 0x6ea2a
jmp 0x6ea0d
jmp 0x6ea2a
jmp 0x6ea2a
jmp 0x6ea2a
jmp 0x6ea2a
jmp 0x6ea2a
jmp 0x6ea0d
jmp 0x6ea2a
jmp 0x6ea0d
jmp 0x6ea2a
jmp 0x6ea2a
jmp 0x6ea0d
jmp 0x6ea2a
movq %rax, %r14
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x6ea2d
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x8480
jmp 0x6ea2d
jmp 0x6ea2a
movq %rax, %r14
movq %rbx, %rdi
callq 0x3123c
movq %r14, %rdi
callq 0x8840