// File: /workspace/github_cpp_makefile_star2_O3/acliusBackHome[P]kamaya/dist/ParseExpressionConstCalculate.cpp
// Function: ParseExpression::calculate_const_div(ConstValueType, ParseConstant const&, ParseConstant const&)
void ParseExpression::
calculate_const_div(ConstValueType cal_type,
                    const ParseConstant &const1, const ParseConstant &const2) {
    switch (cal_type) {
        case C_BOOL:
        case C_SIGNED: {
            auto divisor = const2.get_signed();
            if (divisor == 0) {
                string info = "ParseExpression::calculate_const() expr_id=" + to_string(get_id());
                throw ParseException(EX_EXPRESSION_DIVIDE_ZERO, info);
            }
            const_value = (size_t)
                    new ParseConstant(ParseConstant(const1.get_signed() / divisor));
            return;
        }
        case C_UNSIGNED: {
            auto divisor = const2.get_unsigned();
            if (divisor == 0) {
                string info = "ParseExpression::calculate_const() expr_id=" + to_string(get_id());
                throw ParseException(EX_EXPRESSION_DIVIDE_ZERO, info);
            }
            const_value = (size_t)
                    new ParseConstant(ParseConstant(const1.get_unsigned() / divisor));
            return;
        }
        case C_FLOAT: {
            auto divisor = const2.get_float();
            if (divisor == 0) {
                string info = "ParseExpression::calculate_const() expr_id=" + to_string(get_id());
                throw ParseException(EX_EXPRESSION_DIVIDE_ZERO, info);
            }
            const_value = (size_t)
                    new ParseConstant(ParseConstant(const1.get_float() / divisor));
            return;
        }
        case C_STRING:
        default:
            break;
    }
    const_value = (size_t) -1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rdi, %rbx
decl %esi
cmpl $0x3, %esi
ja 0x34319
movq %rdx, %r15
leaq 0x133dd(%rip), %rax     # 0x4762c
movslq (%rax,%rsi,4), %rdx
addq %rax, %rdx
jmpq *%rdx
movq %rcx, %rdi
callq 0x2efe0
testq %rax, %rax
je 0x34331
movq %rax, %r12
movl $0x10, %edi
callq 0x42e0
movq %rax, %r14
movq %r15, %rdi
callq 0x2efe0
cqto
idivq %r12
movq %r14, %rdi
movq %rax, %rsi
callq 0x2eed4
jmp 0x34320
movq %rcx, %rdi
callq 0x2f04c
testq %rax, %rax
je 0x343a6
movq %rax, %r12
movl $0x10, %edi
callq 0x42e0
movq %rax, %r14
movq %r15, %rdi
callq 0x2f04c
xorl %edx, %edx
divq %r12
movq %r14, %rdi
movq %rax, %rsi
callq 0x2eefe
jmp 0x34320
movq %rcx, %rdi
callq 0x2f0d2
fldz
fld %st(1)
fstpt -0x6c(%rbp)
fxch %st(1)
fucompi %st(1), %st
fstp %st(0)
jne 0x342ee
jnp 0x34418
movl $0x10, %edi
callq 0x42e0
movq %rax, %r14
movq %r15, %rdi
callq 0x2f0d2
fldt -0x6c(%rbp)
fdivrp %st, %st(1)
fstpt (%rsp)
movq %r14, %rdi
callq 0x2ef50
fldz
fstp %st(0)
jmp 0x34320
movq $-0x1, %r14
movq %r14, 0x18(%rbx)
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rbx, %rdi
callq 0x2c6c6
leaq -0x40(%rbp), %rbx
movq %rbx, %rdi
movq %rax, %rsi
callq 0xe50f
leaq 0x133c1(%rip), %rsi     # 0x47710
leaq -0x60(%rbp), %rdi
movq %rbx, %rdx
callq 0xe495
leaq -0x30(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x3436d
callq 0x42b0
movl $0x28, %edi
callq 0x4190
movq %rax, %r14
leaq -0x60(%rbp), %rdx
movq %rax, %rdi
movl $0xe, %esi
callq 0x333ee
leaq 0x269de(%rip), %rsi     # 0x5ad70
leaq -0x25df9(%rip), %rdx    # 0xe5a0
movq %r14, %rdi
callq 0x4540
jmp 0x34488
movq %rbx, %rdi
callq 0x2c6c6
leaq -0x40(%rbp), %rbx
movq %rbx, %rdi
movq %rax, %rsi
callq 0xe50f
leaq 0x1334c(%rip), %rsi     # 0x47710
leaq -0x60(%rbp), %rdi
movq %rbx, %rdx
callq 0xe495
leaq -0x30(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x343e2
callq 0x42b0
movl $0x28, %edi
callq 0x4190
movq %rax, %r14
leaq -0x60(%rbp), %rdx
movq %rax, %rdi
movl $0xe, %esi
callq 0x333ee
leaq 0x26969(%rip), %rsi     # 0x5ad70
leaq -0x25e6e(%rip), %rdx    # 0xe5a0
movq %r14, %rdi
callq 0x4540
jmp 0x34488
movq %rbx, %rdi
callq 0x2c6c6
leaq -0x40(%rbp), %rbx
movq %rbx, %rdi
movq %rax, %rsi
callq 0xe50f
leaq 0x132da(%rip), %rsi     # 0x47710
leaq -0x60(%rbp), %rdi
movq %rbx, %rdx
callq 0xe495
leaq -0x30(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x34454
callq 0x42b0
movl $0x28, %edi
callq 0x4190
movq %rax, %r14
leaq -0x60(%rbp), %rdx
movq %rax, %rdi
movl $0xe, %esi
callq 0x333ee
leaq 0x268f7(%rip), %rsi     # 0x5ad70
leaq -0x25ee0(%rip), %rdx    # 0xe5a0
movq %r14, %rdi
callq 0x4540
jmp 0x34490
jmp 0x34495
jmp 0x34490
jmp 0x34495
movq %rax, %rbx
jmp 0x344a0
movq %rax, %rbx
movq %r14, %rdi
callq 0x4250
leaq -0x50(%rbp), %rax
jmp 0x344b1
jmp 0x344aa
jmp 0x344aa
movq %rax, %rbx
leaq -0x30(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
jne 0x344c8
jmp 0x344cd
fstp %st(0)
jmp 0x344c2
jmp 0x344c2
movq %rax, %rbx
movq %r14, %rdi
callq 0x42b0
movq %rbx, %rdi
callq 0x4560
nop