Function at 0x509090
Capabilities:
Resolve function by parsing pe exports

Disassembly:
mov eax, 0x74
call fcn.004c4b70
mov eax, dword [0x671580]
xor eax, esp
mov dword [esp + 0x70], eax
mov eax, dword [esp + 0x7c]
xor ecx, ecx
movsd xmm3, qword [esp + 0x88]
xorps xmm4, xmm4
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x80]
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0x84]
push esi
xor esi, esi
mov dword [esp + 0x34], eax
mov eax, dword [esp + 0x98]
test eax, eax
mov dword [esp + 0x28], ecx
mov dword [esp + 0x18], ecx
mov ecx, 6
push edi
mov edi, dword [esp + 0x80]
cmovns ecx, eax
comisd xmm4, xmm3
mov dword [esp + 0x10], edi
mov dword [esp + 0x14], esi
jbe 0x50910d
mov dword [esp + 0x20], 0x2d
jmp 0x509132
mov eax, dword [esp + 0xa0]
test al, 2
je 0x509122
mov dword [esp + 0x20], 0x2b
jmp 0x509132
test al, 4
mov edx, 0x20
mov eax, esi
cmovne eax, edx
mov dword [esp + 0x20], eax
mov edx, dword [esp + 0xa4]
movsd xmm1, qword [0x6198b0]
movsd xmm2, qword [0x659658]
cmp edx, 2
jne 0x5091ab
ucomisd xmm3, xmm4
lahf
test ah, 0x44
jp 0x50915e
mov dword [esp + 0x24], esi
jmp 0x5091bf
movsd xmm0, qword [0x6198a8]
comisd xmm0, xmm3
jbe 0x509176
mov dword [esp + 0x24], 1
jmp 0x5091bf
test ecx, ecx
jne 0x509182
comisd xmm3, xmm1
jae 0x5091a1
test ecx, ecx
jle 0x509158
push ecx
call fcn.00509ad0
movsd xmm1, qword [0x6198b0]
add esp, 4
fstp qword [esp + 8]
comisd xmm3, xmmword [esp + 8]
jb 0x509158
mov dword [esp + 0x24], 1
jmp 0x5091bf
mov dword [esp + 0x24], edx
mov esi, ecx
mov dword [esp + 0x28], esi
test edx, edx
je 0x509251
xor esi, esi
ucomisd xmm3, xmm4
movaps xmm0, xmm3
lahf
test ah, 0x44
jnp 0x5091f6
comisd xmm2, xmm3
jbe 0x5091e1
mulsd xmm0, xmm1
dec esi
comisd xmm2, xmm0
ja 0x5091d2
mov dword [esp + 0x14], esi
comisd xmm0, xmm1
jbe 0x5091f6
divsd xmm0, xmm1
inc esi
comisd xmm0, xmm1
ja 0x5091e7
mov dword [esp + 0x14], esi
mov esi, ecx
mov dword [esp + 0x28], esi
cmp edx, 2
jne 0x50923c
test ecx, ecx
mov eax, 1
cmove esi, eax
mov eax, dword [esp + 0x24]
test eax, eax
jne 0x509235
or eax, 0xffffffff
sub eax, dword [esp + 0x14]
add esi, eax
mov dword [esp + 0x28], esi
jns 0x509251
pop edi
xor eax, eax
pop esi
mov ecx, dword [esp + 0x70]
xor ecx, esp
call fcn.004c4309
add esp, 0x74
ret
dec esi
mov dword [esp + 0x28], esi
jmp 0x509240
mov eax, dword [esp + 0x24]
cmp eax, 1
jne 0x509251
movaps xmm3, xmm0
movsd qword [esp + 0x90], xmm3
comisd xmm4, xmm3
jbe 0x509267
xorps xmm3, xmmword [0x5dc900]
movsd qword [esp + 0x90], xmm3
comisd xmm3, xmmword [0x659688]
ja 0x509222
movaps xmm0, xmm3
call fcn.004c4c50
movsd xmm3, qword [0x659658]
mov edx, eax
movaps xmm1, xmm3
cmp esi, 9
jle 0x509298
mov esi, 9
mov dword [esp + 0x28], esi
mov eax, esi
jmp 0x50929e
mov eax, esi
test esi, esi
je 0x5092b1
movsd xmm2, qword [0x6198b0]
mulsd xmm1, xmm2
sub eax, 1
jne 0x5092a6
jmp 0x5092b9
movsd xmm2, qword [0x6198b0]
movsd xmm4, qword [0x5db658]
cvttsd2si ecx, xmm1
movd xmm0, ecx
cvtdq2pd xmm0, xmm0
subsd xmm1, xmm0
comisd xmm1, xmm4
jb 0x5092d8
inc ecx
mov eax, esi
test esi, esi
je 0x5092e9
nop
mulsd xmm3, xmm2
sub eax, 1
jne 0x5092e0
movsd xmm1, qword [esp + 0x90]
mov eax, edx
movd xmm0, edx
cvtdq2pd xmm0, xmm0
shr eax, 0x1f
addsd xmm0, qword [eax*8 + 0x5dbda0]
subsd xmm1, xmm0
mulsd xmm1, xmm3
cvttsd2si eax, xmm1
movd xmm0, eax
cvtdq2pd xmm0, xmm0
subsd xmm1, xmm0
comisd xmm1, xmm4
jb 0x509327
inc eax
mov esi, eax
lea edi, [edx + 1]
sub esi, ecx
cmp eax, ecx
cmovb esi, eax
cmovb edi, edx
mov dword [esp + 0xc], esi
xor esi, esi
nop dword [eax]
mov eax, 0xcccccccd
mov ecx, esi
mul edi
shr edx, 3
lea eax, [edx + edx*4]
add eax, eax
sub edi, eax
mov al, byte [edi + str.0123456789]
mov edi, edx
mov byte [esp + esi + 0x64], al
inc esi
test edi, edi
je 0x509369
cmp esi, 0x14
jl 0x509340
mov edi, dword [esp + 0x10]
cmp ecx, 0x13
cmovne ecx, esi
mov esi, dword [esp + 0xc]
mov dword [esp + 0x18], ecx
cmp ecx, 0x14
jae 0x5097ea
cmp dword [esp + 0x28], 0
mov byte [esp + ecx + 0x64], 0
jle 0x5093f8
xor eax, eax
cmp dword [esp + 0xa4], 2
jne 0x5093ca
test eax, eax
jne 0x5093ca
mov eax, 0xcccccccd
mul esi
mov eax, esi
shr edx, 3
lea ecx, [edx + edx*4]
add ecx, ecx
sub eax, ecx
jne 0x5093ca
mov eax, dword [esp + 0x28]
mov esi, edx
dec eax
mov dword [esp + 0x28], eax
test eax, eax
jle 0x5093f8
mov eax, dword [esp + 0x2c]
jmp 0x509392
mov ecx, dword [esp + 0x2c]
mov eax, 0xcccccccd
mul esi
shr edx, 3
lea eax, [edx + edx*4]
add eax, eax
sub esi, eax
mov al, byte [esi + str.0123456789]
mov esi, edx
mov byte [esp + ecx + 0x50], al
mov eax, ecx
inc eax
mov dword [esp + 0x2c], eax
cmp eax, dword [esp + 0x28]
jl 0x509392
cmp dword [esp + 0x2c], 0x14
mov esi, 0x13
cmovne esi, dword [esp + 0x2c]
mov dword [esp + 0x10], esi
cmp esi, 0x14
jae 0x5097ea
cmp dword [esp + 0x24], 1
mov byte [esp + esi + 0x50], 0
jne 0x5094ea
mov eax, dword [esp + 0x14]
mov ecx, eax
test eax, eax
jns 0x509436
neg ecx
mov dword [esp + 0x2c], ecx
jmp 0x509440
mov dword [esp + 0x2c], eax
nop word [eax + eax]
mov eax, 0x66666667
imul ecx
sar edx, 2
mov ecx, edx
shr ecx, 0x1f
add ecx, edx
mov edx, dword [esp + 0x2c]
mov dword [esp + 0x2c], ecx
lea eax, [ecx + ecx*4]
add eax, eax
sub edx, eax
mov al, byte [edx + str.0123456789]
mov edx, dword [esp + 0x1c]
mov byte [esp + edx + 0x3c], al
inc edx
mov dword [esp + 0x1c], edx
test ecx, ecx
jle 0x50948f
cmp edx, 0x14
jl 0x509440
pop edi
xor eax, eax
pop esi
mov ecx, dword [esp + 0x70]
xor ecx, esp
call fcn.004c4309
add esp, 0x74
ret
cmp edx, 1
jne 0x5094ec
mov ecx, dword [esp + 0x28]
xor eax, eax
cmp dword [esp + 0x20], eax
mov edx, 2
mov dword [esp + 0x1c], edx
setne al
mov byte [esp + 0x3d], 0x30
sub dword [esp + 0x98], eax
xor eax, eax
test ecx, ecx
setg al
sub dword [esp + 0x98], eax
mov eax, dword [esp + 0x98]
sub eax, dword [esp + 0x18]
sub eax, ecx
mov dword [esp + 0x98], eax
mov eax, 0xfffffffe
sub eax, edx
mov edx, dword [esp + 0x98]
add edx, eax
jmp 0x509542
xor edx, edx
mov ecx, dword [esp + 0x28]
xor eax, eax
cmp dword [esp + 0x20], eax
setne al
sub dword [esp + 0x98], eax
xor eax, eax
test ecx, ecx
setg al
sub dword [esp + 0x98], eax
mov eax, dword [esp + 0x98]
sub eax, dword [esp + 0x18]
sub eax, ecx
cmp dword [esp + 0x24], 1
mov dword [esp + 0x98], eax
jne 0x50953b
mov eax, 0xfffffffe
sub eax, edx
mov edx, dword [esp + 0x98]
add edx, eax
jmp 0x509542
mov edx, dword [esp + 0x98]
mov eax, ecx
mov ecx, 0
sub eax, esi
cmovns ecx, eax
mov dword [esp + 0x2c], ecx
xor ecx, ecx
test edx, edx
cmovns ecx, edx
mov edx, ecx
neg edx
test byte [esp + 0xa0], 1
cmove edx, ecx
test byte [esp + 0xa0], 0x10
mov dword [esp + 0xc], edx
mov esi, edx
je 0x5095d6
test edx, edx
jle 0x5095d6
mov eax, dword [esp + 0x20]
test eax, eax
je 0x5095b0
push eax
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push edi
call fcn.00508fa0
add esp, 0x14
test eax, eax
je 0x509222
dec esi
mov dword [esp + 0x20], 0
test esi, esi
jle 0x509604
nop
push 0x30
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push edi
call fcn.00508fa0
add esp, 0x14
test eax, eax
je 0x509222
dec esi
test esi, esi
jg 0x5095b0
jmp 0x509604
test esi, esi
jle 0x509604
nop word [eax + eax]
push 0x20
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push edi
call fcn.00508fa0
add esp, 0x14
test eax, eax
je 0x509222
dec esi
test esi, esi
jg 0x5095e0
mov eax, dword [esp + 0x20]
test eax, eax
je 0x50962a
push eax
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push edi
call fcn.00508fa0
add esp, 0x14
test eax, eax
je 0x509222
mov eax, dword [esp + 0x18]
test eax, eax
jle 0x509662
dec eax
mov dword [esp + 0x18], eax
movsx eax, byte [esp + eax + 0x64]
push eax
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push edi
call fcn.00508fa0
add esp, 0x14
test eax, eax
je 0x509222
mov eax, dword [esp + 0x18]
test eax, eax
jg 0x509632
cmp dword [esp + 0x28], 0
jg 0x509673
test byte [esp + 0xa0], 8
je 0x5096d0
push 0x2e
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push edi
call fcn.00508fa0
add esp, 0x14
test eax, eax
je 0x509222
mov eax, dword [esp + 0x10]
test eax, eax
jle 0x5096d0
nop word [eax + eax]
dec eax
mov dword [esp + 0x10], eax
movsx eax, byte [esp + eax + 0x50]
push eax
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push edi
call fcn.00508fa0
add esp, 0x14
test eax, eax
je 0x509222
mov eax, dword [esp + 0x10]
test eax, eax
jg 0x5096a0
cmp dword [esp + 0x2c], 0
jle 0x50970c
nop word [eax + eax]
push 0x30
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push edi
call fcn.00508fa0
add esp, 0x14
test eax, eax
je 0x509222
mov eax, dword [esp + 0x2c]
dec eax
mov dword [esp + 0x2c], eax
test eax, eax
jg 0x5096e0
cmp dword [esp + 0x24], 1
jne 0x5097a6
mov eax, dword [esp + 0xa0]
not eax
and eax, 0x20
or eax, 0x45
push eax
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push edi
call fcn.00508fa0
add esp, 0x14
test eax, eax
je 0x509222
cmp dword [esp + 0x14], 0
jge 0x50974f
push 0x2d
jmp 0x509751
push 0x2b
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push edi
call fcn.00508fa0
add esp, 0x14
test eax, eax
je 0x509222
mov eax, dword [esp + 0x1c]
test eax, eax
jle 0x5097a6
dec eax
mov dword [esp + 0x1c], eax
movsx eax, byte [esp + eax + 0x3c]
push eax
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push edi
call fcn.00508fa0
add esp, 0x14
test eax, eax
je 0x509222
mov eax, dword [esp + 0x1c]
test eax, eax
jg 0x509776
test esi, esi
jns 0x5097d4
nop word [eax + eax]
push 0x20
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push edi
call fcn.00508fa0
add esp, 0x14
test eax, eax
je 0x509222
add esi, 1
js 0x5097b0
mov ecx, dword [esp + 0x78]
mov eax, 1
pop edi
pop esi
xor ecx, esp
call fcn.004c4309
add esp, 0x74
ret
call fcn.004c4a4b
int3