// File: /workspace/github_cpp_makefile_star2_O1/Mariotti94[P]BigFloat/BigFloat.cc
// Function: BigFloat::CompareNum(BigFloat const&, BigFloat const&)
int BigFloat::CompareNum(const BigFloat& left, const BigFloat& right)
{
    if((left.number.size() - left.decimals) > (right.number.size() - right.decimals))
        return 1;
    else if((left.number.size() - left.decimals) < (right.number.size() - right.decimals))
        return 2;

    if(left.decimals > right.decimals) {
        BigFloat tmp;
        tmp = right;
        while(left.decimals > tmp.decimals) {
            tmp.decimals++;
            tmp.number.push_front('0');
        }

        for(int i = left.number.size() - 1; i >= 0; i--) {
            if(left.number[i] > tmp.number[i])
                return 1;
            else if(left.number[i] < tmp.number[i])
                return 2;
        }
        return 0;
    }
    else if(left.decimals < right.decimals) {
        BigFloat tmp;
        tmp = left;
        while(tmp.decimals < right.decimals) {
            tmp.decimals++;
            tmp.number.push_front('0');
        }

        for(int i = tmp.number.size() - 1; i >= 0; i--) {
            if(tmp.number[i] > right.number[i])
                return 1;
            else if(tmp.number[i] < right.number[i])
                return 2;
        }
        return 0;
    }
    else {
        for(int i = left.number.size() - 1; i >= 0; i--) {
            if(left.number[i] > right.number[i])
                return 1;
            else if(left.number[i] < right.number[i])
                return 2;
        }
        return 0;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movq %rsi, %r15
movq %rdi, %r14
movq 0x50(%rdi), %rax
movq 0x30(%rdi), %rdx
movq %rax, %rcx
movq %rdx, 0xa0(%rsp)
subq %rdx, %rcx
shrq $0x3, %rcx
cmpq $0x1, %rax
adcq $-0x1, %rcx
shlq $0x9, %rcx
movq 0x38(%rdi), %rax
movq 0x40(%rdi), %r11
movq 0x18(%rdi), %rdx
movq 0x28(%rdi), %r9
movq %rax, %r8
subq %r11, %r8
addq %r9, %r8
addq %rcx, %r8
movslq 0x58(%rdi), %r10
movq %rdx, 0x98(%rsp)
addq %r10, %rdx
subq %rdx, %r8
movq 0x50(%rsi), %rdx
movq 0x18(%rsi), %r12
movq 0x30(%rsi), %rsi
movq %rdx, %rbx
movq %rsi, 0x90(%rsp)
subq %rsi, %rbx
shrq $0x3, %rbx
cmpq $0x1, %rdx
adcq $-0x1, %rbx
shlq $0x9, %rbx
movq 0x38(%r15), %rdi
subq 0x40(%r15), %rdi
movslq 0x58(%r15), %rdx
addq 0x28(%r15), %rdi
addq %rbx, %rdi
movq %r12, %rsi
subq %r12, %rdi
subq %rdx, %rdi
leaq 0x8(%r14), %r12
leaq 0x58(%r14), %rbx
leaq 0x8(%r15), %r13
leaq 0x58(%r15), %rbp
cmpq %rdi, %r8
jbe 0x2f30
movl $0x1, %ebx
jmp 0x3486
jae 0x2f3c
movl $0x2, %ebx
jmp 0x3486
cmpl %edx, %r10d
jle 0x3129
leaq 0x10(%rsp), %r12
movq %r12, %rdi
callq 0x27f8
movb (%r15), %al
movb %al, (%r12)
leaq 0x18(%rsp), %rdi
movq %r13, %rsi
callq 0x9d7e
movb 0x4(%rbp), %al
leaq 0x70(%rsp), %rdi
movb %al, -0x4(%rdi)
movl (%rbp), %eax
movl %eax, -0x8(%rdi)
addq $0x60, %r15
movq %r15, %rsi
callq 0x20a0
movl 0x68(%rsp), %eax
cmpl %eax, (%rbx)
jle 0x2fc7
leaq 0xf(%rsp), %r15
incl %eax
movl %eax, 0x68(%rsp)
movb $0x30, 0xf(%rsp)
movq 0x28(%rsp), %rax
cmpq 0x30(%rsp), %rax
je 0x2fb2
movb $0x30, -0x1(%rax)
decq 0x28(%rsp)
jmp 0x2fbf
leaq 0x18(%rsp), %rdi
movq %r15, %rsi
callq 0xb6e0
movl 0x68(%rsp), %eax
cmpl %eax, (%rbx)
jg 0x2f90
movabsq $-0x80000000000000, %rax # imm = 0xFF80000000000000
movq 0x50(%r14), %rsi
movq 0x18(%r14), %rcx
movq 0x30(%r14), %rdx
movl %esi, %r11d
subl %edx, %r11d
shrl $0x3, %r11d
cmpq $0x1, %rsi
adcl $-0x1, %r11d
shll $0x9, %r11d
movl 0x38(%r14), %esi
movq %rcx, %rdi
subq 0x20(%r14), %rdi
movq 0x28(%rsp), %r8
movq %r8, %r9
subq 0x30(%rsp), %r9
movq 0x40(%rsp), %r10
addl 0x28(%r14), %esi
addl %r11d, %esi
movl 0x40(%r14), %r11d
addl %ecx, %r11d
subl %r11d, %esi
decq %rsi
testl %esi, %esi
js 0x331b
movl %esi, %ebx
andl $0x7fffffff, %ebx       # imm = 0x7FFFFFFF
leaq (%rdi,%rbx), %r11
cmpq $0x1ff, %r11            # imm = 0x1FF
ja 0x3047
leaq (%rcx,%rbx), %r15
jmp 0x306c
movq %r11, %r14
shrq $0x9, %r14
movq %r14, %r13
orq %rax, %r13
testq %r11, %r11
cmovgq %r14, %r13
movq %r13, %r14
shlq $0x9, %r14
movq %r11, %r15
subq %r14, %r15
addq (%rdx,%r13,8), %r15
leaq (%r9,%rbx), %r14
cmpq $0x1ff, %r14            # imm = 0x1FF
ja 0x307f
leaq (%r8,%rbx), %r13
jmp 0x30a4
movq %r14, %r13
shrq $0x9, %r13
movq %r13, %rbp
orq %rax, %rbp
testq %r14, %r14
cmovgq %r13, %rbp
movq %rbp, %r12
shlq $0x9, %r12
movq %r14, %r13
subq %r12, %r13
addq (%r10,%rbp,8), %r13
movb (%r15), %bpl
cmpb (%r13), %bpl
jg 0x3461
cmpq $0x1ff, %r11            # imm = 0x1FF
ja 0x30c0
leaq (%rcx,%rbx), %r11
jmp 0x30e2
movq %r11, %r15
shrq $0x9, %r15
movq %r15, %r12
orq %rax, %r12
testq %r11, %r11
cmovgq %r15, %r12
movq %r12, %r15
shlq $0x9, %r15
subq %r15, %r11
addq (%rdx,%r12,8), %r11
cmpq $0x1ff, %r14            # imm = 0x1FF
ja 0x30f0
addq %r8, %rbx
jmp 0x3115
movq %r14, %rbx
shrq $0x9, %rbx
movq %rbx, %r15
orq %rax, %r15
testq %r14, %r14
cmovgq %rbx, %r15
movq %r15, %rbx
shlq $0x9, %rbx
subq %rbx, %r14
addq (%r10,%r15,8), %r14
movq %r14, %rbx
movb (%r11), %r11b
decq %rsi
cmpb (%rbx), %r11b
jge 0x3024
jmp 0x3311
jge 0x3322
leaq 0x10(%rsp), %r13
movq %r13, %rdi
callq 0x27f8
movb (%r14), %al
movb %al, (%r13)
leaq 0x18(%rsp), %rdi
movq %r12, %rsi
callq 0x9d7e
movb 0x4(%rbx), %al
leaq 0x70(%rsp), %rdi
movb %al, -0x4(%rdi)
movl (%rbx), %eax
movl %eax, -0x8(%rdi)
addq $0x60, %r14
movq %r14, %rsi
callq 0x20a0
movl 0x68(%rsp), %eax
cmpl (%rbp), %eax
jge 0x31b2
leaq 0xf(%rsp), %r14
incl %eax
movl %eax, 0x68(%rsp)
movb $0x30, 0xf(%rsp)
movq 0x28(%rsp), %rax
cmpq 0x30(%rsp), %rax
je 0x319c
movb $0x30, -0x1(%rax)
decq 0x28(%rsp)
jmp 0x31a9
leaq 0x18(%rsp), %rdi
movq %r14, %rsi
callq 0xb6e0
movl 0x68(%rsp), %eax
cmpl (%rbp), %eax
jl 0x317a
movabsq $-0x80000000000000, %rax # imm = 0xFF80000000000000
movq 0x60(%rsp), %rsi
movq 0x28(%rsp), %rcx
movq 0x40(%rsp), %rdx
movl %esi, %r11d
subl %edx, %r11d
shrl $0x3, %r11d
cmpq $0x1, %rsi
adcl $-0x1, %r11d
shll $0x9, %r11d
movl 0x48(%rsp), %esi
movq %rcx, %rdi
subq 0x30(%rsp), %rdi
movq 0x18(%r15), %r8
movq %r8, %r9
subq 0x20(%r15), %r9
movq 0x30(%r15), %r10
addl 0x38(%rsp), %esi
addl %r11d, %esi
movl 0x50(%rsp), %r11d
addl %ecx, %r11d
subl %r11d, %esi
decq %rsi
testl %esi, %esi
js 0x331b
movl %esi, %ebx
andl $0x7fffffff, %ebx       # imm = 0x7FFFFFFF
leaq (%rdi,%rbx), %r11
cmpq $0x1ff, %r11            # imm = 0x1FF
ja 0x3234
leaq (%rcx,%rbx), %r15
jmp 0x3259
movq %r11, %r14
shrq $0x9, %r14
movq %r14, %r12
orq %rax, %r12
testq %r11, %r11
cmovgq %r14, %r12
movq %r12, %r14
shlq $0x9, %r14
movq %r11, %r15
subq %r14, %r15
addq (%rdx,%r12,8), %r15
leaq (%r9,%rbx), %r14
cmpq $0x1ff, %r14            # imm = 0x1FF
ja 0x326c
leaq (%r8,%rbx), %r12
jmp 0x3291
movq %r14, %r12
shrq $0x9, %r12
movq %r12, %rbp
orq %rax, %rbp
testq %r14, %r14
cmovgq %r12, %rbp
movq %rbp, %r13
shlq $0x9, %r13
movq %r14, %r12
subq %r13, %r12
addq (%r10,%rbp,8), %r12
movb (%r15), %bpl
cmpb (%r12), %bpl
jg 0x3461
cmpq $0x1ff, %r11            # imm = 0x1FF
ja 0x32ad
leaq (%rcx,%rbx), %r11
jmp 0x32cf
movq %r11, %r15
shrq $0x9, %r15
movq %r15, %r12
orq %rax, %r12
testq %r11, %r11
cmovgq %r15, %r12
movq %r12, %r15
shlq $0x9, %r15
subq %r15, %r11
addq (%rdx,%r12,8), %r11
cmpq $0x1ff, %r14            # imm = 0x1FF
ja 0x32dd
addq %r8, %rbx
jmp 0x3302
movq %r14, %rbx
shrq $0x9, %rbx
movq %rbx, %r15
orq %rax, %r15
testq %r14, %r14
cmovgq %rbx, %r15
movq %r15, %rbx
shlq $0x9, %rbx
subq %rbx, %r14
addq (%r10,%r15,8), %r14
movq %r14, %rbx
movb (%r11), %r11b
decq %rsi
cmpb (%rbx), %r11b
jge 0x3211
movl $0x2, %ebx
jmp 0x3466
xorl %ebx, %ebx
jmp 0x3466
movabsq $-0x80000000000000, %r12 # imm = 0xFF80000000000000
movq 0x98(%rsp), %rbp
movq %rbp, %r13
subq 0x20(%r14), %r13
movq %rsi, %r10
subq 0x20(%r15), %r10
addl %r9d, %eax
addl %eax, %ecx
addl %ebp, %r11d
subl %r11d, %ecx
decq %rcx
movq 0xa0(%rsp), %r14
movq 0x90(%rsp), %r15
testl %ecx, %ecx
js 0x349a
movl %ecx, %ebx
andl $0x7fffffff, %ebx       # imm = 0x7FFFFFFF
leaq (%rbx,%r13), %r11
cmpq $0x1ff, %r11            # imm = 0x1FF
ja 0x3383
leaq (%rbx,%rbp), %rax
jmp 0x33a8
movq %r11, %rax
shrq $0x9, %rax
movq %rax, %rdx
orq %r12, %rdx
testq %r11, %r11
cmovgq %rax, %rdx
movq %rdx, %rdi
shlq $0x9, %rdi
movq %r11, %rax
subq %rdi, %rax
addq (%r14,%rdx,8), %rax
leaq (%r10,%rbx), %r8
cmpq $0x1ff, %r8             # imm = 0x1FF
ja 0x33bb
leaq (%rsi,%rbx), %rdx
jmp 0x33e0
movq %r8, %rdx
shrq $0x9, %rdx
movq %rdx, %rdi
orq %r12, %rdi
testq %r8, %r8
cmovgq %rdx, %rdi
movq %rdi, %r9
shlq $0x9, %r9
movq %r8, %rdx
subq %r9, %rdx
addq (%r15,%rdi,8), %rdx
movb (%rax), %al
cmpb (%rdx), %al
jg 0x2f26
cmpq $0x1ff, %r11            # imm = 0x1FF
ja 0x33f9
leaq (%rbx,%rbp), %r11
jmp 0x341b
movq %r11, %rax
shrq $0x9, %rax
movq %rax, %rdx
orq %r12, %rdx
testq %r11, %r11
cmovgq %rax, %rdx
movq %rdx, %rax
shlq $0x9, %rax
subq %rax, %r11
addq (%r14,%rdx,8), %r11
cmpq $0x1ff, %r8             # imm = 0x1FF
ja 0x3429
addq %rsi, %rbx
jmp 0x344e
movq %r8, %rax
shrq $0x9, %rax
movq %rax, %rdx
orq %r12, %rdx
testq %r8, %r8
cmovgq %rax, %rdx
movq %rdx, %rax
shlq $0x9, %rax
subq %rax, %r8
addq (%r15,%rdx,8), %r8
movq %r8, %rbx
movb (%r11), %al
decq %rcx
cmpb (%rbx), %al
jge 0x3360
jmp 0x2f32
movl $0x1, %ebx
leaq 0x80(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x347c
callq 0x2120
leaq 0x18(%rsp), %rdi
callq 0x28a2
movl %ebx, %eax
addq $0xa8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
xorl %ebx, %ebx
jmp 0x3486
jmp 0x34a4
jmp 0x34a4
jmp 0x34a4
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x2758
movq %rbx, %rdi
callq 0x2200
nop