// File: /workspace/github_cpp_makefile_star2_O3/Ciaxur[P]yagb-emu/include/imgui/imgui_widgets.cpp
// Function: ImGui::PlotEx(ImGuiPlotType, char const*, float (*)(void*, int), void*, int, int, char const*, float, float, ImVec2)
int ImGui::PlotEx(ImGuiPlotType plot_type, const char* label, float (*values_getter)(void* data, int idx), void* data, int values_count, int values_offset, const char* overlay_text, float scale_min, float scale_max, ImVec2 frame_size)
{
    ImGuiContext& g = *GImGui;
    ImGuiWindow* window = GetCurrentWindow();
    if (window->SkipItems)
        return -1;

    const ImGuiStyle& style = g.Style;
    const ImGuiID id = window->GetID(label);

    const ImVec2 label_size = CalcTextSize(label, NULL, true);
    if (frame_size.x == 0.0f)
        frame_size.x = CalcItemWidth();
    if (frame_size.y == 0.0f)
        frame_size.y = label_size.y + (style.FramePadding.y * 2);

    const ImRect frame_bb(window->DC.CursorPos, window->DC.CursorPos + frame_size);
    const ImRect inner_bb(frame_bb.Min + style.FramePadding, frame_bb.Max - style.FramePadding);
    const ImRect total_bb(frame_bb.Min, frame_bb.Max + ImVec2(label_size.x > 0.0f ? style.ItemInnerSpacing.x + label_size.x : 0.0f, 0));
    ItemSize(total_bb, style.FramePadding.y);
    if (!ItemAdd(total_bb, 0, &frame_bb))
        return -1;
    const bool hovered = ItemHoverable(frame_bb, id);

    // Determine scale from values if not specified
    if (scale_min == FLT_MAX || scale_max == FLT_MAX)
    {
        float v_min = FLT_MAX;
        float v_max = -FLT_MAX;
        for (int i = 0; i < values_count; i++)
        {
            const float v = values_getter(data, i);
            if (v != v) // Ignore NaN values
                continue;
            v_min = ImMin(v_min, v);
            v_max = ImMax(v_max, v);
        }
        if (scale_min == FLT_MAX)
            scale_min = v_min;
        if (scale_max == FLT_MAX)
            scale_max = v_max;
    }

    RenderFrame(frame_bb.Min, frame_bb.Max, GetColorU32(ImGuiCol_FrameBg), true, style.FrameRounding);

    const int values_count_min = (plot_type == ImGuiPlotType_Lines) ? 2 : 1;
    int idx_hovered = -1;
    if (values_count >= values_count_min)
    {
        int res_w = ImMin((int)frame_size.x, values_count) + ((plot_type == ImGuiPlotType_Lines) ? -1 : 0);
        int item_count = values_count + ((plot_type == ImGuiPlotType_Lines) ? -1 : 0);

        // Tooltip on hover
        if (hovered && inner_bb.Contains(g.IO.MousePos))
        {
            const float t = ImClamp((g.IO.MousePos.x - inner_bb.Min.x) / (inner_bb.Max.x - inner_bb.Min.x), 0.0f, 0.9999f);
            const int v_idx = (int)(t * item_count);
            IM_ASSERT(v_idx >= 0 && v_idx < values_count);

            const float v0 = values_getter(data, (v_idx + values_offset) % values_count);
            const float v1 = values_getter(data, (v_idx + 1 + values_offset) % values_count);
            if (plot_type == ImGuiPlotType_Lines)
                SetTooltip("%d: %8.4g\n%d: %8.4g", v_idx, v0, v_idx + 1, v1);
            else if (plot_type == ImGuiPlotType_Histogram)
                SetTooltip("%d: %8.4g", v_idx, v0);
            idx_hovered = v_idx;
        }

        const float t_step = 1.0f / (float)res_w;
        const float inv_scale = (scale_min == scale_max) ? 0.0f : (1.0f / (scale_max - scale_min));

        float v0 = values_getter(data, (0 + values_offset) % values_count);
        float t0 = 0.0f;
        ImVec2 tp0 = ImVec2( t0, 1.0f - ImSaturate((v0 - scale_min) * inv_scale) );                       // Point in the normalized space of our target rectangle
        float histogram_zero_line_t = (scale_min * scale_max < 0.0f) ? (-scale_min * inv_scale) : (scale_min < 0.0f ? 0.0f : 1.0f);   // Where does the zero line stands

        const ImU32 col_base = GetColorU32((plot_type == ImGuiPlotType_Lines) ? ImGuiCol_PlotLines : ImGuiCol_PlotHistogram);
        const ImU32 col_hovered = GetColorU32((plot_type == ImGuiPlotType_Lines) ? ImGuiCol_PlotLinesHovered : ImGuiCol_PlotHistogramHovered);

        for (int n = 0; n < res_w; n++)
        {
            const float t1 = t0 + t_step;
            const int v1_idx = (int)(t0 * item_count + 0.5f);
            IM_ASSERT(v1_idx >= 0 && v1_idx < values_count);
            const float v1 = values_getter(data, (v1_idx + values_offset + 1) % values_count);
            const ImVec2 tp1 = ImVec2( t1, 1.0f - ImSaturate((v1 - scale_min) * inv_scale) );

            // NB: Draw calls are merged together by the DrawList system. Still, we should render our batch are lower level to save a bit of CPU.
            ImVec2 pos0 = ImLerp(inner_bb.Min, inner_bb.Max, tp0);
            ImVec2 pos1 = ImLerp(inner_bb.Min, inner_bb.Max, (plot_type == ImGuiPlotType_Lines) ? tp1 : ImVec2(tp1.x, histogram_zero_line_t));
            if (plot_type == ImGuiPlotType_Lines)
            {
                window->DrawList->AddLine(pos0, pos1, idx_hovered == v1_idx ? col_hovered : col_base);
            }
            else if (plot_type == ImGuiPlotType_Histogram)
            {
                if (pos1.x >= pos0.x + 2.0f)
                    pos1.x -= 1.0f;
                window->DrawList->AddRectFilled(pos0, pos1, idx_hovered == v1_idx ? col_hovered : col_base);
            }

            t0 = t1;
            tp0 = tp1;
        }
    }

    // Text overlay
    if (overlay_text)
        RenderTextClipped(ImVec2(frame_bb.Min.x, frame_bb.Min.y + style.FramePadding.y), frame_bb.Max, overlay_text, NULL, NULL, ImVec2(0.5f, 0.0f));

    if (label_size.x > 0.0f)
        RenderText(ImVec2(frame_bb.Max.x + style.ItemInnerSpacing.x, inner_bb.Min.y), label);

    // Return hovered index or -1 if none are hovered.
    // This is currently not exposed in the public API because we need a larger redesign of the whole thing, but in the short-term we are making it available in PlotEx().
    return idx_hovered;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x138, %rsp            # imm = 0x138
movq %r9, -0x48(%rbp)
movq %rcx, -0x60(%rbp)
movq %rdx, -0x58(%rbp)
leaq 0x59e90(%rip), %rax     # 0xfbcd0
movq (%rax), %rax
movq 0x1ae0(%rax), %r14
movb $0x1, 0x90(%r14)
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
cmpb $0x0, 0x93(%r14)
jne 0xa25a0
movl %r8d, %r15d
movq %rsi, %r13
movaps %xmm1, -0xa0(%rbp)
movaps %xmm0, -0xb0(%rbp)
movl %edi, -0x30(%rbp)
movq %rax, -0x50(%rbp)
movq %r14, %rdi
xorl %edx, %edx
movaps %xmm2, -0x100(%rbp)
callq 0x4570a
movl %eax, %r12d
movss 0x13134(%rip), %xmm0    # 0xb4fd0
movq %r13, %rdi
xorl %esi, %esi
movl $0x1, %edx
callq 0x44a23
movaps -0x100(%rbp), %xmm3
movaps %xmm0, %xmm1
xorps %xmm0, %xmm0
ucomiss %xmm0, %xmm3
movaps %xmm1, -0x130(%rbp)
jne 0xa1ee0
jp 0xa1ee0
callq 0x5614d
movaps -0x100(%rbp), %xmm3
movaps -0x130(%rbp), %xmm1
movss %xmm0, %xmm3            # xmm3 = xmm0[0],xmm3[1,2,3]
xorps %xmm0, %xmm0
movaps %xmm3, %xmm2
shufps $0x55, %xmm3, %xmm2     # xmm2 = xmm2[1,1],xmm3[1,1]
ucomiss %xmm0, %xmm2
movq -0x50(%rbp), %rax
movq %r13, -0x148(%rbp)
jne 0xa1f22
jp 0xa1f22
movaps %xmm1, %xmm0
shufps $0x55, %xmm1, %xmm0     # xmm0 = xmm0[1,1],xmm1[1,1]
movss 0x159c(%rax), %xmm4
movaps %xmm4, %xmm2
addss %xmm4, %xmm2
addss %xmm0, %xmm2
movaps %xmm2, %xmm0
movlhps %xmm3, %xmm0            # xmm0 = xmm0[0],xmm3[0]
shufps $0xe2, %xmm3, %xmm0     # xmm0 = xmm0[2,0],xmm3[2,3]
movaps %xmm0, %xmm3
jmp 0xa1f2a
movss 0x159c(%rax), %xmm4
movss 0xd8(%r14), %xmm0
movaps %xmm3, -0x100(%rbp)
addss %xmm3, %xmm0
addss 0xdc(%r14), %xmm2
movaps %xmm0, -0x90(%rbp)
unpcklps %xmm2, %xmm0            # xmm0 = xmm0[0],xmm2[0],xmm0[1],xmm2[1]
movq 0xd8(%r14), %r13
movq %r13, -0xc8(%rbp)
movlps %xmm0, -0xc0(%rbp)
xorps %xmm0, %xmm0
ucomiss %xmm0, %xmm1
xorps %xmm1, %xmm1
jbe 0xa1f81
movss 0x15b0(%rax), %xmm1
addss -0x130(%rbp), %xmm1
movss 0x1598(%rax), %xmm3
movss %xmm3, -0x2c(%rbp)
addss -0x90(%rbp), %xmm1
movaps %xmm2, -0x110(%rbp)
addss %xmm2, %xmm0
unpcklps %xmm0, %xmm1            # xmm1 = xmm1[0],xmm0[0],xmm1[1],xmm0[1]
leaq -0x158(%rbp), %rbx
movq %r13, (%rbx)
movlps %xmm1, 0x8(%rbx)
movq %rbx, %rdi
movss %xmm4, -0xe0(%rbp)
movaps %xmm4, %xmm0
callq 0x559be
leaq -0xc8(%rbp), %rdx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x524a8
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
testb %al, %al
je 0xa25a0
movq %r13, %rax
shrq $0x20, %rax
movd %eax, %xmm0
movdqa %xmm0, -0xf0(%rbp)
leaq -0xc8(%rbp), %rdi
movl %r12d, %esi
callq 0x4632f
movaps -0xb0(%rbp), %xmm0
ucomiss 0x1382d(%rip), %xmm0    # 0xb5840
movaps -0xa0(%rbp), %xmm0
movb %al, -0x140(%rbp)
jne 0xa2024
jnp 0xa2038
ucomiss 0x13815(%rip), %xmm0    # 0xb5840
jne 0xa202f
jnp 0xa2038
movl -0x30(%rbp), %r12d
jmp 0xa20ef
movss 0x13800(%rip), %xmm0    # 0xb5840
testl %r15d, %r15d
movl -0x30(%rbp), %r12d
jle 0xa20a1
xorl %ebx, %ebx
movss 0x13855(%rip), %xmm3    # 0xb58a8
movss 0x137e5(%rip), %xmm4    # 0xb5840
movaps %xmm4, -0x40(%rbp)
movaps %xmm3, -0x80(%rbp)
movq -0x60(%rbp), %rdi
movl %ebx, %esi
callq *-0x58(%rbp)
ucomiss %xmm0, %xmm0
jp 0xa2097
movaps -0x40(%rbp), %xmm4
minss %xmm0, %xmm4
movaps %xmm0, %xmm1
movaps -0x80(%rbp), %xmm3
cmpless %xmm3, %xmm1
andps %xmm1, %xmm3
andnps %xmm0, %xmm1
orps %xmm1, %xmm3
incl %ebx
cmpl %ebx, %r15d
jne 0xa205b
jmp 0xa20ac
movaps -0x80(%rbp), %xmm3
movaps -0x40(%rbp), %xmm4
jmp 0xa208e
movss 0x137ff(%rip), %xmm3    # 0xb58a8
movaps %xmm0, %xmm4
movaps -0xb0(%rbp), %xmm1
movaps %xmm1, %xmm0
movss 0x13782(%rip), %xmm2    # 0xb5840
cmpeqss %xmm2, %xmm0
andps %xmm0, %xmm4
andnps %xmm1, %xmm0
orps %xmm4, %xmm0
movaps -0xa0(%rbp), %xmm1
cmpeqss %xmm1, %xmm2
andps %xmm2, %xmm3
andnps %xmm1, %xmm2
orps %xmm3, %xmm2
movaps %xmm2, -0xa0(%rbp)
movaps %xmm0, -0xb0(%rbp)
movaps -0xf0(%rbp), %xmm0
addss -0xe0(%rbp), %xmm0
movaps %xmm0, -0xf0(%rbp)
movsd -0xc8(%rbp), %xmm0
movaps %xmm0, -0x80(%rbp)
movsd -0xc0(%rbp), %xmm0
movaps %xmm0, -0x40(%rbp)
movss 0x12ebf(%rip), %xmm0    # 0xb4fe4
movl $0x7, %edi
callq 0x43bca
movq -0x50(%rbp), %rcx
movss 0x15a0(%rcx), %xmm2
movaps -0x80(%rbp), %xmm0
movaps -0x40(%rbp), %xmm1
movl %eax, %edi
movl $0x1, %esi
callq 0x44f69
xorl %eax, %eax
cmpl $0x1, %r12d
adcl $0x1, %eax
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
cmpl %r15d, %eax
jg 0xa2510
movd %r13d, %xmm1
movss -0x2c(%rbp), %xmm2
addss %xmm2, %xmm1
movaps -0x90(%rbp), %xmm0
subss %xmm2, %xmm0
movaps %xmm0, -0x90(%rbp)
movaps -0x110(%rbp), %xmm2
subss -0xe0(%rbp), %xmm2
movl %r12d, %eax
xorl %r12d, %r12d
testl %eax, %eax
cvttss2si -0x100(%rbp), %r13d
sete %r12b
cmpl %r15d, %r13d
cmovgel %r15d, %r13d
movl %r15d, %eax
subl %r12d, %eax
movl %eax, -0x80(%rbp)
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
cmpb $0x0, -0x140(%rbp)
movss %xmm1, -0x2c(%rbp)
movaps %xmm2, -0x110(%rbp)
je 0xa21e9
movq -0x50(%rbp), %rax
movss 0x128(%rax), %xmm0
ucomiss %xmm1, %xmm0
jae 0xa25b4
subl %r12d, %r13d
movaps -0xa0(%rbp), %xmm2
movaps %xmm2, %xmm0
movaps -0xb0(%rbp), %xmm3
subss %xmm3, %xmm0
movss 0x12ddb(%rip), %xmm1    # 0xb4fe4
divss %xmm0, %xmm1
cmpeqss %xmm2, %xmm3
andnps %xmm1, %xmm3
movaps %xmm3, -0xe0(%rbp)
movq -0x48(%rbp), %rax
cltd
idivl %r15d
movq -0x60(%rbp), %rdi
movl %edx, %esi
callq *-0x58(%rbp)
movaps -0xe0(%rbp), %xmm4
movaps -0xb0(%rbp), %xmm3
xorps %xmm2, %xmm2
movaps -0xa0(%rbp), %xmm1
mulss %xmm3, %xmm1
ucomiss %xmm1, %xmm2
movss %xmm0, -0x40(%rbp)
jbe 0xa2263
movaps 0x12d66(%rip), %xmm1    # 0xb4fc0
xorps %xmm3, %xmm1
mulss %xmm4, %xmm1
jmp 0xa2276
movaps %xmm3, %xmm1
cmpltss %xmm2, %xmm1
movss 0x12d71(%rip), %xmm0    # 0xb4fe4
andnps %xmm0, %xmm1
movaps %xmm1, -0x120(%rbp)
xorl %r12d, %r12d
cmpl $0x0, -0x30(%rbp)
setne %r12b
leal 0x26(,%r12,2), %edi
movss 0x12d4c(%rip), %xmm0    # 0xb4fe4
callq 0x43bca
movl %eax, -0x70(%rbp)
leal 0x27(,%r12,2), %edi
movss 0x12d34(%rip), %xmm0    # 0xb4fe4
callq 0x43bca
movl %eax, -0x6c(%rbp)
testl %r13d, %r13d
jle 0xa2510
movss -0x40(%rbp), %xmm0
subss -0xb0(%rbp), %xmm0
movaps -0xe0(%rbp), %xmm7
mulss %xmm0, %xmm7
movss 0x12d03(%rip), %xmm2    # 0xb4fe4
movaps %xmm2, %xmm0
minss %xmm7, %xmm0
movaps %xmm2, %xmm1
subss %xmm0, %xmm1
cmpltss 0x1354c(%rip), %xmm7    # 0xb5844
movaps %xmm7, %xmm0
andnps %xmm1, %xmm0
andps %xmm2, %xmm7
xorps %xmm1, %xmm1
cvtsi2ss %r13d, %xmm1
orps %xmm0, %xmm7
xorps %xmm0, %xmm0
cvtsi2ssl -0x80(%rbp), %xmm0
movss %xmm0, -0xa0(%rbp)
divss %xmm1, %xmm2
movaps %xmm2, -0x140(%rbp)
movq -0x48(%rbp), %rax
incl %eax
movq %rax, -0x48(%rbp)
movaps -0x90(%rbp), %xmm0
subss -0x2c(%rbp), %xmm0
movaps %xmm0, -0x90(%rbp)
movaps -0x110(%rbp), %xmm2
movaps -0xf0(%rbp), %xmm0
subss %xmm0, %xmm2
movaps -0x120(%rbp), %xmm1
mulss %xmm2, %xmm1
addss %xmm0, %xmm1
movaps %xmm1, -0x120(%rbp)
xorps %xmm0, %xmm0
movaps %xmm2, -0x110(%rbp)
movaps %xmm7, -0x40(%rbp)
movaps %xmm0, %xmm1
mulss -0xa0(%rbp), %xmm0
addss 0x12c77(%rip), %xmm0    # 0xb5004
cvttss2si %xmm0, %r12d
testl %r12d, %r12d
js 0xa26b7
cmpl %r15d, %r12d
jge 0xa26b7
movaps -0x140(%rbp), %xmm0
addss %xmm1, %xmm0
movaps %xmm0, -0x80(%rbp)
movq -0x48(%rbp), %rax
addl %r12d, %eax
cltd
idivl %r15d
movq -0x60(%rbp), %rdi
movl %edx, %esi
movaps %xmm1, -0x100(%rbp)
callq *-0x58(%rbp)
movaps -0x100(%rbp), %xmm8
movaps %xmm0, %xmm7
subss -0xb0(%rbp), %xmm7
mulss -0xe0(%rbp), %xmm7
movss 0x12bf3(%rip), %xmm0    # 0xb4fe4
movaps %xmm0, %xmm2
minss %xmm7, %xmm2
movaps %xmm0, %xmm1
subss %xmm2, %xmm1
cmpltss 0x1343c(%rip), %xmm7    # 0xb5844
movaps %xmm7, %xmm2
andnps %xmm1, %xmm2
andps %xmm0, %xmm7
orps %xmm2, %xmm7
movaps -0x90(%rbp), %xmm1
mulss %xmm1, %xmm8
movss -0x2c(%rbp), %xmm4
addss %xmm4, %xmm8
movaps -0x110(%rbp), %xmm2
movaps -0x40(%rbp), %xmm6
mulss %xmm2, %xmm6
movaps -0xf0(%rbp), %xmm3
addss %xmm3, %xmm6
movaps %xmm8, %xmm5
unpcklps %xmm6, %xmm5            # xmm5 = xmm5[0],xmm6[0],xmm5[1],xmm6[1]
movlps %xmm5, -0xb8(%rbp)
movaps %xmm1, %xmm5
mulss -0x80(%rbp), %xmm5
addss %xmm4, %xmm5
movl -0x30(%rbp), %eax
testl %eax, %eax
je 0xa24c8
movaps %xmm5, %xmm1
unpcklps -0x120(%rbp), %xmm1     # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1]
movlps %xmm1, -0x68(%rbp)
cmpl $0x1, %eax
jne 0xa2503
movaps %xmm7, -0x40(%rbp)
addss 0x133df(%rip), %xmm8    # 0xb5868
ucomiss %xmm8, %xmm5
jb 0xa249c
addss 0x12b39(%rip), %xmm5    # 0xb4fd0
movss %xmm5, -0x68(%rbp)
movq 0x2b8(%r14), %rdi
cmpl %r12d, %ebx
movl -0x70(%rbp), %ecx
cmovel -0x6c(%rbp), %ecx
xorps %xmm0, %xmm0
leaq -0xb8(%rbp), %rsi
leaq -0x68(%rbp), %rdx
movl $0xf, %r8d
callq 0x785e6
jmp 0xa24ff
movaps %xmm2, %xmm1
mulss %xmm7, %xmm1
addss %xmm3, %xmm1
unpcklps %xmm1, %xmm5            # xmm5 = xmm5[0],xmm1[0],xmm5[1],xmm1[1]
movlps %xmm5, -0x68(%rbp)
movq 0x2b8(%r14), %rdi
cmpl %r12d, %ebx
movl -0x70(%rbp), %ecx
cmovel -0x6c(%rbp), %ecx
leaq -0xb8(%rbp), %rsi
leaq -0x68(%rbp), %rdx
movaps %xmm7, -0x40(%rbp)
callq 0x78368
movaps -0x40(%rbp), %xmm7
decl %r13d
movaps -0x80(%rbp), %xmm0
jne 0xa2376
movq 0x10(%rbp), %rdx
testq %rdx, %rdx
je 0xa2563
leaq -0xc0(%rbp), %rsi
movss -0x8(%rsi), %xmm0
movss -0x4(%rsi), %xmm1
movq -0x50(%rbp), %rax
addss 0x159c(%rax), %xmm1
leaq -0xb8(%rbp), %rdi
movss %xmm0, (%rdi)
movss %xmm1, 0x4(%rdi)
leaq -0x68(%rbp), %r9
movq $0x3f000000, (%r9)      # imm = 0x3F000000
movq $0x0, (%rsp)
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x44ac2
xorps %xmm0, %xmm0
movaps -0x130(%rbp), %xmm1
ucomiss %xmm0, %xmm1
movq -0x148(%rbp), %rdi
jbe 0xa25a0
movss -0xc0(%rbp), %xmm0
movq -0x50(%rbp), %rax
addss 0x15b0(%rax), %xmm0
unpcklps -0xf0(%rbp), %xmm0      # xmm0 = xmm0[0],mem[0],xmm0[1],mem[1]
xorl %esi, %esi
movl $0x1, %edx
callq 0x44476
movl %ebx, %eax
addq $0x138, %rsp            # imm = 0x138
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movss 0x12c(%rax), %xmm1
ucomiss -0xf0(%rbp), %xmm1
jb 0xa21e9
movaps -0x90(%rbp), %xmm3
ucomiss %xmm0, %xmm3
jbe 0xa21e9
ucomiss %xmm1, %xmm2
jbe 0xa21e9
movss -0x2c(%rbp), %xmm2
subss %xmm2, %xmm0
movaps -0x90(%rbp), %xmm1
subss %xmm2, %xmm1
divss %xmm1, %xmm0
movss 0x2e7c2(%rip), %xmm1    # 0xd0dc4
minss %xmm0, %xmm1
xorps %xmm2, %xmm2
cmpltss %xmm2, %xmm0
andnps %xmm1, %xmm0
xorps %xmm1, %xmm1
cvtsi2ssl -0x80(%rbp), %xmm1
mulss %xmm0, %xmm1
cvttss2si %xmm1, %ebx
testl %ebx, %ebx
js 0xa26d6
cmpl %r15d, %ebx
jge 0xa26d6
movq -0x48(%rbp), %rax
addl %ebx, %eax
cltd
idivl %r15d
movq -0x60(%rbp), %rdi
movl %edx, %esi
callq *-0x58(%rbp)
movss %xmm0, -0x40(%rbp)
movq -0x48(%rbp), %rax
addl %ebx, %eax
incl %eax
cltd
idivl %r15d
movq -0x60(%rbp), %rdi
movl %edx, %esi
callq *-0x58(%rbp)
movl -0x30(%rbp), %eax
testl %eax, %eax
je 0xa268d
movss -0x40(%rbp), %xmm0
cmpl $0x1, %eax
jne 0xa21e9
cvtss2sd %xmm0, %xmm0
leaq 0x302fc(%rip), %rdi     # 0xd297b
movl %ebx, %esi
movb $0x1, %al
callq 0x50d5f
jmp 0xa21e9
leal 0x1(%rbx), %edx
xorps %xmm2, %xmm2
cvtss2sd -0x40(%rbp), %xmm2
xorps %xmm1, %xmm1
cvtss2sd %xmm0, %xmm1
leaq 0x302cb(%rip), %rdi     # 0xd2971
movl %ebx, %esi
movaps %xmm2, %xmm0
movb $0x2, %al
callq 0x50d5f
jmp 0xa21e9
leaq 0x302c7(%rip), %rdi     # 0xd2985
leaq 0x2e953(%rip), %rsi     # 0xd1018
leaq 0x30228(%rip), %rcx     # 0xd28f4
movl $0x18c1, %edx           # imm = 0x18C1
callq 0xc140
leaq 0x301f4(%rip), %rdi     # 0xd28d1
leaq 0x2e934(%rip), %rsi     # 0xd1018
leaq 0x30209(%rip), %rcx     # 0xd28f4
movl $0x18a7, %edx           # imm = 0x18A7
callq 0xc140