// File: /workspace/github_c_makefile_star2_O2/msteveb[P]autosetup/./jimsh0.c
// Function: JimExprOpBin
static int JimExprOpBin(Jim_Interp *interp, struct JimExprNode *node)
{
    int rc = JIM_OK;
    double dA, dB, dC = 0;
    jim_wide wA, wB, wC = 0;
    Jim_Obj *A, *B;

    if ((rc = JimExprGetTerm(interp, node->left, &A)) != JIM_OK) {
        return rc;
    }
    if ((rc = JimExprGetTerm(interp, node->right, &B)) != JIM_OK) {
        Jim_DecrRefCount(interp, A);
        return rc;
    }

    if ((A->typePtr != &doubleObjType || A->bytes) &&
        (B->typePtr != &doubleObjType || B->bytes) &&
        JimGetWideNoErr(interp, A, &wA) == JIM_OK && JimGetWideNoErr(interp, B, &wB) == JIM_OK) {



        switch (node->type) {
            case JIM_EXPROP_POW:
            case JIM_EXPROP_FUNC_POW:
                if (wA == 0 && wB < 0) {
                    Jim_SetResultString(interp, "exponentiation of zero by negative power", -1);
                    rc = JIM_ERR;
                    goto done;
                }
                wC = JimPowWide(wA, wB);
                goto intresult;
            case JIM_EXPROP_ADD:
                wC = wA + wB;
                goto intresult;
            case JIM_EXPROP_SUB:
                wC = wA - wB;
                goto intresult;
            case JIM_EXPROP_MUL:
                wC = wA * wB;
                goto intresult;
            case JIM_EXPROP_DIV:
                if (wB == 0) {
                    Jim_SetResultString(interp, "Division by zero", -1);
                    rc = JIM_ERR;
                    goto done;
                }
                else {
                    if (wB < 0) {
                        wB = -wB;
                        wA = -wA;
                    }
                    wC = wA / wB;
                    if (wA % wB < 0) {
                        wC--;
                    }
                    goto intresult;
                }
            case JIM_EXPROP_LT:
                wC = wA < wB;
                goto intresult;
            case JIM_EXPROP_GT:
                wC = wA > wB;
                goto intresult;
            case JIM_EXPROP_LTE:
                wC = wA <= wB;
                goto intresult;
            case JIM_EXPROP_GTE:
                wC = wA >= wB;
                goto intresult;
            case JIM_EXPROP_NUMEQ:
                wC = wA == wB;
                goto intresult;
            case JIM_EXPROP_NUMNE:
                wC = wA != wB;
                goto intresult;
        }
    }
    if (Jim_GetDouble(interp, A, &dA) == JIM_OK && Jim_GetDouble(interp, B, &dB) == JIM_OK) {
        switch (node->type) {
#ifndef JIM_MATH_FUNCTIONS
            case JIM_EXPROP_POW:
            case JIM_EXPROP_FUNC_POW:
            case JIM_EXPROP_FUNC_ATAN2:
            case JIM_EXPROP_FUNC_HYPOT:
            case JIM_EXPROP_FUNC_FMOD:
                Jim_SetResultString(interp, "unsupported", -1);
                rc = JIM_ERR;
                goto done;
#else
            case JIM_EXPROP_POW:
            case JIM_EXPROP_FUNC_POW:
                dC = pow(dA, dB);
                goto doubleresult;
            case JIM_EXPROP_FUNC_ATAN2:
                dC = atan2(dA, dB);
                goto doubleresult;
            case JIM_EXPROP_FUNC_HYPOT:
                dC = hypot(dA, dB);
                goto doubleresult;
            case JIM_EXPROP_FUNC_FMOD:
                dC = fmod(dA, dB);
                goto doubleresult;
#endif
            case JIM_EXPROP_ADD:
                dC = dA + dB;
                goto doubleresult;
            case JIM_EXPROP_SUB:
                dC = dA - dB;
                goto doubleresult;
            case JIM_EXPROP_MUL:
                dC = dA * dB;
                goto doubleresult;
            case JIM_EXPROP_DIV:
                if (dB == 0) {
#ifdef INFINITY
                    dC = dA < 0 ? -INFINITY : INFINITY;
#else
                    dC = (dA < 0 ? -1.0 : 1.0) * strtod("Inf", NULL);
#endif
                }
                else {
                    dC = dA / dB;
                }
                goto doubleresult;
            case JIM_EXPROP_LT:
                wC = dA < dB;
                goto intresult;
            case JIM_EXPROP_GT:
                wC = dA > dB;
                goto intresult;
            case JIM_EXPROP_LTE:
                wC = dA <= dB;
                goto intresult;
            case JIM_EXPROP_GTE:
                wC = dA >= dB;
                goto intresult;
            case JIM_EXPROP_NUMEQ:
                wC = dA == dB;
                goto intresult;
            case JIM_EXPROP_NUMNE:
                wC = dA != dB;
                goto intresult;
        }
    }
    else {



        int i = Jim_StringCompareObj(interp, A, B, 0);

        switch (node->type) {
            case JIM_EXPROP_LT:
                wC = i < 0;
                goto intresult;
            case JIM_EXPROP_GT:
                wC = i > 0;
                goto intresult;
            case JIM_EXPROP_LTE:
                wC = i <= 0;
                goto intresult;
            case JIM_EXPROP_GTE:
                wC = i >= 0;
                goto intresult;
            case JIM_EXPROP_NUMEQ:
                wC = i == 0;
                goto intresult;
            case JIM_EXPROP_NUMNE:
                wC = i != 0;
                goto intresult;
        }
    }

    rc = JIM_ERR;
done:
    Jim_DecrRefCount(interp, A);
    Jim_DecrRefCount(interp, B);
    return rc;
intresult:
    Jim_SetResultInt(interp, wC);
    goto done;
doubleresult:
    Jim_SetResult(interp, Jim_NewDoubleObj(interp, dC));
    goto done;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rsi, %r13
movq %rdi, %rbx
movq 0x10(%rsi), %rsi
leaq -0x58(%rbp), %rdx
callq 0x1818d
movl %eax, %r12d
testl %eax, %eax
jne 0x17722
movq 0x18(%r13), %rsi
leaq -0x50(%rbp), %rdx
movq %rbx, %rdi
callq 0x1818d
movq -0x58(%rbp), %r15
testl %eax, %eax
je 0x17589
movl %eax, %r12d
movl 0x10(%r15), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0x10(%r15)
movq %r15, %r14
jmp 0x17712
leaq 0x19e50(%rip), %rax     # 0x313e0
cmpq %rax, 0x8(%r15)
jne 0x1759c
cmpq $0x0, (%r15)
je 0x17600
movq -0x50(%rbp), %r14
cmpq %rax, 0x8(%r14)
jne 0x175ac
cmpq $0x0, (%r14)
je 0x17604
leaq -0x38(%rbp), %rdx
movq %rbx, %rdi
movq %r15, %rsi
callq 0x1733a
testl %eax, %eax
jne 0x17604
leaq -0x30(%rbp), %rdx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1733a
testl %eax, %eax
jne 0x17604
movl (%r13), %ecx
leal -0x14(%rcx), %eax
cmpl $0x16, %eax
ja 0x17775
leaq 0xbc77(%rip), %rcx      # 0x23260
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq -0x30(%rbp), %rsi
imulq -0x38(%rbp), %rsi
jmp 0x176bf
movq -0x50(%rbp), %r14
leaq -0x48(%rbp), %rdx
movq %rbx, %rdi
movq %r15, %rsi
callq 0xd267
testl %eax, %eax
jne 0x1762a
leaq -0x40(%rbp), %rdx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xd267
testl %eax, %eax
je 0x1765e
movq %r15, %rsi
movq %r14, %rdx
xorl %ecx, %ecx
callq 0xaa82
movl %eax, %esi
movl (%r13), %eax
addl $-0x1d, %eax
cmpl $0x5, %eax
ja 0x17734
leaq 0xbc6c(%rip), %rcx      # 0x232bc
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
shrl $0x1f, %esi
jmp 0x176bf
movl (%r13), %eax
pushq $0x1
popq %r12
leal -0x14(%rax), %ecx
cmpl $0x16, %ecx
ja 0x1773a
leaq 0xbc5b(%rip), %rax      # 0x232d4
movslq (%rax,%rcx,4), %rcx
addq %rax, %rcx
jmpq *%rcx
movsd -0x48(%rbp), %xmm0
mulsd -0x40(%rbp), %xmm0
jmp 0x17975
xorl %eax, %eax
testl %esi, %esi
sete %al
jmp 0x176bc
xorl %eax, %eax
testl %esi, %esi
setle %al
jmp 0x176bc
xorl %eax, %eax
testl %esi, %esi
setns %al
jmp 0x176bc
xorl %eax, %eax
testl %esi, %esi
setg %al
jmp 0x176bc
xorl %eax, %eax
testl %esi, %esi
setne %al
movq %rax, %rsi
movq %rbx, %rdi
callq 0x8212
movq %rax, %r13
incl 0x10(%rax)
movq (%rbx), %rsi
movl 0x10(%rsi), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0x10(%rsi)
xorl %r12d, %r12d
cmpl $0x2, %eax
jge 0x176e9
movq %rbx, %rdi
callq 0x73bf
movq %r13, (%rbx)
movl 0x10(%r15), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0x10(%r15)
cmpl $0x1, %eax
jg 0x17707
movq %rbx, %rdi
movq %r15, %rsi
callq 0x73bf
movl 0x10(%r14), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0x10(%r14)
cmpl $0x2, %eax
jge 0x17722
movq %rbx, %rdi
movq %r14, %rsi
callq 0x73bf
movl %r12d, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
pushq $0x1
popq %r12
jmp 0x176ec
addl $-0x44, %eax
cmpl $0xc, %eax
ja 0x176ec
movl $0x1c01, %ecx           # imm = 0x1C01
btl %eax, %ecx
jae 0x176ec
leaq 0x107ff(%rip), %rsi     # 0x27f52
pushq $-0x1
popq %rdx
movq %rbx, %rdi
callq 0x7363
movq %rax, %r13
incl 0x10(%rax)
movq (%rbx), %rsi
movl 0x10(%rsi), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0x10(%rsi)
jmp 0x176dc
cmpl $0x4e, %ecx
jne 0x17604
movq -0x38(%rbp), %rax
testq %rax, %rax
sete %dl
movq -0x30(%rbp), %rcx
testq %rcx, %rcx
sets %sil
andb %dl, %sil
cmpb $0x1, %sil
jne 0x17938
leaq 0x10771(%rip), %rsi     # 0x27f18
jmp 0x17989
movsd -0x48(%rbp), %xmm0
addsd -0x40(%rbp), %xmm0
jmp 0x17975
movsd -0x40(%rbp), %xmm0
cmpeqsd -0x48(%rbp), %xmm0
jmp 0x17839
movsd -0x40(%rbp), %xmm0
xorl %esi, %esi
ucomisd -0x48(%rbp), %xmm0
jmp 0x17867
movsd -0x40(%rbp), %xmm0
xorl %esi, %esi
ucomisd -0x48(%rbp), %xmm0
jmp 0x17852
movsd -0x40(%rbp), %xmm1
xorpd %xmm2, %xmm2
ucomisd %xmm2, %xmm1
movsd -0x48(%rbp), %xmm0
jne 0x17971
jp 0x17971
xorl %eax, %eax
ucomisd %xmm0, %xmm2
seta %al
leaq 0xbf8b(%rip), %rcx      # 0x237a0
movsd (%rcx,%rax,8), %xmm0
jmp 0x17975
movsd -0x48(%rbp), %xmm0
subsd -0x40(%rbp), %xmm0
jmp 0x17975
movsd -0x40(%rbp), %xmm0
cmpneqsd -0x48(%rbp), %xmm0
movq %xmm0, %rsi
andl $0x1, %esi
jmp 0x176bf
movsd -0x48(%rbp), %xmm0
xorl %esi, %esi
ucomisd -0x40(%rbp), %xmm0
seta %sil
jmp 0x176bf
movsd -0x48(%rbp), %xmm0
xorl %esi, %esi
ucomisd -0x40(%rbp), %xmm0
setae %sil
jmp 0x176bf
movq -0x38(%rbp), %rax
xorl %esi, %esi
cmpq -0x30(%rbp), %rax
setg %sil
jmp 0x176bf
movq -0x38(%rbp), %rax
xorl %esi, %esi
cmpq -0x30(%rbp), %rax
setl %sil
jmp 0x176bf
movq -0x38(%rbp), %rsi
subq -0x30(%rbp), %rsi
jmp 0x176bf
movq -0x30(%rbp), %rcx
testq %rcx, %rcx
je 0x17982
movq -0x38(%rbp), %rdx
movq %rdx, %rax
negq %rax
movq %rcx, %rsi
negq %rsi
cmovsq %rcx, %rsi
testq %rcx, %rcx
cmovnsq %rdx, %rax
cqto
idivq %rsi
movq %rdx, %rsi
sarq $0x3f, %rsi
addq %rax, %rsi
jmp 0x176bf
movq -0x38(%rbp), %rax
xorl %esi, %esi
cmpq -0x30(%rbp), %rax
setle %sil
jmp 0x176bf
movq -0x30(%rbp), %rsi
addq -0x38(%rbp), %rsi
jmp 0x176bf
movq -0x38(%rbp), %rax
xorl %esi, %esi
cmpq -0x30(%rbp), %rax
setne %sil
jmp 0x176bf
movq -0x38(%rbp), %rax
xorl %esi, %esi
cmpq -0x30(%rbp), %rax
sete %sil
jmp 0x176bf
movq -0x38(%rbp), %rax
xorl %esi, %esi
cmpq -0x30(%rbp), %rax
setge %sil
jmp 0x176bf
cmpq $0x1, %rax
jne 0x17946
pushq $0x1
popq %rsi
jmp 0x176bf
testq %rcx, %rcx
js 0x179af
pushq $0x1
popq %rdx
movq %rdx, %rsi
testq %rcx, %rcx
je 0x176bf
testb $0x1, %cl
movq %rax, %rdi
cmoveq %rdx, %rdi
imulq %rdi, %rsi
shrq %rcx
imulq %rax, %rax
jmp 0x17951
divsd %xmm1, %xmm0
movq %rbx, %rdi
callq 0xd366
jmp 0x176c7
leaq 0x105b8(%rip), %rsi     # 0x27f41
pushq $-0x1
popq %rdx
movq %rbx, %rdi
callq 0x7363
movq %rax, %r13
incl 0x10(%rax)
movq (%rbx), %rsi
movl 0x10(%rsi), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0x10(%rsi)
pushq $0x1
popq %r12
jmp 0x176dc
cmpq $-0x1, %rax
je 0x179bc
xorl %esi, %esi
jmp 0x176bf
negq %rcx
jmp 0x1794b