// File: /workspace/github_cpp_makefile_star2_O1/intheswim[P]FractalTubes/m3d.cpp
// Function: M3DDrawer::ShowInPreviewWindow(ShapeParams*, DrawParams*, pointData**, corePointData**)
bool M3DDrawer::ShowInPreviewWindow (struct ShapeParams *sp, struct DrawParams *dp,
                                     struct pointData ** pointData,
                                     struct corePointData ** corePoints)
{
	double x_real, y_real, z_real;
	unsigned long raw_color = 0;
	int mandel = 0, fraction = 0;
	double l = sp->l, r = sp->r;
	long col = 0;
	double y_median = sp->y_range / 2;
	int red, green, blue;
    
	float bright = 0, bright0 = 0; // brightness
	long double y1 = 0, alp = 0;
    
#ifdef USE_RUNTIME
	double tilt = set_tilt;
	double cos_tilt, sin_tilt;
#endif

    //	struct MiniMax minimax;
	double slope = atan (sp->y_range / (sp->alpha_range * sp->r));
	double x_norm, y_norm, z_norm;
    
	// trying to allocate space for 640*350=224000 pixels
	// space is neccesary to store z-cordinates
    
    double light_x = light_dir_x, light_y = light_dir_y, light_z = light_dir_z;
    
    double normalizer = sqrt (light_x * light_x + light_y * light_y + light_z * light_z);
	light_x /= normalizer;
	light_y /= normalizer;
	light_z /= normalizer;
    
#ifdef USE_RUNTIME
	  cos_tilt = cos (tilt);
	  sin_tilt = sin (tilt);
#endif
    
	SetMaterialType (moBoth) ; //Metal);    
    
	divisor = sqrt (800.0f * 600.0f / ((client_width) * (client_height)));
    
	sp->r /= divisor;
	sp->l /= divisor;
	sp->y_range /= divisor;
	y_median = y_median / divisor;
	l = sp->l, r = sp->r;
    
	SetGlobals (sp, dp);
        
	pix_count = 0;
    
    *pointData = new struct pointData [sp->total_points];
    
    long core_total = (sp->total_points/m_points_in_cycle);
    
    *corePoints = new struct corePointData [core_total];
    
    if (pointData == NULL || corePoints == NULL)
    {
        m_total_points = 0;
		    return (false);
    }
    
    memset(*corePoints, 0, sizeof(struct corePointData) * core_total);
        
    pix_count = 0;
    
    int core_cnt = 0;
    
