// File: medvedevgroup[P]varmatch/src/./diploidvariant.h
// Function: DiploidVariant::operator==(DiploidVariant const&)
bool operator ==(const DiploidVariant& y) {
        if (pos == y.pos && ref == y.ref) {
            if(heterozygous == y.heterozygous && multi_alts == y.multi_alts){
                if (multi_alts && heterozygous) {
                    int match_times = 0;
                    for (int i = 0; i < 2; i++) {
                        for (int j = 0; j < 2; j++) {
                            if (alts[i] == y.alts[j])
                                match_times++;
                        }
                    }
                    if (match_times >= 2)
                        return true;
                }
                else if(alts[0] == y.alts[0]){
                    return true;
                }
            }
            if(multi_alts && zero_one_var && y.multi_alts && y.zero_one_var){
                int match_times = 0;
                for (int i = 0; i < 2; i++) {
                    for (int j = 0; j < 2; j++) {
                        if (alts[i] == y.alts[j])
                            match_times++;
                    }
                }
                if(match_times > 1) return true;
            }
        }
        return false;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x38(%rbp)
movl (%rax), %eax
movq -0x18(%rbp), %rcx
cmpl (%rcx), %eax
jne 0x34088
movq -0x38(%rbp), %rdi
addq $0x8, %rdi
movq -0x18(%rbp), %rsi
addq $0x8, %rsi
callq 0xdcb0
testb $0x1, %al
jne 0x33e94
jmp 0x34088
movq -0x38(%rbp), %rax
movb 0x40(%rax), %al
andb $0x1, %al
movzbl %al, %eax
movq -0x18(%rbp), %rcx
movb 0x40(%rcx), %cl
andb $0x1, %cl
movzbl %cl, %ecx
cmpl %ecx, %eax
jne 0x33fc4
movq -0x38(%rbp), %rax
movb 0x41(%rax), %al
andb $0x1, %al
movzbl %al, %eax
movq -0x18(%rbp), %rcx
movb 0x41(%rcx), %cl
andb $0x1, %cl
movzbl %cl, %ecx
cmpl %ecx, %eax
jne 0x33fc4
movq -0x38(%rbp), %rax
testb $0x1, 0x41(%rax)
je 0x33f7f
movq -0x38(%rbp), %rax
testb $0x1, 0x40(%rax)
je 0x33f7f
movl $0x0, -0x1c(%rbp)
movl $0x0, -0x20(%rbp)
cmpl $0x2, -0x20(%rbp)
jge 0x33f6e
movl $0x0, -0x24(%rbp)
cmpl $0x2, -0x24(%rbp)
jge 0x33f61
movq -0x38(%rbp), %rdi
addq $0x28, %rdi
movslq -0x20(%rbp), %rsi
callq 0x9080
movq %rax, -0x40(%rbp)
movq -0x18(%rbp), %rdi
addq $0x28, %rdi
movslq -0x24(%rbp), %rsi
callq 0x386e0
movq -0x40(%rbp), %rdi
movq %rax, %rsi
callq 0xdcb0
testb $0x1, %al
jne 0x33f4b
jmp 0x33f54
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x33f56
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x33f0d
jmp 0x33f63
movl -0x20(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x20(%rbp)
jmp 0x33f00
cmpl $0x2, -0x1c(%rbp)
jl 0x33f7d
movb $0x1, -0x1(%rbp)
jmp 0x3408c
jmp 0x33fc2
movq -0x38(%rbp), %rdi
addq $0x28, %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x9080
movq %rax, -0x48(%rbp)
movq -0x18(%rbp), %rdi
addq $0x28, %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x386e0
movq -0x48(%rbp), %rdi
movq %rax, %rsi
callq 0xdcb0
testb $0x1, %al
jne 0x33fb7
jmp 0x33fc0
movb $0x1, -0x1(%rbp)
jmp 0x3408c
jmp 0x33fc2
jmp 0x33fc4
movq -0x38(%rbp), %rax
testb $0x1, 0x41(%rax)
je 0x34086
movq -0x38(%rbp), %rax
testb $0x1, 0x42(%rax)
je 0x34086
movq -0x18(%rbp), %rax
testb $0x1, 0x41(%rax)
je 0x34086
movq -0x18(%rbp), %rax
testb $0x1, 0x42(%rax)
je 0x34086
movl $0x0, -0x28(%rbp)
movl $0x0, -0x2c(%rbp)
cmpl $0x2, -0x2c(%rbp)
jge 0x34078
movl $0x0, -0x30(%rbp)
cmpl $0x2, -0x30(%rbp)
jge 0x3406b
movq -0x38(%rbp), %rdi
addq $0x28, %rdi
movslq -0x2c(%rbp), %rsi
callq 0x9080
movq %rax, -0x50(%rbp)
movq -0x18(%rbp), %rdi
addq $0x28, %rdi
movslq -0x30(%rbp), %rsi
callq 0x386e0
movq -0x50(%rbp), %rdi
movq %rax, %rsi
callq 0xdcb0
testb $0x1, %al
jne 0x34055
jmp 0x3405e
movl -0x28(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x28(%rbp)
jmp 0x34060
movl -0x30(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x30(%rbp)
jmp 0x34017
jmp 0x3406d
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x3400a
cmpl $0x1, -0x28(%rbp)
jle 0x34084
movb $0x1, -0x1(%rbp)
jmp 0x3408c
jmp 0x34086
jmp 0x34088
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x50, %rsp
popq %rbp
retq
nopw (%rax,%rax)