// File: 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 %rbp
movq %rsp, %rbp
subq $0x230, %rsp            # imm = 0x230
movq %rdi, -0x1e0(%rbp)
movb %r8b, %al
movq %rdi, %r8
movq %r8, -0x1d8(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movb %al, -0x21(%rbp)
movb $0x0, -0x22(%rbp)
callq 0x48da0
movq -0x20(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0xae8a0
movsbl (%rax), %eax
cmpl $0x30, %eax
jne 0xadb3f
movq -0x20(%rbp), %rdi
movl $0x1, %esi
callq 0xae8a0
movsbl (%rax), %eax
cmpl $0x30, %eax
jne 0xadb3f
movq -0x1e0(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x48dc0
jmp 0xadaa0
leaq -0x59(%rbp), %rdi
movq %rdi, -0x1e8(%rbp)
callq 0xab60
movq -0x1e8(%rbp), %rdx
leaq 0x85c2f(%rip), %rsi     # 0x1336ed
leaq -0x58(%rbp), %rdi
callq 0x2d6c0
jmp 0xadac9
movq -0x1e0(%rbp), %rdi
leaq -0x58(%rbp), %rsi
callq 0x5f980
jmp 0xadadb
leaq -0x58(%rbp), %rdi
callq 0xac88
leaq -0x59(%rbp), %rdi
callq 0xa640
movb $0x1, -0x22(%rbp)
movl $0x1, -0x60(%rbp)
jmp 0xae2a5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
jmp 0xae2c7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
jmp 0xadb31
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x58(%rbp), %rdi
callq 0xac88
leaq -0x59(%rbp), %rdi
callq 0xa640
jmp 0xae2c7
movq -0x20(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0xae8a0
movsbl (%rax), %eax
cmpl $0x31, %eax
jne 0xadc1b
movq -0x20(%rbp), %rdi
movl $0x1, %esi
callq 0xae8a0
movsbl (%rax), %eax
cmpl $0x31, %eax
jne 0xadc1b
movq -0x1e0(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x48dc0
jmp 0xadb84
leaq -0x81(%rbp), %rdi
movq %rdi, -0x1f0(%rbp)
callq 0xab60
movq -0x1f0(%rbp), %rdx
leaq 0xa091b(%rip), %rsi     # 0x14e4c0
leaq -0x80(%rbp), %rdi
callq 0x2d6c0
jmp 0xadbb0
movq -0x1e0(%rbp), %rdi
leaq -0x80(%rbp), %rsi
callq 0x5f980
jmp 0xadbc2
leaq -0x80(%rbp), %rdi
callq 0xac88
leaq -0x81(%rbp), %rdi
callq 0xa640
movb $0x1, -0x22(%rbp)
movl $0x1, -0x60(%rbp)
jmp 0xae2a5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
jmp 0xadc0a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x80(%rbp), %rdi
callq 0xac88
leaq -0x81(%rbp), %rdi
callq 0xa640
jmp 0xae2c7
movq -0x20(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0xae8a0
movsbl (%rax), %eax
cmpl $0x2e, %eax
jne 0xadd84
movq -0x20(%rbp), %rdi
movl $0x1, %esi
callq 0xae8a0
movsbl (%rax), %eax
cmpl $0x2e, %eax
jne 0xadd84
leaq -0xa9(%rbp), %rdi
movq %rdi, -0x1f8(%rbp)
callq 0xab60
movq -0x1f8(%rbp), %rdx
leaq 0x96ab5(%rip), %rsi     # 0x144724
leaq -0xa8(%rbp), %rdi
callq 0x2d6c0
jmp 0xadc7d
movq -0x1e0(%rbp), %rdi
leaq -0xa8(%rbp), %rsi
callq 0x5f980
jmp 0xadc92
leaq -0xa8(%rbp), %rdi
callq 0xac88
leaq -0xa9(%rbp), %rdi
callq 0xa640
leaq -0xd1(%rbp), %rdi
movq %rdi, -0x200(%rbp)
callq 0xab60
movq -0x200(%rbp), %rdx
leaq 0x85a22(%rip), %rsi     # 0x1336ed
leaq -0xd0(%rbp), %rdi
callq 0x2d6c0
jmp 0xadcd9
movq -0x1e0(%rbp), %rdi
leaq -0xd0(%rbp), %rsi
callq 0x5f980
jmp 0xadcee
leaq -0xd0(%rbp), %rdi
callq 0xac88
leaq -0xd1(%rbp), %rdi
callq 0xa640
movb $0x1, -0x22(%rbp)
movl $0x1, -0x60(%rbp)
jmp 0xae2a5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
jmp 0xadd3c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0xa8(%rbp), %rdi
callq 0xac88
leaq -0xa9(%rbp), %rdi
callq 0xa640
jmp 0xae2c7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
jmp 0xadd73
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0xd0(%rbp), %rdi
callq 0xac88
leaq -0xd1(%rbp), %rdi
callq 0xa640
jmp 0xae2c7
movsbl -0x21(%rbp), %eax
cmpl $0x72, %eax
jne 0xadf2e
callq 0xa180
cvtsi2sd %eax, %xmm0
movsd 0x8d386(%rip), %xmm1    # 0x13b128
divsd %xmm1, %xmm0
movsd %xmm0, -0xe0(%rbp)
movsd 0x80352(%rip), %xmm0    # 0x12e108
ucomisd -0xe0(%rbp), %xmm0
jb 0xade79
movq -0x1e0(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x48dc0
jmp 0xaddd6
leaq -0x101(%rbp), %rdi
movq %rdi, -0x208(%rbp)
callq 0xab60
movq -0x208(%rbp), %rdx
leaq 0x858f6(%rip), %rsi     # 0x1336ed
leaq -0x100(%rbp), %rdi
callq 0x2d6c0
jmp 0xade05
movq -0x1e0(%rbp), %rdi
leaq -0x100(%rbp), %rsi
callq 0x5f980
jmp 0xade1a
leaq -0x100(%rbp), %rdi
callq 0xac88
leaq -0x101(%rbp), %rdi
callq 0xa640
movb $0x1, -0x22(%rbp)
movl $0x1, -0x60(%rbp)
jmp 0xae2a5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
jmp 0xade68
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x100(%rbp), %rdi
callq 0xac88
leaq -0x101(%rbp), %rdi
callq 0xa640
jmp 0xae2c7
movq -0x1e0(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x48dc0
jmp 0xade8b
leaq -0x129(%rbp), %rdi
movq %rdi, -0x210(%rbp)
callq 0xab60
movq -0x210(%rbp), %rdx
leaq 0xa0614(%rip), %rsi     # 0x14e4c0
leaq -0x128(%rbp), %rdi
callq 0x2d6c0
jmp 0xadeba
movq -0x1e0(%rbp), %rdi
leaq -0x128(%rbp), %rsi
callq 0x5f980
jmp 0xadecf
leaq -0x128(%rbp), %rdi
callq 0xac88
leaq -0x129(%rbp), %rdi
callq 0xa640
movb $0x1, -0x22(%rbp)
movl $0x1, -0x60(%rbp)
jmp 0xae2a5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
jmp 0xadf1d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x128(%rbp), %rdi
callq 0xac88
leaq -0x129(%rbp), %rdi
callq 0xa640
jmp 0xae2c7
movsbl -0x21(%rbp), %eax
cmpl $0x70, %eax
jne 0xae0de
movq -0x20(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0xae8a0
movsbl (%rax), %eax
cmpl $0x30, %eax
jne 0xae009
movq -0x1e0(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x48dc0
jmp 0xadf66
leaq -0x151(%rbp), %rdi
movq %rdi, -0x218(%rbp)
callq 0xab60
movq -0x218(%rbp), %rdx
leaq 0x85766(%rip), %rsi     # 0x1336ed
leaq -0x150(%rbp), %rdi
callq 0x2d6c0
jmp 0xadf95
movq -0x1e0(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x5f980
jmp 0xadfaa
leaq -0x150(%rbp), %rdi
callq 0xac88
leaq -0x151(%rbp), %rdi
callq 0xa640
movb $0x1, -0x22(%rbp)
movl $0x1, -0x60(%rbp)
jmp 0xae2a5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
jmp 0xadff8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x150(%rbp), %rdi
callq 0xac88
leaq -0x151(%rbp), %rdi
callq 0xa640
jmp 0xae2c7
movq -0x20(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0xae8a0
movsbl (%rax), %eax
cmpl $0x31, %eax
jne 0xae0d7
movq -0x1e0(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x48dc0
jmp 0xae034
leaq -0x179(%rbp), %rdi
movq %rdi, -0x220(%rbp)
callq 0xab60
movq -0x220(%rbp), %rdx
leaq 0xa046b(%rip), %rsi     # 0x14e4c0
leaq -0x178(%rbp), %rdi
callq 0x2d6c0
jmp 0xae063
movq -0x1e0(%rbp), %rdi
leaq -0x178(%rbp), %rsi
callq 0x5f980
jmp 0xae078
leaq -0x178(%rbp), %rdi
callq 0xac88
leaq -0x179(%rbp), %rdi
callq 0xa640
movb $0x1, -0x22(%rbp)
movl $0x1, -0x60(%rbp)
jmp 0xae2a5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
jmp 0xae0c6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x178(%rbp), %rdi
callq 0xac88
leaq -0x179(%rbp), %rdi
callq 0xa640
jmp 0xae2c7
jmp 0xae0d9
jmp 0xae293
movsbl -0x21(%rbp), %eax
cmpl $0x62, %eax
jne 0xae287
movq -0x20(%rbp), %rdi
movl $0x1, %esi
callq 0xae8a0
movsbl (%rax), %eax
cmpl $0x30, %eax
jne 0xae1ba
movq -0x1e0(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x48dc0
jmp 0xae117
leaq -0x1a1(%rbp), %rdi
movq %rdi, -0x228(%rbp)
callq 0xab60
movq -0x228(%rbp), %rdx
leaq 0x855b5(%rip), %rsi     # 0x1336ed
leaq -0x1a0(%rbp), %rdi
callq 0x2d6c0
jmp 0xae146
movq -0x1e0(%rbp), %rdi
leaq -0x1a0(%rbp), %rsi
callq 0x5f980
jmp 0xae15b
leaq -0x1a0(%rbp), %rdi
callq 0xac88
leaq -0x1a1(%rbp), %rdi
callq 0xa640
movb $0x1, -0x22(%rbp)
movl $0x1, -0x60(%rbp)
jmp 0xae2a5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
jmp 0xae1a9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x1a0(%rbp), %rdi
callq 0xac88
leaq -0x1a1(%rbp), %rdi
callq 0xa640
jmp 0xae2c7
movq -0x20(%rbp), %rdi
movl $0x1, %esi
callq 0xae8a0
movsbl (%rax), %eax
cmpl $0x31, %eax
jne 0xae283
movq -0x1e0(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x48dc0
jmp 0xae1e6
leaq -0x1c9(%rbp), %rdi
movq %rdi, -0x230(%rbp)
callq 0xab60
movq -0x230(%rbp), %rdx
leaq 0xa02b9(%rip), %rsi     # 0x14e4c0
leaq -0x1c8(%rbp), %rdi
callq 0x2d6c0
jmp 0xae215
movq -0x1e0(%rbp), %rdi
leaq -0x1c8(%rbp), %rsi
callq 0x5f980
jmp 0xae22a
leaq -0x1c8(%rbp), %rdi
callq 0xac88
leaq -0x1c9(%rbp), %rdi
callq 0xa640
movb $0x1, -0x22(%rbp)
movl $0x1, -0x60(%rbp)
jmp 0xae2a5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
jmp 0xae275
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x1c8(%rbp), %rdi
callq 0xac88
leaq -0x1c9(%rbp), %rdi
callq 0xa640
jmp 0xae2c7
jmp 0xae285
jmp 0xae291
movl $0x1, %edi
callq 0xa700
jmp 0xae293
jmp 0xae295
jmp 0xae297
jmp 0xae299
jmp 0xae29b
movl $0x1, %edi
callq 0xa700
testb $0x1, -0x22(%rbp)
jne 0xae2b7
movq -0x1e0(%rbp), %rdi
callq 0x3dfa0
movq -0x1d8(%rbp), %rax
addq $0x230, %rsp            # imm = 0x230
popq %rbp
retq
movq -0x1e0(%rbp), %rdi
callq 0x3dfa0
movq -0x30(%rbp), %rdi
callq 0xab50
nopl (%rax)