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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xffffffe0
sub esp, 0x118
mov eax, dword [0x1005b008]
xor eax, esp
mov dword [esp + 0x114], eax
mov eax, dword [0x1006ef44]
push esi
push edi
mov edi, ecx
mov dword [esp + 0x14], eax
xor esi, esi
mov dword [esp + 0x1c], edi
vpxor xmm0, xmm0, xmm0
mov byte [esp + 0x68], 0
mov eax, dword [edi]
mov byte [edi + 0x67], 0
mov dword [esp + 0xe0], esi
mov dword [esp + 0x18], esi
mov dword [esp + 0x34], 1
vmovdqu ymmword [esp + 0xc0], ymm0
test eax, eax
jle 0x100407fe
mov dword [esp + 0x20], esi
xor edx, edx
mov ecx, dword [edi + 8]
mov eax, dword [edx + ecx + 8]
cmp eax, dword [edi + 0x24]
jl 0x100407bb
cmp byte [edx + ecx + 0x28], 0
jne 0x100407bb
cmp esi, dword [esp + 0x18]
je 0x1004073d
mov edi, dword [esp + 0x20]
vmovdqu ymm0, ymmword [edx + ecx]
vmovq xmm1, qword [edx + ecx + 0x20]
mov eax, dword [edx + ecx + 0x28]
vmovdqu ymmword [edi + ecx], ymm0
vmovq qword [edi + ecx + 0x20], xmm1
mov dword [edi + ecx + 0x28], eax
mov edi, dword [esp + 0x1c]
mov eax, dword [edi + 8]
add eax, dword [esp + 0x20]
mov word [eax + 0x26], si
mov eax, dword [eax + 4]
test al, 0x40
je 0x10040753
xor ecx, ecx
jmp 0x1004075e
test al, 0x80
mov ecx, 0
setne cl
inc ecx
test esi, esi
jle 0x100407a9
mov eax, dword [edi + 8]
mov edi, dword [esp + 0x20]
mov eax, dword [eax + edi - 0x28]
test al, 0x40
je 0x10040775
xor eax, eax
jmp 0x10040780
test al, 0x80
mov eax, 0
setne al
inc eax
mov edi, dword [esp + 0x1c]
test ecx, ecx
jne 0x10040791
test eax, eax
je 0x100407a9
mov byte [esp + 0x68], 1
cmp eax, 2
jne 0x100407a9
mov eax, dword [esp + 0x68]
cmp ecx, 2
movzx eax, al
cmovne eax, dword [esp + 0x34]
mov dword [esp + 0x68], eax
lea eax, [ecx + ecx*2]
inc esi
inc dword [esp + eax*4 + 0xc0]
add dword [esp + 0x20], 0x2c
jmp 0x100407e8
mov eax, dword [edi + 0x1c]
cmp eax, dword [edx + ecx]
jne 0x100407ca
mov dword [edi + 0x1c], 0
mov eax, dword [edi + 0x14]
cmp eax, dword [edx + ecx]
jne 0x100407d9
mov dword [edi + 0x14], 0
mov eax, dword [edi + 0x18]
cmp eax, dword [edx + ecx]
jne 0x100407e8
mov dword [edi + 0x18], 0
mov ecx, dword [esp + 0x18]
add edx, 0x2c
mov eax, dword [edi]
inc ecx
mov dword [esp + 0x18], ecx
cmp ecx, eax
jl 0x100406f6
cmp eax, esi
je 0x10040834
mov eax, dword [edi + 4]
cmp esi, eax
jle 0x10040830
test eax, eax
je 0x10040819
cdq
sub eax, edx
mov ecx, eax
sar ecx, 1
add ecx, dword [edi + 4]
jmp 0x1004081e
mov ecx, 8
cmp ecx, esi
mov eax, esi
cmovg eax, ecx
mov ecx, edi
push eax
vzeroupper
call fcn.100430d0
mov dword [edi], esi
mov eax, esi
cmp byte [esp + 0x68], 0
je 0x10040857
cmp eax, 1
jbe 0x10040857
push 0x100400b0
push 0x2c
push eax
push dword [edi + 8]
vzeroupper
call dword [sym.imp.api_ms_win_crt_utility_l1_1_0.dll_qsort]
add esp, 0x10
cmp dword [esp + 0xc0], 0
jle 0x10040881
mov eax, dword [esp + 0xcc]
add eax, dword [esp + 0xd8]
test eax, eax
jle 0x10040881
mov eax, dword [esp + 0x14]
vmovss xmm1, dword [eax + 0x37d4]
jmp 0x10040889
mov eax, dword [esp + 0x14]
vxorps xmm1, xmm1, xmm1
cmp dword [esp + 0xcc], 0
vxorps xmm0, xmm0, xmm0
vmovss dword [esp + 0xc8], xmm1
jle 0x100408b2
cmp dword [esp + 0xd8], 0
jle 0x100408b2
vmovss xmm0, dword [eax + 0x37d4]
xor eax, eax
mov dword [esp + 0x20], eax
mov eax, dword [edi + 0x18]
vmovss dword [esp + 0xd4], xmm0
test eax, eax
je 0x100408d6
mov dword [esp + 0x20], eax
mov dword [edi + 0x14], eax
mov dword [edi + 0x18], 0
mov edx, dword [edi + 0x60]
test edx, edx
je 0x10040a20
mov ecx, dword [edi]
xor eax, eax
test ecx, ecx
jle 0x10040a19
mov esi, dword [edi + 8]
cmp dword [esi], edx
je 0x10040901
inc eax
add esi, 0x2c
cmp eax, ecx
jl 0x100408f0
jmp 0x10040a19
test esi, esi
je 0x10040a19
test byte [esi + 4], 0x20
jne 0x10040a19
mov ecx, esi
mov eax, 0x2e8ba2e9
sub ecx, dword [edi + 8]
imul ecx
sar edx, 3
mov eax, edx
shr eax, 0x1f
add eax, edx
movzx edx, word [edi + 0x64]
movsx ecx, dx
add eax, ecx
js 0x10040a19
cmp eax, dword [edi]
jge 0x10040a19
imul eax, eax, 0x2c
add eax, dword [edi + 8]
mov dword [esp + 0x34], eax
mov edx, dword [eax + 4]
test dl, 0x20
jne 0x10040a19
xor edx, dword [esi + 4]
test dl, 0xc0
jne 0x10040a19
mov edx, dword [esi + 0x28]
vmovdqu ymm0, ymmword [esi]
mov dword [esp + 0x28], edx
lea edx, [esi + 0x2c]
mov dword [esp + 0x18], edx
movzx edx, word [edi + 0x64]
mov edi, dword [esp + 0x18]
test dx, dx
vmovdqu ymmword [esp + 0x80], ymm0
vmovq xmm0, qword [esi + 0x20]
cmovle edi, eax
add eax, 0x2c
test dx, dx
mov dword [esp + 0x18], edi
vmovq qword [esp + 0x40], xmm0
cmovle esi, eax
jg 0x100409a7
neg ecx
imul eax, ecx, 0x2c
push eax
push dword [esp + 0x1c]
push esi
vzeroupper
call sub.VCRUNTIME140.dll_memmove
mov eax, dword [esp + 0x40]
add esp, 0xc
vmovdqu ymm0, ymmword [esp + 0x80]
mov edi, dword [esp + 0x1c]
mov ecx, dword [esp + 0x28]
vmovdqu ymmword [eax], ymm0
vmovq xmm0, qword [esp + 0x40]
vmovq qword [eax + 0x20], xmm0
mov dword [eax + 0x28], ecx
test dword [edi + 0xc], 0x400000
je 0x10040a08
mov ecx, dword [0x1006ef44]
vxorps xmm0, xmm0, xmm0
vcomiss xmm0, dword [ecx + 0x5a64]
jb 0x10040a08
mov eax, dword [ecx + 0x1c]
mov dword [ecx + 0x5a64], eax
mov eax, dword [edi + 0x60]
mov ecx, dword [esp + 0x20]
cmp eax, dword [edi + 0x14]
cmove ecx, eax
mov dword [esp + 0x20], ecx
mov dword [edi + 0x60], 0
mov eax, dword [edi + 0xc]
shr eax, 2
test al, 1
je 0x10040c16
mov esi, dword [0x1006ef44]
mov dword [esp + 0x80], 0
mov eax, dword [esi + 0x3e58]
lea ecx, [esi + 0x476c]
vmovss xmm1, dword [esi + 0x37c0]
vaddss xmm2, xmm1, dword [esi + 0x3bc4]
mov dword [esp + 0x28], eax
vmovss xmm0, dword [eax + 0xf0]
vmovss dword [esp + 0x34], xmm0
vmovss xmm0, dword [eax + 0xf4]
vmovss dword [esp + 0x40], xmm0
vmovss xmm0, dword [edi + 0x28]
vsubss xmm0, xmm0, xmm1
vmovss xmm1, dword [edi + 0x2c]
vmovss dword [eax + 0xf0], xmm0
vmovss dword [eax + 0xf4], xmm1
vaddss xmm0, xmm2, dword [edi + 0x28]
vmovss dword [edi + 0x28], xmm0
vmovdqu xmm0, xmmword [esi + 0x385c]
vmovdqa xmmword [esp + 0x70], xmm0
vshufps xmm0, xmm0, xmm0, 0xff
vmulss xmm0, xmm0, dword [0x100558e8]
vmovss dword [esp + 0x7c], xmm0
vmovdqu xmm0, xmmword [esi + 0x385c]
lea eax, [esp + 0x80]
vmovdqu xmmword [esp + 0x84], xmm0
push eax
vzeroupper
call fcn.10022080
vmovdqu xmm0, xmmword [esp + 0x70]
vmovdqu xmmword [esi + 0x385c], xmm0
mov esi, dword [0x1006ef44]
lea eax, [esp + 0x80]
push eax
mov dword [esp + 0x84], 0x15
vmovdqu xmm0, xmmword [esi + 0x39ac]
lea ecx, [esi + 0x476c]
vmovdqu xmmword [esp + 0x88], xmm0
call fcn.10022080
vxorps xmm0, xmm0, xmm0
push ecx
vmovdqu xmmword [esi + 0x39ac], xmm0
call fcn.100383b0
add esp, 4
mov byte [esp + 0x27], al
mov ecx, 2
call fcn.1000c4e0
xor ecx, ecx
mov dword [esp + 0x1c], ecx
cmp byte [esp + 0x27], cl
je 0x10040be9
mov dword [esp + 0x3c], ecx
cmp dword [edi], ecx
jle 0x10040be0
xor eax, eax
mov dword [esp + 0x18], eax
nop dword [eax]
mov esi, dword [edi + 8]
add esi, eax
test dword [esi + 4], 0x200000
jne 0x10040bd0
mov eax, dword [esi + 0x20]
cmp eax, 0xffffffff
jne 0x10040b8d
mov ecx, 0x10054fb0
jmp 0x10040b95
mov ecx, dword [edi + 0x8c]
add ecx, eax
mov eax, dword [edi + 0x14]
cmp eax, dword [esi]
lea eax, [esp + 0x68]
vxorps xmm0, xmm0, xmm0
push eax
sete dl
push ecx
vmovss dword [esp + 0x70], xmm0
vmovss dword [esp + 0x74], xmm0
call fcn.1003fb50
mov ecx, dword [esp + 0x24]
add esp, 8
test al, al
mov eax, dword [esp + 0x18]
cmovne ecx, esi
mov dword [esp + 0x1c], ecx
mov ecx, dword [esp + 0x3c]
inc ecx
add eax, 0x2c
mov dword [esp + 0x3c], ecx
mov dword [esp + 0x18], eax
cmp ecx, dword [edi]
jl 0x10040b70
call fcn.1001b880
mov ecx, dword [esp + 0x1c]
mov eax, dword [esp + 0x28]
vmovss xmm0, dword [esp + 0x34]
vmovss dword [eax + 0xf0], xmm0
vmovss xmm0, dword [esp + 0x40]
vmovss dword [eax + 0xf4], xmm0
test ecx, ecx
je 0x10040c16
mov eax, dword [ecx]
mov dword [esp + 0x20], eax
mov dword [edi + 0x14], eax
mov esi, dword [esp + 0x14]
mov ecx, dword [esp + 0xc0]
mov eax, dword [esp + 0xd8]
mov edx, dword [edi]
add eax, ecx
mov dword [esp + 0x78], ecx
mov ecx, dword [esi + 0x4a94]
mov dword [esp + 0x70], 0
mov dword [esp + 0x74], eax
mov dword [esp + 0x3c], edx
cmp edx, ecx
jle 0x10040cff
test ecx, ecx
je 0x10040c61
mov eax, ecx
cdq
sub eax, edx
mov edx, dword [esp + 0x3c]
sar eax, 1
add eax, ecx
jmp 0x10040c66
mov eax, 8
cmp eax, edx
mov ecx, edx
cmovg ecx, eax
mov dword [esp + 0x28], ecx
cmp ecx, dword [esi + 0x4a94]
jle 0x10040cff
mov eax, dword [0x1006ef44]
test eax, eax
je 0x10040c8c
inc dword [eax + 0xac]
lea eax, [ecx + ecx*2]
shl eax, 2
push eax
vzeroupper
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov edx, dword [esi + 0x4a98]
add esp, 4
mov dword [esp + 0x34], eax
test edx, edx
je 0x10040ceb
mov ecx, dword [esi + 0x4a90]
lea ecx, [ecx + ecx*2]
shl ecx, 2
push ecx
push edx
push eax
call sub.VCRUNTIME140.dll_memcpy
mov ecx, dword [esi + 0x4a98]
add esp, 0xc
test ecx, ecx
je 0x10040cdd
mov eax, dword [0x1006ef44]
test eax, eax
je 0x10040cdd
dec dword [eax + 0xac]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, dword [esp + 0x38]
add esp, 4
mov edx, dword [esp + 0x3c]
mov dword [esi + 0x4a98], eax
mov eax, dword [esp + 0x28]
mov dword [esi + 0x4a94], eax
xor ecx, ecx
mov dword [esi + 0x4a90], edx
mov eax, dword [edi]
mov dword [esp + 0x3c], ecx
mov dword [esp + 0x18], 0xffffffff
mov byte [esp + 0x68], cl
mov dword [esp + 0x1c], ecx
test eax, eax
jle 0x10040e81
xor edx, edx
mov dword [esp + 0x40], edx
nop dword [eax + eax]
mov esi, dword [edi + 8]
add esi, edx
test ecx, ecx
je 0x10040d41
mov eax, dword [ecx + 0xc]
cmp eax, dword [esi + 0xc]
jge 0x10040d4f
test dword [esi + 4], 0x200000
cmove ecx, esi
mov dword [esp + 0x3c], ecx
mov eax, dword [esp + 0x68]
mov ecx, 1
mov edx, dword [esi]
cmp edx, dword [edi + 0x14]
movzx eax, al
cmove eax, ecx
mov ecx, dword [esp + 0x20]
mov dword [esp + 0x68], eax
test ecx, ecx
jne 0x10040d80
mov eax, dword [esp + 0x14]
cmp dword [eax + 0x47f8], edx
cmove ecx, edx
mov dword [esp + 0x20], ecx
mov eax, dword [esi + 0x20]
cmp eax, 0xffffffff
jne 0x10040d8f
mov edx, 0x10054fb0
jmp 0x10040d97
mov edx, dword [edi + 0x8c]
add edx, eax
mov eax, dword [esi + 4]
vmovss xmm1, dword [esi + 0x1c]
and eax, 0x100001
cmp eax, 0x100000
vxorps xmm0, xmm0, xmm0
setne al
vcomiss xmm1, xmm0
jae 0x10040dd1
push eax
lea ecx, [esp + 0xbc]
vzeroupper
call fcn.100426d0
add esp, 4
vxorps xmm0, xmm0, xmm0
vmovss xmm1, dword [eax]
mov eax, dword [esi + 4]
vmovss dword [esi + 0x18], xmm1
test al, 0x40
je 0x10040de1
xor edx, edx
jmp 0x10040dec
test al, 0x80
mov edx, 0
setne dl
inc edx
lea ecx, [edx + edx*2]
cmp edx, dword [esp + 0x18]
jne 0x10040e01
mov eax, dword [esp + 0x14]
vmovss xmm0, dword [eax + 0x37d4]
vaddss xmm0, xmm1, xmm0
vaddss xmm0, xmm0, dword [esp + ecx*4 + 0xc4]
vmovss dword [esp + ecx*4 + 0xc4], xmm0
mov ecx, dword [esp + edx*4 + 0x70]
mov dword [esp + 0x18], edx
lea eax, [ecx + 1]
mov dword [esp + edx*4 + 0x70], eax
lea ecx, [ecx + ecx*2]
mov eax, dword [esp + 0x14]
mov edx, dword [esp + 0x1c]
mov eax, dword [eax + 0x4a98]
mov dword [eax + ecx*4], edx
vmovss xmm0, dword [esi + 0x18]
vmovss dword [eax + ecx*4 + 8], xmm0
vmovss dword [eax + ecx*4 + 4], xmm0
vmovss xmm0, dword [esi + 0x18]
vmaxss xmm0, xmm0, dword [0x10055920]
mov ecx, edx
mov edx, dword [esp + 0x40]
inc ecx
add edx, 0x2c
vmovss dword [esi + 0x14], xmm0
mov eax, dword [edi]
cmp ecx, eax
mov dword [esp + 0x1c], ecx
mov ecx, dword [esp + 0x3c]
mov dword [esp + 0x40], edx
jl 0x10040d30
mov esi, dword [esp + 0x14]
vmovss xmm0, dword [esp + 0xc4]
vaddss xmm0, xmm0, dword [esp + 0xc8]
vxorps xmm2, xmm2, xmm2
vaddss xmm1, xmm0, xmm2
vmovss xmm0, dword [esp + 0xd0]
vaddss xmm0, xmm0, dword [esp + 0xd4]
vaddss xmm1, xmm1, xmm0
vmovss xmm0, dword [esp + 0xdc]
vaddss xmm0, xmm0, dword [esp + 0xe0]
vaddss xmm1, xmm1, xmm0
vmovss dword [edi + 0x44], xmm1
vmovss xmm0, dword [edi + 0x30]
vsubss xmm0, xmm0, dword [edi + 0x28]
vcomiss xmm1, xmm0
jbe 0x10040f12
cmp eax, 1
jle 0x10040f12
mov eax, dword [edi + 0xc]
test al, 0x10
jne 0x10040f12
test al, al
jns 0x10040f12
mov ecx, edi
vzeroupper
call fcn.10041860
mov ecx, eax
vxorps xmm2, xmm2, xmm2
test ecx, ecx
je 0x10040f12
test dword [ecx + 4], 0x200000
mov eax, dword [ecx]
mov dword [esp + 0x20], eax
jne 0x10040f12
mov dword [edi + 0x14], eax
vmovss xmm0, dword [esp + 0xc4]
vaddss xmm4, xmm0, dword [esp + 0xc8]
vmovss xmm0, dword [esp + 0xdc]
vaddss xmm5, xmm0, dword [esp + 0xe0]
vmovss xmm0, dword [edi + 0x30]
vsubss xmm3, xmm0, dword [edi + 0x28]
vaddss xmm1, xmm5, xmm4
vcomiss xmm3, xmm1
seta al
mov byte [esp + 0x27], al
test al, al
je 0x10040f77
vmovss xmm0, dword [esp + 0xd0]
vaddss xmm1, xmm0, dword [esp + 0xd4]
vsubss xmm0, xmm3, xmm4
vsubss xmm0, xmm0, xmm5
vsubss xmm0, xmm1, xmm0
vmaxss xmm2, xmm0, xmm2
jmp 0x10040f7b
vsubss xmm2, xmm1, xmm3
vcomiss xmm2, dword [0x10055920]
jb 0x100410a6
test byte [edi + 0xc], 0x40
jne 0x10040fc4
test al, al
jne 0x100410a6
mov edx, dword [esp + 0xd8]
add edx, dword [esp + 0xc0]
cmp byte [esp + 0x27], 0
mov dword [esp + 0x1c], edx
mov dword [esp + 0x18], edx
je 0x10040fe7
mov eax, dword [esp + 0xd8]
add eax, dword [esp + 0xc0]
jmp 0x10040fed
test al, al
je 0x10040f97
mov edx, dword [esp + 0xcc]
mov eax, dword [esp + 0xd8]
add eax, dword [esp + 0xc0]
mov dword [esp + 0x1c], edx
mov dword [esp + 0x18], edx
jmp 0x10040fed
xor eax, eax
mov dword [esp + 0x1c], edx
mov ecx, dword [esi + 0x4a98]
mov dword [esp + 0x40], eax
lea eax, [eax + eax*2]
shl eax, 2
mov dword [esp + 0x34], eax
add ecx, eax
vzeroupper
call fcn.100381a0
mov eax, dword [esp + 0x1c]
add eax, dword [esp + 0x40]
vxorps xmm3, xmm3, xmm3
cmp dword [esp + 0x40], eax
jge 0x100410aa
mov edx, dword [esp + 0x34]
nop word [eax + eax]
mov eax, dword [esi + 0x4a98]
vxorps xmm0, xmm0, xmm0
imul ecx, dword [edx + eax], 0x2c
vcvttss2si eax, dword [edx + eax + 4]
vcvtsi2ss xmm0, xmm0, eax
add ecx, dword [edi + 8]
vcomiss xmm3, xmm0
ja 0x1004109a
vmovss xmm1, dword [0x10055920]
mov eax, dword [ecx + 4]
vmaxss xmm2, xmm1, xmm0
test al, 0x40
je 0x10041068
xor eax, eax
jmp 0x10041073
test al, 0x80
mov eax, 0
setne al
inc eax
vmovss xmm0, dword [ecx + 0x14]
lea eax, [eax + eax*2]
vsubss xmm1, xmm0, xmm2
vmovss xmm0, dword [esp + eax*4 + 0xc4]
vsubss xmm0, xmm0, xmm1
vmovss dword [esp + eax*4 + 0xc4], xmm0
vmovss dword [ecx + 0x14], xmm2
add edx, 0xc
sub dword [esp + 0x18], 1
jne 0x10041030
jmp 0x100410aa
vxorps xmm3, xmm3, xmm3
xor ecx, ecx
mov dword [esp + 0x1c], 0
vmovaps xmm2, xmm3
vmovss dword [edi + 0x40], xmm3
mov dword [esp + 0x34], ecx
lea eax, [ecx + ecx*2]
shl eax, 2
lea edx, [esp + 0xc4]
add edx, eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x28], edx
cmp ecx, 2
jne 0x100410f5
vmovss xmm0, dword [edi + 0x30]
vsubss xmm0, xmm0, dword [edi + 0x28]
vsubss xmm0, xmm0, dword [edx]
vmaxss xmm0, xmm3, xmm0
vminss xmm2, xmm0, xmm2
jmp 0x100410f9
mov dword [esp + 0x28], edx
mov esi, dword [esp + eax + 0xc0]
xor edx, edx
test esi, esi
jle 0x10041166
imul eax, dword [esp + 0x1c], 0x2c
mov dword [esp + 0x40], eax
nop
mov ecx, dword [edi + 8]
add ecx, eax
mov eax, dword [esp + 0x18]
mov dword [ecx + 0x20], 0xffffffff
vmovss dword [ecx + 0x10], xmm2
mov esi, dword [esp + eax + 0xc0]
lea eax, [esi - 1]
cmp edx, eax
jge 0x10041141
mov eax, dword [esp + 0x14]
vmovss xmm1, dword [eax + 0x37d4]
jmp 0x10041145
vmovaps xmm1, xmm3
mov eax, dword [esp + 0x40]
inc edx
vaddss xmm0, xmm1, dword [ecx + 0x14]
add eax, 0x2c
mov dword [esp + 0x40], eax
vaddss xmm2, xmm0, xmm2
cmp edx, esi
jl 0x10041110
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x34]
vmovss xmm1, dword [esp + eax + 0xc8]
mov eax, dword [esp + 0x28]
inc ecx
add dword [esp + 0x1c], esi
mov dword [esp + 0x34], ecx
vaddss xmm2, xmm2, xmm1
vaddss xmm0, xmm1, dword [eax]
vmaxss xmm0, xmm0, xmm3
vaddss xmm0, xmm0, dword [edi + 0x40]
vmovss dword [edi + 0x40], xmm0
cmp ecx, 3
jl 0x100410c1
mov ecx, dword [edi + 0x88]
test ecx, ecx
jns 0x100411c8
mov eax, ecx
cdq
sub eax, edx
sar eax, 1
add eax, ecx
xor ecx, ecx
test eax, eax
cmovg ecx, eax
push ecx
lea ecx, [edi + 0x84]
vzeroupper
call fcn.10022510
vxorps xmm3, xmm3, xmm3
cmp byte [esp + 0x68], 0
mov dword [edi + 0x84], 0
jne 0x100411e0
mov dword [edi + 0x14], 0
mov eax, dword [edi + 0x14]
mov ecx, eax
test eax, eax
jne 0x100411ff
cmp dword [edi + 0x18], eax
jne 0x100411ff
mov eax, dword [esp + 0x3c]
test eax, eax
je 0x100411ff
mov eax, dword [eax]
mov ecx, eax
mov dword [edi + 0x14], eax
jmp 0x10041203
mov eax, dword [esp + 0x20]
mov dword [edi + 0x1c], ecx
mov byte [edi + 0x68], 0
test eax, eax
je 0x10041344
mov edx, dword [edi]
xor ecx, ecx
test edx, edx
jle 0x1004150d
mov esi, dword [edi + 8]
cmp dword [esi], eax
je 0x10041232
inc ecx
add esi, 0x2c
cmp ecx, edx
jl 0x10041221
jmp 0x1004150d
test esi, esi
je 0x1004150d
test byte [esi + 4], 0xc0
jne 0x1004150d
mov ecx, dword [0x1006ef44]
mov eax, 0x2e8ba2e9
vmovss xmm0, dword [edi + 0x30]
vsubss xmm0, xmm0, dword [edi + 0x28]
vsubss xmm0, xmm0, dword [esp + 0xc4]
vmovss xmm2, dword [ecx + 0x3bc4]
vsubss xmm0, xmm0, dword [esp + 0xdc]
vsubss xmm4, xmm0, dword [esp + 0xd4]
mov ecx, esi
sub ecx, dword [edi + 8]
imul ecx
mov eax, dword [esp + 0xc0]
sar edx, 3
dec eax
mov ecx, edx
shr ecx, 0x1f
add ecx, edx
mov dword [esp + 0x34], ecx
cmp ecx, eax
jle 0x100412a7
vxorps xmm1, xmm2, xmmword [0x10055d40]
jmp 0x100412ab
vmovaps xmm1, xmm3
mov ecx, dword [edi]
mov eax, dword [esp + 0x34]
vmovss xmm0, dword [esi + 0x10]
sub ecx, dword [esp + 0xd8]
inc eax
vsubss xmm5, xmm0, dword [esp + 0xc4]
vaddss xmm1, xmm1, xmm5
cmp eax, ecx
jl 0x100412d7
vmovss xmm2, dword [0x10055920]
vaddss xmm0, xmm5, dword [esi + 0x14]
vmovss xmm5, dword [edi + 0x4c]
vcomiss xmm5, xmm1
vaddss xmm2, xmm0, xmm2
vmovss dword [edi + 0x50], xmm3
ja 0x10041328
vsubss xmm0, xmm2, xmm1
vcomiss xmm0, xmm4
jae 0x10041328
mov ecx, dword [esp + 0x14]
vsubss xmm2, xmm2, xmm4
vcomiss xmm2, xmm5
jbe 0x10041511
vsubss xmm0, xmm1, xmm4
vsubss xmm0, xmm0, dword [edi + 0x48]
vmaxss xmm0, xmm0, xmm3
vmovss dword [edi + 0x50], xmm0
vmovss dword [edi + 0x4c], xmm2
jmp 0x10041511
vmovss xmm0, dword [edi + 0x48]
vsubss xmm0, xmm0, xmm2
vmaxss xmm0, xmm0, xmm3
vmovss dword [edi + 0x50], xmm0
vmovss dword [edi + 0x4c], xmm1
jmp 0x1004150d
test byte [edi + 0xc], 0x80
je 0x1004150d
mov edx, dword [0x1006ef44]
vmovss xmm2, dword [edi + 0x2c]
vmovss xmm0, dword [edi + 0x28]
vmovss xmm1, dword [edi + 0x34]
mov eax, dword [edx + 0x3e58]
vmovss xmm5, dword [edi + 0x30]
vmaxss xmm3, xmm0, dword [eax + 0x210]
vmaxss xmm4, xmm2, dword [eax + 0x214]
vminss xmm2, xmm1, dword [eax + 0x21c]
vminss xmm0, xmm5, dword [eax + 0x218]
vmovss xmm1, dword [edx + 0x37e4]
vaddss xmm6, xmm1, xmm0
vmovss xmm0, dword [edx + 0x37e8]
vaddss xmm5, xmm0, xmm2
vmovss xmm2, dword [edx + 0xdb8]
vsubss xmm1, xmm3, xmm1
vcomiss xmm2, xmm1
vsubss xmm3, xmm4, xmm0
jb 0x1004150d
vmovss xmm0, dword [edx + 0xdbc]
vcomiss xmm0, xmm3
jb 0x1004150d
vcomiss xmm6, xmm2
jbe 0x1004150d
vcomiss xmm5, xmm0
jbe 0x1004150d
mov edx, dword [edx + 0x47dc]
mov ecx, dword [esp + 0x14]
test edx, edx
je 0x1004143b
mov edx, dword [edx + 0x300]
test edx, edx
je 0x1004143b
cmp byte [edx + 0xab], 0
je 0x1004143b
mov eax, dword [ecx + 0x3e58]
mov eax, dword [eax + 0x300]
cmp edx, eax
je 0x1004143b
test dword [edx + 0xc], 0xc000000
je 0x1004143b
cmp dword [eax + 0x300], edx
je 0x1004143b
cmp eax, edx
je 0x1004143b
mov eax, dword [eax + 0x2fc]
test eax, eax
jne 0x10041428
jmp 0x10041511
mov dl, byte [ecx + 0x3725]
test dl, dl
je 0x1004144f
vmovss xmm0, dword [ecx + 0xdc8]
jmp 0x10041457
vmovss xmm0, dword [ecx + 0xdcc]
mov esi, dword [edi + 0x10]
xor eax, eax
test dl, dl
mov edx, esi
vmovss dword [esp + 0x34], xmm0
setne al
add eax, 0x286
mov dword [esp + 0x28], eax
mov ecx, eax
vzeroupper
call fcn.1001a1d0
test al, al
je 0x100414f3
vmovss xmm1, dword [esp + 0x34]
vxorps xmm4, xmm4, xmm4
vucomiss xmm1, xmm4
lahf
test ah, 0x44
jnp 0x100414f3
vmovss xmm0, dword [edi + 0x30]
vsubss xmm0, xmm0, dword [edi + 0x28]
vsubss xmm0, xmm0, dword [esp + 0xc4]
vsubss xmm0, xmm0, dword [esp + 0xdc]
vsubss xmm0, xmm0, dword [esp + 0xd4]
vmulss xmm0, xmm0, xmm1
vdivss xmm1, xmm0, dword [0x100559fc]
vmovss xmm0, dword [edi + 0x4c]
vsubss xmm2, xmm0, xmm1
vmovss xmm0, dword [edi + 0x30]
vmovss dword [edi + 0x50], xmm4
vsubss xmm1, xmm0, dword [edi + 0x28]
vmovss xmm0, dword [edi + 0x40]
vsubss xmm0, xmm0, xmm1
vminss xmm0, xmm2, xmm0
vmaxss xmm0, xmm0, xmm4
vmovss dword [edi + 0x4c], xmm0
mov edx, dword [esp + 0x28]
mov ecx, dword [0x1006ef44]
call fcn.1000b3b0
mov dword [eax + 4], esi
mov dword [eax], esi
mov word [eax + 8], 0
mov ecx, dword [esp + 0x14]
vmovss xmm5, dword [edi + 0x28]
vmovss xmm0, dword [edi + 0x30]
vmovss xmm2, dword [edi + 0x40]
vsubss xmm0, xmm0, xmm5
vsubss xmm1, xmm2, xmm0
vmovss xmm0, dword [edi + 0x48]
vminss xmm0, xmm0, xmm1
vxorps xmm3, xmm3, xmm3
vmaxss xmm4, xmm0, xmm3
vmovss dword [edi + 0x48], xmm4
vmovss xmm6, dword [edi + 0x30]
vsubss xmm0, xmm6, xmm5
vsubss xmm1, xmm2, xmm0
vmovss xmm0, dword [edi + 0x4c]
vminss xmm0, xmm0, xmm1
vmaxss xmm2, xmm0, xmm3
vucomiss xmm4, xmm2
vmovss dword [edi + 0x4c], xmm2
lahf
test ah, 0x44
jnp 0x10041602
vmovss xmm0, dword [ecx + 0x3bc4]
vmulss xmm1, xmm0, dword [0x10055aa0]
vmovss xmm0, dword [edi + 0x54]
mov eax, dword [edi + 0x24]
vmaxss xmm1, xmm0, xmm1
vsubss xmm0, xmm2, xmm4
vandps xmm0, xmm0, xmmword [0x10055d30]
vdivss xmm0, xmm0, dword [0x100558d8]
vmaxss xmm3, xmm1, xmm0
inc eax
vmovss dword [edi + 0x54], xmm3
cmp eax, dword [ecx + 0x3dd8]
jl 0x100415f7
vmovss xmm0, dword [ecx + 0x3bc4]
vmulss xmm1, xmm0, dword [0x10055a68]
vmovss xmm0, dword [edi + 0x50]
vcomiss xmm0, xmm1
ja 0x100415f7
vcomiss xmm2, xmm4
vmulss xmm0, xmm3, dword [ecx + 0x18]
jbe 0x100415e2
vaddss xmm0, xmm4, xmm0
vminss xmm4, xmm0, xmm2
vmovss dword [edi + 0x48], xmm4
jmp 0x10041607
vcomiss xmm4, xmm2
jbe 0x100415fb
vsubss xmm0, xmm4, xmm0
vmaxss xmm4, xmm0, xmm2
vmovss dword [edi + 0x48], xmm4
jmp 0x10041607
vmovaps xmm4, xmm2
vmovss dword [edi + 0x48], xmm4
jmp 0x10041607
vmovss dword [edi + 0x54], xmm3
vaddss xmm0, xmm5, dword [esp + 0xc4]
vaddss xmm0, xmm0, dword [esp + 0xc8]
mov eax, dword [edi + 0x28]
vmovss dword [edi + 0x58], xmm0
vsubss xmm0, xmm6, dword [esp + 0xdc]
vsubss xmm0, xmm0, dword [esp + 0xd4]
vmovss dword [edi + 0x5c], xmm0
mov esi, dword [ecx + 0x3e58]
mov ecx, dword [edi + 0x2c]
mov dword [esi + 0xf4], ecx
lea ecx, [esp + 0x34]
mov dword [esi + 0xf0], eax
vmovss xmm0, dword [edi + 0x40]
vmovss xmm1, dword [edi + 0x78]
vmovss dword [esp + 0x34], xmm0
vmovss xmm0, dword [edi + 0x34]
vsubss xmm0, xmm0, dword [edi + 0x2c]
vmovss dword [esp + 0x38], xmm0
vzeroupper
call fcn.1001a380
vmovss xmm0, dword [edi + 0x44]
vaddss xmm1, xmm0, dword [edi + 0x28]
vmovss xmm0, dword [esi + 0x110]
mov ecx, dword [esp + 0x11c]
vmaxss xmm0, xmm0, xmm1
pop edi
vmovss dword [esi + 0x110], xmm0
pop esi
xor ecx, esp
call fcn.1004c44e
mov esp, ebp
pop ebp
ret