// File: /workspace/github_c_makefile_star2_O1/enzo1982[P]smooth/classes/gui/widgets/multi/menu/popupmenuentry.cpp
// Function: smooth::GUI::PopupMenuEntry::Paint(int)
S::Int S::GUI::PopupMenuEntry::Paint(Int message)
{
	if (!IsRegistered()) return Error();
	if (!IsVisible())    return Success();

	Surface	*surface = GetDrawSurface();
	Rect	 frame	 = Rect(GetRealPosition(), GetRealSize());
	Rect	 bmpRect = Rect(GetRealPosition() + Point(2, 2) * surface->GetSurfaceDPI() / 96.0 - Point(0, 1), Size(12, 12) * surface->GetSurfaceDPI() / 96.0);

	surface->StartPaint(frame);

	switch (message)
	{
		case SP_PAINT:
		case SP_MOUSEOUT:
			if (text == NIL && bitmap == NIL)
			{
				Point	 p1 = Point(frame.left - 1, frame.top + 1);
				Point	 p2 = Point(frame.right + 1, frame.top + 1);

				surface->Bar(p1, p2, OR_HORZ);
			}
			else if (text != NIL || bitmap != NIL)
			{
				Rect	 textRect = frame + Point(18 * surface->GetSurfaceDPI() / 96.0, Math::Ceil(Float(frame.GetHeight() - scaledTextSize.cy) / 2) - 2) - Size(4 + 18 * surface->GetSurfaceDPI() / 96.0, 0);
				Font	 nFont	  = font;

				if (!IsActive()) nFont.SetColor(Setup::InactiveTextColor);

				surface->Box(frame, Setup::BackgroundColor, Rect::Filled);
				surface->SetText(text, textRect, nFont);

				if (bitmap != NIL && bVar == NIL && iVar == NIL)
				{
					if (IsActive())	surface->BlitFromBitmap(bitmap, Rect(Point(0, 0), bitmap.GetSize()), bmpRect);
					else		surface->BlitFromBitmap(graymap, Rect(Point(0, 0), graymap.GetSize()), bmpRect);
				}

				if (shortcut != NIL)
				{
					textRect.left = textRect.right - Math::Round(shortcutOffset * surface->GetSurfaceDPI() / 96.0);

					surface->SetText(shortcut->ToString(), textRect, nFont);
				}

				if (popup != NIL)
				{
					Int	 size = Math::Round(3 * surface->GetSurfaceDPI() / 96.0);

					Point	 lineStart = Point(frame.right - 4 - size, frame.top + 1 + Math::Round(4 * surface->GetSurfaceDPI() / 96.0));
					Point	 lineEnd   = Point(frame.right - 4 - size, frame.top + 1 + Math::Round(4 * surface->GetSurfaceDPI() / 96.0) + size * 2 - 1);

					for (Int i = 0; i < size; i++) surface->Line(lineStart + Point(i, i), lineEnd + Point(i, -i), Setup::TextColor);
				}
			}

			break;
		case SP_MOUSEIN:
			if (text != NIL || bitmap != NIL)
			{
				Rect	 textRect = frame + Point(18 * surface->GetSurfaceDPI() / 96.0, Math::Ceil(Float(frame.GetHeight() - scaledTextSize.cy) / 2) - 2) - Size(4 + 18 * surface->GetSurfaceDPI() / 96.0, 0);
				Font	 nFont	  = font;

				nFont.SetColor(Setup::GradientTextColor);

				surface->Gradient(frame, Setup::GradientStartColor, Setup::GradientEndColor, OR_HORZ);
				surface->SetText(text, textRect, nFont);

				if (bitmap != NIL && bVar == NIL && iVar == NIL)
				{
					surface->BlitFromBitmap(bitmap, Rect(Point(0, 0), bitmap.GetSize()), bmpRect);
				}

				if (shortcut != NIL)
				{
					textRect.left = textRect.right - Math::Round(shortcutOffset * surface->GetSurfaceDPI() / 96.0);

					surface->SetText(shortcut->ToString(), textRect, nFont);
				}

				if (popup != NIL)
				{
					Int	 size = Math::Round(3 * surface->GetSurfaceDPI() / 96.0);

					Point	 lineStart = Point(frame.right - 4 - size, frame.top + 1 + Math::Round(4 * surface->GetSurfaceDPI() / 96.0));
					Point	 lineEnd   = Point(frame.right - 4 - size, frame.top + 1 + Math::Round(4 * surface->GetSurfaceDPI() / 96.0) + size * 2 - 1);

					for (Int i = 0; i < size; i++) surface->Line(lineStart + Point(i, i), lineEnd + Point(i, -i), Setup::GradientTextColor);
				}
			}

			break;
	}

	surface->EndPaint();

	return Success();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xb8, %rsp
movl %esi, %ebp
movq %rdi, %r15
movq (%rdi), %rax
callq *0x88(%rax)
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
testb %al, %al
je 0x8d970
movq (%r15), %rax
movq %r15, %rdi
callq *0x90(%rax)
xorl %ecx, %ecx
testb %al, %al
je 0x8d970
movq (%r15), %rax
movq %r15, %rdi
callq *0x40(%rax)
movq %rax, %r12
movq (%r15), %rax
movq %r15, %rdi
callq *0x48(%rax)
movq %rax, %r13
movq %rax, %rbx
shrq $0x20, %rbx
movq (%r15), %rax
movq %r15, %rdi
callq *0x50(%rax)
leal (%rax,%r13), %ecx
shrq $0x20, %rax
leaq 0x8(%rsp), %rdx
movl %r13d, (%rdx)
movl %ebx, 0x4(%rdx)
movl %ecx, 0x8(%rdx)
addl %ebx, %eax
movl %eax, 0xc(%rdx)
movq (%r15), %rax
movq %r15, %rdi
callq *0x48(%rax)
movq %rax, %r13
movq %rax, %rbx
shrq $0x20, %rbx
movq %r12, %rdi
callq 0x58930
cwtl
cvtsi2sd %eax, %xmm0
addsd %xmm0, %xmm0
xorpd %xmm2, %xmm2
movapd %xmm0, %xmm1
cmpltsd %xmm2, %xmm1
xorpd %xmm4, %xmm4
movsd 0x6738c(%rip), %xmm3    # 0xf4390
movapd %xmm1, %xmm2
andpd %xmm3, %xmm2
movapd %xmm3, %xmm5
movsd 0x67380(%rip), %xmm3    # 0xf4398
andnpd %xmm3, %xmm1
orpd %xmm2, %xmm1
addsd %xmm0, %xmm1
cvttsd2si %xmm1, %rax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd 0x674b8(%rip), %xmm0    # 0xf44f0
movapd %xmm0, %xmm1
cmpltsd %xmm4, %xmm1
movapd %xmm1, %xmm2
andpd %xmm5, %xmm2
andnpd %xmm3, %xmm1
orpd %xmm2, %xmm1
addsd %xmm0, %xmm1
cvttsd2si %xmm1, %rax
addl %eax, %r13d
leal (%rbx,%rax), %r14d
addl %eax, %ebx
decl %ebx
movq %r12, %rdi
callq 0x58930
cwtl
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x6a973(%rip), %xmm0    # 0xf79f0
movapd %xmm0, %xmm1
xorpd %xmm3, %xmm3
cmpltsd %xmm3, %xmm1
movapd %xmm1, %xmm2
movsd 0x672fa(%rip), %xmm4    # 0xf4390
andpd %xmm4, %xmm2
movsd 0x672f6(%rip), %xmm5    # 0xf4398
andnpd %xmm5, %xmm1
orpd %xmm2, %xmm1
addsd %xmm0, %xmm1
cvttsd2si %xmm1, %rax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd 0x6742e(%rip), %xmm0    # 0xf44f0
movapd %xmm0, %xmm1
cmpltsd %xmm3, %xmm1
movapd %xmm4, %xmm2
andpd %xmm1, %xmm2
andnpd %xmm5, %xmm1
orpd %xmm2, %xmm1
addsd %xmm0, %xmm1
cvttsd2si %xmm1, %rax
movl %r13d, 0x68(%rsp)
movl %ebx, 0x6c(%rsp)
addl %eax, %r13d
movl %r13d, 0x70(%rsp)
addl %r14d, %eax
decl %eax
movq %r12, %r14
movl %eax, 0x74(%rsp)
movq %r12, %rdi
leaq 0x8(%rsp), %rsi
callq 0x55160
cmpl $0x3, %ebp
je 0x8d124
cmpl $0x2, %ebp
je 0x8d34e
testl %ebp, %ebp
jne 0x8d966
leaq 0xf0(%r15), %r12
movq %r12, %rdi
xorl %esi, %esi
callq 0x55260
testb %al, %al
je 0x8d183
leaq 0x5c0(%r15), %rdi
xorl %esi, %esi
callq 0x57e30
testb %al, %al
je 0x8d183
movl 0x8(%rsp), %eax
movl 0xc(%rsp), %ecx
decl %eax
incl %ecx
leaq 0x78(%rsp), %rsi
movl %eax, (%rsi)
movl %ecx, 0x4(%rsi)
movl 0x10(%rsp), %eax
incl %eax
leaq 0x30(%rsp), %rdx
movl %eax, (%rdx)
movl %ecx, 0x4(%rdx)
movq %r14, %rdi
movl $0x1, %ecx
callq 0x58fc0
jmp 0x8d966
movq %r12, %rdi
xorl %esi, %esi
callq 0x56bd0
testb %al, %al
jne 0x8d1a7
leaq 0x5c0(%r15), %rdi
xorl %esi, %esi
callq 0x563f0
testb %al, %al
je 0x8d966
movq %r14, %rdi
callq 0x58930
cwtl
addl %eax, %eax
leal (%rax,%rax,8), %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd 0x6732c(%rip), %xmm1    # 0xf44f0
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %ebx
movl 0xc(%rsp), %eax
movl 0x14(%rsp), %ecx
addl 0x18c(%r15), %eax
subl %eax, %ecx
xorps %xmm0, %xmm0
cvtsi2sd %ecx, %xmm0
mulsd 0x671ac(%rip), %xmm0    # 0xf4398
callq 0x56cb0
movq %rax, %r13
addl $-0x2, %r13d
movq %r14, 0x18(%rsp)
movl 0x8(%rsp), %r14d
addl %ebx, %r14d
movl 0xc(%rsp), %ebp
addl %r13d, %ebp
addl 0x10(%rsp), %ebx
shlq $0x20, %rbp
addl 0x14(%rsp), %r13d
shlq $0x20, %r13
movq 0x18(%rsp), %rdi
callq 0x58930
cwtl
addl %eax, %eax
leal (%rax,%rax,8), %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd 0x672b4(%rip), %xmm0    # 0xf44f0
addsd 0x6715c(%rip), %xmm0    # 0xf43a0
cvttsd2si %xmm0, %eax
subl %eax, %ebx
orq %rbp, %r14
orq %r13, %rbx
movq %r14, 0x20(%rsp)
movq 0x18(%rsp), %r14
movq %rbx, 0x28(%rsp)
leaq 0x140(%r15), %rsi
leaq 0x78(%rsp), %rdi
callq 0x55b70
movq (%r15), %rax
movq %r15, %rdi
callq *0x98(%rax)
testb %al, %al
jne 0x8d291
movq 0xdf6c9(%rip), %rsi     # 0x16c950
leaq 0x78(%rsp), %rdi
callq 0x58650
movq 0xdfd10(%rip), %rax     # 0x16cfa8
movl (%rax), %ecx
leaq 0x30(%rsp), %r8
movq $0x0, (%r8)
movq 0xdf223(%rip), %rdx     # 0x16c4d0
leaq 0x8(%rsp), %rsi
movq %r14, %rdi
callq 0x57930
leaq 0x20(%rsp), %rdx
leaq 0x78(%rsp), %rcx
movq %r14, %rdi
movq %r12, %rsi
xorl %r8d, %r8d
callq 0x57b80
leaq 0x5c0(%r15), %r12
movq %r12, %rdi
xorl %esi, %esi
callq 0x563f0
cmpq $0x0, 0x5d8(%r15)
sete %cl
andb %cl, %al
cmpb $0x1, %al
jne 0x8d73d
cmpq $0x0, 0x5e0(%r15)
jne 0x8d73d
movq (%r15), %rax
movq %r15, %rdi
callq *0x98(%rax)
testb %al, %al
je 0x8d707
movq %r12, %rdi
callq 0x58410
leaq 0x30(%rsp), %rdx
movq $0x0, (%rdx)
movl (%rax), %ecx
movl %ecx, 0x8(%rdx)
movl 0x4(%rax), %eax
movl %eax, 0xc(%rdx)
leaq 0x68(%rsp), %rcx
movq %r14, %rdi
movq %r12, %rsi
callq 0x55ba0
jmp 0x8d73d
leaq 0xf0(%r15), %r12
movq %r12, %rdi
xorl %esi, %esi
callq 0x56bd0
testb %al, %al
jne 0x8d379
leaq 0x5c0(%r15), %rdi
xorl %esi, %esi
callq 0x563f0
testb %al, %al
je 0x8d966
movq %r14, %rdi
callq 0x58930
cwtl
addl %eax, %eax
leal (%rax,%rax,8), %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd 0x6715a(%rip), %xmm1    # 0xf44f0
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %ebx
movl 0xc(%rsp), %eax
movl 0x14(%rsp), %ecx
addl 0x18c(%r15), %eax
subl %eax, %ecx
xorps %xmm0, %xmm0
cvtsi2sd %ecx, %xmm0
mulsd 0x66fda(%rip), %xmm0    # 0xf4398
callq 0x56cb0
movq %rax, %r13
addl $-0x2, %r13d
movq %r14, 0x18(%rsp)
movl 0x8(%rsp), %r14d
addl %ebx, %r14d
movl 0xc(%rsp), %ebp
addl %r13d, %ebp
addl 0x10(%rsp), %ebx
shlq $0x20, %rbp
addl 0x14(%rsp), %r13d
shlq $0x20, %r13
movq 0x18(%rsp), %rdi
callq 0x58930
cwtl
addl %eax, %eax
leal (%rax,%rax,8), %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd 0x670e2(%rip), %xmm0    # 0xf44f0
addsd 0x66f8a(%rip), %xmm0    # 0xf43a0
cvttsd2si %xmm0, %eax
subl %eax, %ebx
orq %rbp, %r14
orq %r13, %rbx
movq %r14, 0x20(%rsp)
movq 0x18(%rsp), %r14
movq %rbx, 0x28(%rsp)
leaq 0x140(%r15), %rsi
leaq 0x78(%rsp), %r13
movq %r13, %rdi
callq 0x55b70
movq 0xdf6e4(%rip), %rsi     # 0x16cb30
movq %r13, %rdi
callq 0x58650
movq 0xdfb5d(%rip), %rdx     # 0x16cfb8
movq 0xdfabe(%rip), %rcx     # 0x16cf20
leaq 0x8(%rsp), %rsi
movq %r14, %rdi
movl $0x1, %r8d
callq 0x58750
leaq 0x20(%rsp), %rdx
leaq 0x78(%rsp), %rcx
movq %r14, %rdi
movq %r12, %rsi
xorl %r8d, %r8d
callq 0x57b80
leaq 0x5c0(%r15), %r12
movq %r12, %rdi
xorl %esi, %esi
callq 0x563f0
cmpq $0x0, 0x5d8(%r15)
sete %cl
andb %cl, %al
cmpb $0x1, %al
jne 0x8d4e8
cmpq $0x0, 0x5e0(%r15)
jne 0x8d4e8
movq %r12, %rdi
callq 0x58410
leaq 0x30(%rsp), %rdx
movq $0x0, (%rdx)
movl (%rax), %ecx
movl %ecx, 0x8(%rdx)
movl 0x4(%rax), %eax
movl %eax, 0xc(%rdx)
leaq 0x68(%rsp), %rcx
movq %r14, %rdi
movq %r12, %rsi
callq 0x55ba0
cmpq $0x0, 0x5d0(%r15)
je 0x8d576
movl 0x28(%rsp), %ebx
movl 0x610(%r15), %ebp
movq %r14, %rdi
callq 0x58930
cwtl
imull %eax, %ebp
xorps %xmm0, %xmm0
cvtsi2sd %ebp, %xmm0
divsd 0x66fd4(%rip), %xmm0    # 0xf44f0
xorpd %xmm1, %xmm1
xorl %eax, %eax
ucomisd %xmm0, %xmm1
seta %al
leaq 0x67260(%rip), %rcx     # 0xf4790
addsd (%rcx,%rax,8), %xmm0
cvttsd2si %xmm0, %rax
subl %eax, %ebx
movl %ebx, 0x20(%rsp)
movq 0x5d0(%r15), %rsi
movq (%rsi), %rax
leaq 0x30(%rsp), %rdi
callq *0x20(%rax)
leaq 0x30(%rsp), %rsi
leaq 0x20(%rsp), %rdx
leaq 0x78(%rsp), %rcx
movq %r14, %rdi
xorl %r8d, %r8d
callq 0x57b80
leaq 0x30(%rsp), %rdi
callq 0x59200
cmpq $0x0, 0x5b8(%r15)
je 0x8d957
movq 0x18(%rsp), %rbx
movq %rbx, %rdi
callq 0x58930
cwtl
leal (%rax,%rax,2), %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd 0x66f4c(%rip), %xmm0    # 0xf44f0
xorpd %xmm1, %xmm1
xorl %r13d, %r13d
movsd %xmm0, 0x58(%rsp)
ucomisd %xmm0, %xmm1
seta %r12b
movl 0xc(%rsp), %eax
movq %rax, 0x50(%rsp)
movl 0x10(%rsp), %ebp
movq %rbx, %rdi
callq 0x58930
movq %rbx, %rdi
cwtl
shll $0x2, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd 0x66f0c(%rip), %xmm0    # 0xf44f0
xorl %r15d, %r15d
movsd %xmm0, 0x48(%rsp)
xorpd %xmm1, %xmm1
ucomisd %xmm0, %xmm1
seta 0x7(%rsp)
movl 0xc(%rsp), %ebx
movl 0x10(%rsp), %r14d
callq 0x58930
movb %r12b, %r13b
leaq 0x6717e(%rip), %rdx     # 0xf4790
movsd 0x58(%rsp), %xmm0
addsd (%rdx,%r13,8), %xmm0
cvttsd2si %xmm0, %rcx
cwtl
shll $0x2, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd 0x66eba(%rip), %xmm0    # 0xf44f0
xorpd %xmm1, %xmm1
xorl %esi, %esi
ucomisd %xmm0, %xmm1
seta %dil
testl %ecx, %ecx
jle 0x8d957
movb 0x7(%rsp), %al
movb %al, %r15b
movsd 0x48(%rsp), %xmm1
addsd (%rdx,%r15,8), %xmm1
cvttsd2si %xmm1, %rax
incl %ebx
movb %dil, %sil
addsd (%rdx,%rsi,8), %xmm0
cvttsd2si %xmm0, %rdx
leaq (%rcx,%rcx), %rsi
movabsq $-0x100000000, %rdi     # imm = 0xFFFFFFFF00000000
movl %ecx, %r15d
andl $0x7fffffff, %r15d      # imm = 0x7FFFFFFF
subl %ecx, %r14d
addl $-0x4, %r14d
addl %edx, %ebx
addl %esi, %ebx
shlq $0x20, %rbx
addq %rdi, %rbx
subl %ecx, %ebp
addl $-0x4, %ebp
movq 0x50(%rsp), %rcx
leal (%rcx,%rax), %r12d
incl %r12d
leaq 0x60(%rsp), %r13
movl %r14d, %eax
addq %rbx, %rax
movq %r12, %rcx
shlq $0x20, %rcx
movl %ebp, %edx
orq %rcx, %rdx
movq %rdx, 0x30(%rsp)
movq %rax, 0x60(%rsp)
movq 0x18(%rsp), %rdi
leaq 0x30(%rsp), %rsi
movq %r13, %rdx
movq 0xdf44d(%rip), %rcx     # 0x16cb30
callq 0x58300
incl %r14d
movabsq $-0x100000000, %rax     # imm = 0xFFFFFFFF00000000
addq %rax, %rbx
incl %ebp
incl %r12d
decq %r15
jne 0x8d6b3
jmp 0x8d957
leaq 0x5c8(%r15), %r12
movq %r12, %rdi
callq 0x58410
leaq 0x30(%rsp), %rdx
movq $0x0, (%rdx)
movl (%rax), %ecx
movl %ecx, 0x8(%rdx)
movl 0x4(%rax), %eax
movl %eax, 0xc(%rdx)
leaq 0x68(%rsp), %rcx
movq %r14, %rdi
movq %r12, %rsi
callq 0x55ba0
cmpq $0x0, 0x5d0(%r15)
je 0x8d7cb
movl 0x28(%rsp), %ebx
movl 0x610(%r15), %ebp
movq %r14, %rdi
callq 0x58930
cwtl
imull %eax, %ebp
xorps %xmm0, %xmm0
cvtsi2sd %ebp, %xmm0
divsd 0x66d7f(%rip), %xmm0    # 0xf44f0
xorpd %xmm1, %xmm1
xorl %eax, %eax
ucomisd %xmm0, %xmm1
seta %al
leaq 0x6700b(%rip), %rcx     # 0xf4790
addsd (%rcx,%rax,8), %xmm0
cvttsd2si %xmm0, %rax
subl %eax, %ebx
movl %ebx, 0x20(%rsp)
movq 0x5d0(%r15), %rsi
movq (%rsi), %rax
leaq 0x30(%rsp), %rdi
callq *0x20(%rax)
leaq 0x30(%rsp), %rsi
leaq 0x20(%rsp), %rdx
leaq 0x78(%rsp), %rcx
movq %r14, %rdi
xorl %r8d, %r8d
callq 0x57b80
leaq 0x30(%rsp), %rdi
callq 0x59200
cmpq $0x0, 0x5b8(%r15)
je 0x8d957
movq 0x18(%rsp), %rbx
movq %rbx, %rdi
callq 0x58930
cwtl
leal (%rax,%rax,2), %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd 0x66cf7(%rip), %xmm0    # 0xf44f0
xorpd %xmm1, %xmm1
xorl %r13d, %r13d
movsd %xmm0, 0x58(%rsp)
ucomisd %xmm0, %xmm1
seta %r12b
movl 0xc(%rsp), %eax
movq %rax, 0x50(%rsp)
movl 0x10(%rsp), %ebp
movq %rbx, %rdi
callq 0x58930
movq %rbx, %rdi
cwtl
shll $0x2, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd 0x66cb7(%rip), %xmm0    # 0xf44f0
xorl %r15d, %r15d
movsd %xmm0, 0x48(%rsp)
xorpd %xmm1, %xmm1
ucomisd %xmm0, %xmm1
seta 0x7(%rsp)
movl 0xc(%rsp), %ebx
movl 0x10(%rsp), %r14d
callq 0x58930
movb %r12b, %r13b
leaq 0x66f29(%rip), %rdx     # 0xf4790
movsd 0x58(%rsp), %xmm0
addsd (%rdx,%r13,8), %xmm0
cvttsd2si %xmm0, %rcx
cwtl
shll $0x2, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd 0x66c65(%rip), %xmm0    # 0xf44f0
xorpd %xmm1, %xmm1
xorl %esi, %esi
ucomisd %xmm0, %xmm1
seta %dil
testl %ecx, %ecx
jle 0x8d957
movb 0x7(%rsp), %al
movb %al, %r15b
movsd 0x48(%rsp), %xmm1
addsd (%rdx,%r15,8), %xmm1
cvttsd2si %xmm1, %rax
incl %ebx
movb %dil, %sil
addsd (%rdx,%rsi,8), %xmm0
cvttsd2si %xmm0, %rdx
leaq (%rcx,%rcx), %rsi
movabsq $-0x100000000, %rdi     # imm = 0xFFFFFFFF00000000
movl %ecx, %r15d
andl $0x7fffffff, %r15d      # imm = 0x7FFFFFFF
subl %ecx, %r14d
addl $-0x4, %r14d
addl %edx, %ebx
addl %esi, %ebx
shlq $0x20, %rbx
addq %rdi, %rbx
subl %ecx, %ebp
addl $-0x4, %ebp
movq 0x50(%rsp), %rcx
leal (%rcx,%rax), %r12d
incl %r12d
leaq 0x60(%rsp), %r13
movl %r14d, %eax
addq %rbx, %rax
movq %r12, %rcx
shlq $0x20, %rcx
movl %ebp, %edx
orq %rcx, %rdx
movq %rdx, 0x30(%rsp)
movq %rax, 0x60(%rsp)
movq 0x18(%rsp), %rdi
leaq 0x30(%rsp), %rsi
movq %r13, %rdx
movq 0xdf0b0(%rip), %rcx     # 0x16c9e8
callq 0x58300
incl %r14d
movabsq $-0x100000000, %rax     # imm = 0xFFFFFFFF00000000
addq %rax, %rbx
incl %ebp
incl %r12d
decq %r15
jne 0x8d908
leaq 0x78(%rsp), %rdi
callq 0x56720
movq 0x18(%rsp), %r14
movq %r14, %rdi
callq 0x58780
xorl %ecx, %ecx
movl %ecx, %eax
addq $0xb8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x8d9b3
jmp 0x8d9b3
jmp 0x8d996
jmp 0x8d9b3
jmp 0x8d9b3
jmp 0x8d9b3
jmp 0x8d9b3
jmp 0x8d9b3
jmp 0x8d9b3
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0x59200
jmp 0x8d9b6
jmp 0x8d9b3
jmp 0x8d9b3
jmp 0x8d9b3
jmp 0x8d9b3
jmp 0x8d9b3
jmp 0x8d9b3
jmp 0x8d9b3
movq %rax, %rbx
leaq 0x78(%rsp), %rdi
callq 0x56720
movq %rbx, %rdi
callq 0x57090