    // initial y1 is 0;
    // r is
	while ((alp < sp->alpha_range) && (pix_count < sp->total_points))
    {
        long double alp2 = (((int)(pix_count / m_points_in_cycle)) * m_points_in_cycle) * sp->delta_alpha;
        
        long double beta = (pix_count % m_points_in_cycle) * (sp->delta_alpha * sp->coef);
        
        y1 = ((pix_count / m_points_in_cycle) * m_points_in_cycle) * sp->delta_y;
        
        GetPixelCoordinates (y1, r, l, alp2, beta, sp->coef, slope,
                             x_real, y_real, z_real,
                             x_norm, y_norm, z_norm);
        
        struct pointData *pd = &((*pointData)[pix_count]);
        
        if ((pix_count % m_points_in_cycle) == 0 /*half_cycle*/ && (core_cnt < core_total))
        {
            struct corePointData * cpd = &((*corePoints)[core_cnt]);
            
            alp2 = ((((pix_count / m_points_in_cycle) + 0.5f) * (double)m_points_in_cycle) + 0.5f) * sp->delta_alpha;
            
            //double extra = 0.5f / m_points_in_cycle;
            
            y1 = ((((pix_count / m_points_in_cycle) + 0.5f) * (double)m_points_in_cycle) + 0.5f) * sp->delta_y;
            
            double x_real2, y_real2, z_real2;
            double x_norm2, y_norm2, z_norm2;
            
            GetPixelCoordinates (y1, r, l, alp2, 0, sp->coef, slope,
                                 x_real2, y_real2, z_real2,
                                 x_norm2, y_norm2, z_norm2);

            
            cpd->x = (x_real2 - x_norm2 * l) / r;
            cpd->y = (y_real2 - y_norm2 * l) / r;
            cpd->z = (z_real2 - z_norm2 * l) / r;
            
            cpd->index = (int)pix_count;
            
            core_cnt++;
        }
        
        pd->x = x_real / (r);
        pd->y = y_real / (r);
        pd->z = z_real / (r);
        
        pd->normx = x_norm;
        pd->normy = y_norm;
        pd->normz = z_norm;        
                
        if (true)
        {            
            if (bright_k == 1)
            {
                bright0 = CalcBrightness (light_x, light_y, light_z, x_norm, y_norm, z_norm, 0, 0, 1);
            }
            else
            {
                bright0 = 50;
            }            
            
            // all following manipulations are to smooth the surface:
            // if actual brightness is too high, part of it goes as a bonus
            // to the next point
            
            bright += bright0;
            
            if (bright > 0)
            {
                col = (int)(bright + 0.5);
                
                if (col > 150)
                    col = 150;
                
                // SetPixel(hdc, xs, ys, color);
                if (dp->method == dmOnePoint)
                {
                    raw_color = GetMandelColor (*dp, *sp, alp, alp * sp->coef + alp * currentParams.skew, mandel, fraction);
                }
                else
                {
                    raw_color = GetMandelColor3 (*dp, *sp, alp, alp * sp->coef + alp * currentParams.skew, mandel, fraction);
                }
                
                GetColor (raw_color, col, red, green, blue);
                                
                if (raw_color != 0)
                {                    
                    pd->ucRed = red ;
                    pd->ucBlue = blue ;
                    pd->ucGreen = green ;
                }
                else
                {
                    pd->ucRed = 0;
                    pd->ucBlue = 0;
                    pd->ucGreen = 0;
                }
            }
            bright-=col;
        }
        
        y1 += sp->delta_y ;
        alp += sp->delta_alpha ;
        pix_count++;
    }
    
	pix_count = 0;

