// File: /workspace/github_cpp_makefile_star2_O3/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
movzbl (%rcx), %eax
cmpl $0x30, %eax
jne 0x6e41d
cmpb $0x30, 0x1(%rcx)
jne 0x6e4e0
movq %rbx, %rdi
movq %r15, %rsi
callq 0x3133c
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x5e347(%rip), %rsi     # 0xcc745
leaq 0x5e341(%rip), %rdx     # 0xcc746
movq %rsp, %rdi
callq 0x28a52
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x3e784
jmp 0x6e69b
cmpl $0x2e, %eax
je 0x6e471
cmpl $0x31, %eax
jne 0x6e4e0
movb $0x1, %dl
cmpb $0x31, 0x1(%rcx)
jne 0x6e4e2
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3133c
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x725da(%rip), %rsi     # 0xe0a2c
leaq 0x725d4(%rip), %rdx     # 0xe0a2d
movq %rsp, %rdi
callq 0x28a52
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x3e784
jmp 0x6e69b
cmpb $0x2e, 0x1(%rcx)
jne 0x6e4e0
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x6a3be(%rip), %rsi     # 0xd8845
leaq 0x6a3b8(%rip), %rdx     # 0xd8846
movq %rsp, %rdi
callq 0x28a52
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x3e784
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x6e4b7
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x8480
movq %rsp, %rdi
movq %r15, (%rdi)
leaq 0x5e281(%rip), %rsi     # 0xcc745
leaq 0x5e27b(%rip), %rdx     # 0xcc746
callq 0x28a52
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x3e784
jmp 0x6e69b
xorl %edx, %edx
movsbl %r8b, %esi
cmpl $0x62, %esi
je 0x6e5a0
cmpl $0x70, %esi
je 0x6e55d
cmpl $0x72, %esi
jne 0x6e6be
callq 0x8140
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd 0x61e0f(%rip), %xmm0    # 0xd0320
movsd 0x5e207(%rip), %xmm1    # 0xcc720
ucomisd %xmm0, %xmm1
jae 0x6e62f
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3133c
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x724ee(%rip), %rsi     # 0xe0a2c
leaq 0x724e8(%rip), %rdx     # 0xe0a2d
movq %rsp, %rdi
callq 0x28a52
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x3e784
jmp 0x6e69b
cmpl $0x30, %eax
jne 0x6e5f0
movq %rbx, %rdi
movq %r15, %rsi
callq 0x3133c
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x5e1c4(%rip), %rsi     # 0xcc745
leaq 0x5e1be(%rip), %rdx     # 0xcc746
movq %rsp, %rdi
callq 0x28a52
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x3e784
jmp 0x6e69b
movzbl 0x1(%rcx), %eax
cmpl $0x31, %eax
je 0x6e666
cmpl $0x30, %eax
jne 0x6e6be
movq %rbx, %rdi
movq %r15, %rsi
callq 0x3133c
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x5e174(%rip), %rsi     # 0xcc745
leaq 0x5e16e(%rip), %rdx     # 0xcc746
movq %rsp, %rdi
callq 0x28a52
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x3e784
jmp 0x6e69b
testb %dl, %dl
je 0x6e6be
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3133c
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x72419(%rip), %rsi     # 0xe0a2c
leaq 0x72413(%rip), %rdx     # 0xe0a2d
movq %rsp, %rdi
callq 0x28a52
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x3e784
jmp 0x6e69b
movq %rbx, %rdi
movq %r15, %rsi
callq 0x3133c
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x5e0fb(%rip), %rsi     # 0xcc745
leaq 0x5e0f5(%rip), %rdx     # 0xcc746
movq %rsp, %rdi
callq 0x28a52
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x3e784
jmp 0x6e69b
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3133c
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x723ab(%rip), %rsi     # 0xe0a2c
leaq 0x723a5(%rip), %rdx     # 0xe0a2d
movq %rsp, %rdi
callq 0x28a52
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x3e784
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x6e6b1
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 0x6e6ee
jmp 0x6e70b
jmp 0x6e6ee
jmp 0x6e6ee
jmp 0x6e70b
jmp 0x6e70b
jmp 0x6e6ee
jmp 0x6e6ee
jmp 0x6e6ee
jmp 0x6e6ee
jmp 0x6e6ee
jmp 0x6e70b
jmp 0x6e6ee
jmp 0x6e70b
jmp 0x6e70b
jmp 0x6e70b
jmp 0x6e70b
jmp 0x6e70b
jmp 0x6e70b
movq %rax, %r14
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x6e70e
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x8480
jmp 0x6e70e
jmp 0x6e70b
movq %rax, %r14
movq %rbx, %rdi
callq 0x2e784
movq %r14, %rdi
callq 0x8840