    return (true);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1e8, %rsp            # imm = 0x1E8
movq %r8, 0xd8(%rsp)
movq %rcx, 0xe0(%rsp)
movq %rdx, 0xa0(%rsp)
movq %rsi, %r13
movq %rdi, %r12
xorl %eax, %eax
movl %eax, 0x7c(%rsp)
movl %eax, 0x78(%rsp)
movsd 0x10(%rsi), %xmm0
movsd 0x18(%rsi), %xmm1
mulsd 0x40(%rsi), %xmm1
divsd %xmm1, %xmm0
callq 0x3290
movsd %xmm0, 0x88(%rsp)
movsd 0x10(%r12), %xmm1
movsd 0x18(%r12), %xmm0
movsd 0x20(%r12), %xmm2
movsd %xmm0, 0x38(%rsp)
mulsd %xmm0, %xmm0
movsd %xmm1, 0x50(%rsp)
mulsd %xmm1, %xmm1
addsd %xmm0, %xmm1
movsd %xmm2, 0x28(%rsp)
movapd %xmm2, %xmm0
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jb 0x682b
sqrtsd %xmm0, %xmm0
jmp 0x6830
callq 0x3240
movsd %xmm0, 0x40(%rsp)
callq 0x30e0
xorl %ecx, %ecx
testb $0x1, %al
sete %cl
movl $0x28, %eax
movl $0xa, %edx
cmovel %eax, %edx
movl $0x3, %eax
movl $0xd, %esi
cmovel %eax, %esi
shll $0x4, %ecx
addl $0x1e, %ecx
movl %edx, (%r12)
movl $0x46, 0x4(%r12)
movl %ecx, 0x8(%r12)
movl %esi, 0xc(%r12)
movss 0x30(%r12), %xmm1
mulss 0x34(%r12), %xmm1
movss 0x2b65(%rip), %xmm0     # 0x93f4
divss %xmm1, %xmm0
xorps %xmm1, %xmm1
ucomiss %xmm1, %xmm0
jb 0x68a1
sqrtss %xmm0, %xmm0
jmp 0x68a6
callq 0x35f0
movq 0xa0(%rsp), %rdx
movss %xmm0, 0x38(%r12)
cvtss2sd %xmm0, %xmm0
movsd 0x10(%r13), %xmm1
movsd 0x40(%r13), %xmm2
divsd %xmm0, %xmm2
movsd %xmm2, 0xa8(%rsp)
movsd %xmm2, 0x40(%r13)
movsd 0x48(%r13), %xmm2
divsd %xmm0, %xmm2
movsd %xmm2, 0xe8(%rsp)
movsd %xmm2, 0x48(%r13)
divsd %xmm0, %xmm1
movsd %xmm1, 0x10(%r13)
movq %r12, %rdi
movq %r13, %rsi
callq 0x71ce
xorl %r15d, %r15d
movq %r15, 0x40(%r12)
movq (%r13), %rbp
movl $0x38, %ecx
movq %rbp, %rax
mulq %rcx
movq $-0x1, %rbx
cmovoq %rbx, %rax
movq %rax, %rdi
callq 0x3030
movq 0xe0(%rsp), %rcx
movq %rax, (%rcx)
movslq 0x60(%r12), %rcx
movq %rbp, %rax
cqto
idivq %rcx
movq %rax, %r14
movl $0x28, %ecx
mulq %rcx
cmovnoq %rax, %rbx
movq %rbx, %rdi
callq 0x3030
movq 0xd8(%rsp), %rcx
movq %rax, (%rcx)
movq %r14, 0x130(%rsp)
leaq (,%r14,8), %rcx
leaq (%rcx,%rcx,4), %rdx
movq %rax, %rdi
xorl %esi, %esi
callq 0x3170
movq %r15, 0x40(%r12)
movsd 0x18(%r13), %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
fldz
jbe 0x71af
fstp %st(0)
movsd 0x28(%rsp), %xmm1
movsd 0x40(%rsp), %xmm0
divsd %xmm0, %xmm1
movsd 0x38(%rsp), %xmm2
divsd %xmm0, %xmm2
movsd 0x50(%rsp), %xmm3
divsd %xmm0, %xmm3
movsd 0xa8(%rsp), %xmm0
movsd %xmm0, 0x1e0(%rsp)
fldl 0x1e0(%rsp)
fstpt 0xbc(%rsp)
xorps %xmm0, %xmm0
cvtsd2ss %xmm3, %xmm0
movss %xmm0, 0xb8(%rsp)
xorps %xmm0, %xmm0
cvtsd2ss %xmm2, %xmm0
movss %xmm0, 0xb4(%rsp)
xorps %xmm0, %xmm0
cvtsd2ss %xmm1, %xmm0
movss %xmm0, 0xb0(%rsp)
fldz
xorl %ebx, %ebx
xorps %xmm1, %xmm1
xorl %eax, %eax
cmpq (%r13), %rax
jge 0x71af
fstpt 0x50(%rsp)
movss %xmm1, 0x38(%rsp)
movslq 0x60(%r12), %rcx
cqto
idivq %rcx
movl %eax, %esi
imull %ecx, %esi
movl %esi, 0xc8(%rsp)
fldt 0x30(%r13)
fld %st(0)
fimull 0xc8(%rsp)
fld %st(0)
fstpt 0x28(%rsp)
movq %rdx, 0x1d0(%rsp)
fildll 0x1d0(%rsp)
fldt 0x50(%r13)
fmulp %st, %st(3)
fmulp %st, %st(2)
fxch %st(1)
fstpt 0x40(%rsp)
imulq %rcx, %rax
movq %rax, 0x1d8(%rsp)
fildll 0x1d8(%rsp)
fldt 0x20(%r13)
fmulp %st, %st(1)
fstpl 0x1c8(%rsp)
fstpt (%rsp)
callq 0x33a0
fldt 0xbc(%rsp)
fmulp %st, %st(1)
fstpl 0x1c0(%rsp)
fldt 0x28(%rsp)
fstpt (%rsp)
callq 0x3510
fldt 0xbc(%rsp)
fmulp %st, %st(1)
fstpl 0x1b8(%rsp)
fldt 0x40(%rsp)
fstpt (%rsp)
callq 0x33a0
fstpl 0x1b0(%rsp)
movsd 0x1b0(%rsp), %xmm0
movsd %xmm0, 0x60(%rsp)
fldt 0x40(%rsp)
fstpt (%rsp)
callq 0x3510
fstpl 0x1a0(%rsp)
movsd 0x1a0(%rsp), %xmm0
movaps %xmm0, 0x40(%rsp)
xorps 0x29c6(%rip), %xmm0     # 0x94e0
movaps %xmm0, 0xf0(%rsp)
movsd 0x88(%rsp), %xmm0
callq 0x3080
mulsd 0xf0(%rsp), %xmm0
movsd %xmm0, 0x80(%rsp)
movsd 0x88(%rsp), %xmm0
callq 0x3610
mulsd 0x40(%rsp), %xmm0
movsd %xmm0, 0xf0(%rsp)
movsd 0x60(%rsp), %xmm0
movsd %xmm0, 0x1a8(%rsp)
fldl 0x1a8(%rsp)
fstpt 0x40(%rsp)
fldt 0x28(%rsp)
fstpt (%rsp)
callq 0x33a0
fstpt 0x90(%rsp)
movsd 0x80(%rsp), %xmm0
movsd %xmm0, 0x198(%rsp)
fldl 0x198(%rsp)
fstpt 0x60(%rsp)
fldt 0x28(%rsp)
fstpt (%rsp)
callq 0x3510
fldt 0x60(%rsp)
fmulp %st, %st(1)
fldt 0x40(%rsp)
fldt 0x90(%rsp)
fmulp %st, %st(1)
fsubp %st, %st(1)
fstpl 0x190(%rsp)
movsd 0x190(%rsp), %xmm0
movsd %xmm0, 0x80(%rsp)
fldt 0x28(%rsp)
fstpt (%rsp)
callq 0x3510
fstpt 0x90(%rsp)
fldt 0x28(%rsp)
fstpt (%rsp)
callq 0x33a0
movsd 0x80(%rsp), %xmm3
movsd 0xf0(%rsp), %xmm2
fldt 0x60(%rsp)
fmulp %st, %st(1)
fldt 0x40(%rsp)
fldt 0x90(%rsp)
fmulp %st, %st(1)
faddp %st, %st(1)
fstpl 0x188(%rsp)
movsd 0x188(%rsp), %xmm5
movapd %xmm3, %xmm4
movsd 0xe8(%rsp), %xmm0
mulsd %xmm0, %xmm4
addsd 0x1c0(%rsp), %xmm4
movapd %xmm2, %xmm6
mulsd %xmm0, %xmm6
addsd 0x1c8(%rsp), %xmm6
movapd %xmm5, %xmm7
mulsd %xmm0, %xmm7
addsd 0x1b8(%rsp), %xmm7
movq 0x40(%r12), %rax
imulq $0x38, %rax, %rbp
movq 0xe0(%rsp), %rcx
addq (%rcx), %rbp
movslq 0x60(%r12), %rcx
cqto
idivq %rcx
testq %rdx, %rdx
je 0x6ca7
movss 0x38(%rsp), %xmm1
fldt 0x50(%rsp)
jmp 0x6fa3
movslq %r15d, %r14
cmpq %r14, 0x130(%rsp)
movss 0x38(%rsp), %xmm1
fldt 0x50(%rsp)
jle 0x6fa3
fstp %st(0)
movq 0xd8(%rsp), %rdx
movq (%rdx), %r15
movq %rbx, 0x90(%rsp)
leaq (%r14,%r14,4), %rbx
xorps %xmm0, %xmm0
cvtsi2ss %rax, %xmm0
addss 0x2625(%rip), %xmm0     # 0x9310
cvtss2sd %xmm0, %xmm0
xorps %xmm1, %xmm1
cvtsi2sd %ecx, %xmm1
mulsd %xmm0, %xmm1
addsd 0x2556(%rip), %xmm1     # 0x9258
movsd %xmm1, 0x180(%rsp)
fldl 0x180(%rsp)
fldt 0x30(%r13)
fmul %st(1), %st
fld %st(0)
fstpt 0x28(%rsp)
fldt 0x20(%r13)
fmulp %st, %st(2)
fxch %st(1)
fstpl 0x178(%rsp)
fstpt (%rsp)
movsd %xmm5, 0x128(%rsp)
movsd %xmm4, 0x120(%rsp)
movsd %xmm6, 0x118(%rsp)
movsd %xmm7, 0x110(%rsp)
callq 0x33a0
fldt 0xbc(%rsp)
fmulp %st, %st(1)
fstpl 0x170(%rsp)
fldt 0x28(%rsp)
fstpt (%rsp)
callq 0x3510
fldt 0xbc(%rsp)
fmulp %st, %st(1)
fstpl 0x168(%rsp)
fldz
fstpt (%rsp)
callq 0x33a0
fstpl 0x160(%rsp)
movsd 0x160(%rsp), %xmm0
movsd %xmm0, 0x40(%rsp)
fldz
fstpt (%rsp)
callq 0x3510
fstpl 0x150(%rsp)
movsd 0x150(%rsp), %xmm0
movaps %xmm0, 0x100(%rsp)
xorps 0x2712(%rip), %xmm0     # 0x94e0
movaps %xmm0, 0x60(%rsp)
movsd 0x88(%rsp), %xmm0
callq 0x3080
mulsd 0x60(%rsp), %xmm0
movsd %xmm0, 0x60(%rsp)
movsd 0x88(%rsp), %xmm0
callq 0x3610
mulsd 0x100(%rsp), %xmm0
movsd %xmm0, 0x100(%rsp)
movsd 0x40(%rsp), %xmm0
movsd %xmm0, 0x158(%rsp)
fldl 0x158(%rsp)
fstpt 0x40(%rsp)
fldt 0x28(%rsp)
fstpt (%rsp)
callq 0x33a0
fstpt 0xcc(%rsp)
movsd 0x60(%rsp), %xmm0
movsd %xmm0, 0x148(%rsp)
fldl 0x148(%rsp)
fstpt 0x60(%rsp)
fldt 0x28(%rsp)
fstpt (%rsp)
callq 0x3510
fldt 0x60(%rsp)
fmulp %st, %st(1)
fldt 0x40(%rsp)
fldt 0xcc(%rsp)
fmulp %st, %st(1)
fsubp %st, %st(1)
fstpl 0x140(%rsp)
fldt 0x28(%rsp)
fstpt (%rsp)
callq 0x3510
fstpt 0xcc(%rsp)
fldt 0x28(%rsp)
fstpt (%rsp)
callq 0x33a0
movsd 0x110(%rsp), %xmm7
movsd 0x118(%rsp), %xmm6
movsd 0x128(%rsp), %xmm5
fldt 0x50(%rsp)
fldt 0x60(%rsp)
fmulp %st, %st(2)
fldt 0x40(%rsp)
fldt 0xcc(%rsp)
fmulp %st, %st(1)
faddp %st, %st(2)
fxch %st(1)
fstpl 0x138(%rsp)
movsd 0x140(%rsp), %xmm0
movsd 0xe8(%rsp), %xmm4
mulsd %xmm4, %xmm0
movsd 0x170(%rsp), %xmm1
addsd %xmm0, %xmm1
movsd 0x100(%rsp), %xmm3
mulsd %xmm4, %xmm3
movsd 0x178(%rsp), %xmm2
addsd %xmm3, %xmm2
movapd %xmm3, %xmm8
movsd 0x138(%rsp), %xmm3
mulsd %xmm4, %xmm3
movsd 0x168(%rsp), %xmm4
addsd %xmm3, %xmm4
subsd %xmm0, %xmm1
movsd 0xa8(%rsp), %xmm0
divsd %xmm0, %xmm1
movsd %xmm1, (%r15,%rbx,8)
movss 0x38(%rsp), %xmm1
subsd %xmm8, %xmm2
divsd %xmm0, %xmm2
movsd %xmm2, 0x8(%r15,%rbx,8)
movsd 0xf0(%rsp), %xmm2
subsd %xmm3, %xmm4
movsd 0x80(%rsp), %xmm3
divsd %xmm0, %xmm4
movsd %xmm4, 0x10(%r15,%rbx,8)
movsd 0x120(%rsp), %xmm4
movl 0x40(%r12), %eax
movl %eax, 0x20(%r15,%rbx,8)
movq 0x90(%rsp), %rbx
incl %r14d
movl %r14d, %r15d
movsd 0xa8(%rsp), %xmm0
divsd %xmm0, %xmm4
movsd %xmm4, 0x8(%rbp)
divsd %xmm0, %xmm6
movsd %xmm6, 0x10(%rbp)
divsd %xmm0, %xmm7
movsd %xmm7, 0x18(%rbp)
movsd %xmm3, 0x20(%rbp)
movsd %xmm2, 0x28(%rbp)
movsd %xmm5, 0x30(%rbp)
cmpl $0x1, 0x64(%r12)
movss 0x2414(%rip), %xmm0     # 0x93f8
jne 0x7033
fstp %st(0)
cvtsd2ss %xmm3, %xmm3
xorps %xmm4, %xmm4
cvtsd2ss %xmm2, %xmm4
cvtsd2ss %xmm5, %xmm5
movl $0x3f800000, (%rsp)     # imm = 0x3F800000
xorpd %xmm6, %xmm6
xorpd %xmm7, %xmm7
movq %r12, %rdi
movss 0xb8(%rsp), %xmm0
movss 0xb4(%rsp), %xmm1
movss 0xb0(%rsp), %xmm2
callq 0x7cce
fldt 0x50(%rsp)
movss 0x38(%rsp), %xmm1
addss %xmm0, %xmm1
ucomiss 0x23be(%rip), %xmm1     # 0x93fc
jbe 0x7184
xorps %xmm0, %xmm0
cvtss2sd %xmm1, %xmm0
addsd 0x2205(%rip), %xmm0     # 0x9258
cvttsd2si %xmm0, %ebx
movl $0x96, %eax
cmpl %eax, %ebx
movq 0xa0(%rsp), %rsi
jl 0x706d
movl $0x96, %ebx
movss %xmm1, 0x38(%rsp)
cmpl $0x0, 0xb8(%rsi)
fldt 0x50(%r13)
fld %st(1)
fmuls 0x54d2(%rip)            # 0xc558
fxch %st(1)
fmul %st(2), %st
faddp %st, %st(1)
je 0x70ac
fstpt 0x10(%rsp)
fstpt (%rsp)
movq %r12, %rdi
movq %r13, %rdx
leaq 0x7c(%rsp), %rcx
leaq 0x78(%rsp), %r8
callq 0x752e
jmp 0x70c8
fstpt 0x10(%rsp)
fstpt (%rsp)
movq %r12, %rdi
movq %r13, %rdx
leaq 0x7c(%rsp), %rcx
leaq 0x78(%rsp), %r8
callq 0x7406
movslq %ebx, %rbx
testq %rax, %rax
je 0x716f
movl %eax, %ecx
shrl $0x10, %ecx
movl $0xff, %edx
andl %edx, %ecx
imulq %rbx, %rcx
xorps %xmm0, %xmm0
cvtsi2sd %rcx, %xmm0
mulsd 0x21fc(%rip), %xmm0     # 0x92f0
cvttsd2si %xmm0, %rcx
movl $0xff, %esi
cmpq %rsi, %rcx
movss 0x38(%rsp), %xmm1
fldt 0x50(%rsp)
jl 0x7112
movl $0xff, %ecx
movl %eax, %edx
shrl $0x8, %edx
movl $0xff, %edi
andl %edi, %edx
imulq %rbx, %rdx
xorps %xmm0, %xmm0
cvtsi2sd %rdx, %xmm0
mulsd 0x21be(%rip), %xmm0     # 0x92f0
cvttsd2si %xmm0, %rdx
cmpq %rsi, %rdx
jl 0x7141
movl $0xff, %edx
andq %rsi, %rax
imulq %rbx, %rax
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
mulsd 0x2198(%rip), %xmm0     # 0x92f0
cvttsd2si %xmm0, %rax
cmpq %rsi, %rax
jl 0x7167
movl $0xff, %eax
movb %al, (%rbp)
movb %cl, 0x2(%rbp)
jmp 0x7181
xorl %edx, %edx
movb %dl, (%rbp)
movb %dl, 0x2(%rbp)
movss 0x38(%rsp), %xmm1
fldt 0x50(%rsp)
movb %dl, 0x1(%rbp)
xorps %xmm0, %xmm0
cvtsi2ss %rbx, %xmm0
subss %xmm0, %xmm1
fldt 0x30(%r13)
faddp %st, %st(1)
movq 0x40(%r12), %rax
incq %rax
movq %rax, 0x40(%r12)
fldl 0x18(%r13)
fucompi %st(1), %st
ja 0x6a22
fstp %st(0)
movq $0x0, 0x40(%r12)
movb $0x1, %al
addq $0x1e8, %rsp            # imm = 0x1E8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq