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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0x114
mov eax, dword [0x5d60c4]
xor eax, esp
mov dword [esp + 0x110], eax
mov edx, dword [ebp + 8]
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 0x18]
lea ebx, [edx + 0x70]
mov dword [esp + 0x4c], eax
mov eax, dword [ebp + 0x14]
push edi
push dword [ebp + 0x1c]
mov edi, dword [edx + 0xc]
add edi, dword [edx + 4]
mov dword [esp + 0x94], eax
mov dword [esp + 0x34], eax
add eax, esi
mov dword [esp + 0x40], eax
add eax, 0xfffffff8
push edx
mov dword [esp + 0x28], edx
mov dword [esp + 0x50], ecx
mov dword [esp + 0x64], ebx
mov dword [esp + 0x68], eax
call fcn.0050a410
mov dword [esp + 0xa4], eax
mov ecx, 0xfff
mov eax, dword [edx + 0xcc]
xorps xmm0, xmm0
cmp eax, ecx
movaps xmmword [esp + 0xd8], xmm0
movups xmmword [esp + 0xbc], xmm0
cmovb ecx, eax
mov dword [esp + 0xa0], 0
xor eax, eax
mov dword [esp + 0xa8], ecx
cmp dword [edx + 0xc8], 3
mov ecx, 0x5a69c0
push esi
setne al
mov dword [esp + 0x108], 0
add eax, 3
mov dword [esp + 0x100], 0
mov dword [esp + 0x58], eax
mov eax, dword [edx + 0x1c]
mov dword [esp + 0xa0], eax
mov eax, dword [edx + 0x84]
mov dword [esp + 0x20], eax
mov eax, dword [edx + 0x80]
mov dword [esp + 0x50], eax
mov eax, dword [edx + 0xd4]
test eax, eax
push 0
cmovne ecx, eax
mov dword [esp + 0x108], 0
mov eax, dword [ecx + 0x10]
movups xmm0, xmmword [ecx]
mov dword [esp + 0x100], eax
lea eax, [esp + 0xf0]
push eax
movups xmmword [esp + 0xf4], xmm0
call fcn.00509b40
push 0
push esi
mov esi, dword [esp + 0xac]
push esi
push ebx
call fcn.00509c20
xor ecx, ecx
add esp, 0x24
cmp esi, edi
sete cl
add ecx, esi
mov dword [esp + 0x28], ecx
cmp ecx, dword [esp + 0x60]
jae 0x508702
mov edi, dword [esp + 0x20]
nop dword [eax + eax]
push dword [esp + 0x4c]
mov esi, dword [esp + 0x48]
mov ebx, ecx
sub ebx, dword [esp + 0x34]
mov eax, 0
mov dword [esp + 0x3c], ebx
sete al
push eax
push dword [esp + 0x58]
lea eax, [esp + 0xa0]
push dword [esp + 0x48]
push ecx
push eax
push edi
push esi
call dword [esp + 0xbc]
mov edx, dword [esp + 0x48]
sub edx, dword [esp + 0xb0]
mov dword [esp + 0x44], eax
mov eax, dword [esp + 0x5c]
sub eax, dword [esp + 0x48]
push eax
push edx
lea eax, [esp + 0x4c]
mov dword [esp + 0xd0], edx
push eax
lea eax, [esp + 0x10c]
push esi
push eax
call fcn.00509a30
mov esi, dword [esp + 0x58]
add esp, 0x34
test esi, esi
jne 0x507bf1
mov ecx, dword [esp + 0x28]
inc ecx
mov dword [esp + 0x28], ecx
jmp 0x5086f8
mov edx, dword [esp + 0x14]
mov ecx, dword [esp + 0x50]
mov eax, dword [ecx]
mov dword [edx + 0x10], eax
mov eax, dword [ecx + 4]
mov dword [edx + 0x14], eax
mov eax, dword [ecx + 8]
mov dword [edx + 0x18], eax
lea eax, [edx + 0xc]
mov dword [edx + 8], 0
mov dword [eax], ebx
cmp dword [edi + 0xa8], 1
mov dword [esp + 0x2c], eax
jne 0x507c2e
lea eax, [ebx + 1]
bsr edx, eax
shl edx, 8
jmp 0x507c81
cmp ebx, 0x20000
jne 0x507c51
push 0
lea eax, [edi + 0x70]
push eax
push 0x1ffff
call fcn.00509980
add esp, 0xc
lea edx, [eax + 0x100]
jmp 0x507c81
cmp ebx, 0x3f
jbe 0x507c5e
bsr ecx, ebx
add ecx, 0x13
jmp 0x507c65
movzx ecx, byte [ebx + 0x5a69d8]
mov eax, dword [edi + 0x74]
movzx edx, byte [ecx + 0x5a6864]
mov eax, dword [eax + ecx*4]
inc eax
bsr eax, eax
sub edx, eax
shl edx, 8
add edx, dword [edi + 0x9c]
mov eax, dword [esp + 0x14]
mov dword [eax], edx
mov eax, dword [esp + 0x44]
mov ecx, dword [eax + esi*8 - 4]
cmp ecx, dword [esp + 0xa0]
jbe 0x507d2f
mov edx, dword [eax + esi*8 - 8]
movaps xmm2, xmmword [esp + 0xd0]
mov esi, dword [esp + 0x38]
mov dword [esp + 0xc0], ebx
mov dword [esp + 0xbc], ecx
mov dword [esp + 0xb8], edx
movups xmm1, xmmword [esp + 0xb4]
xor ebx, ebx
mov dword [esp + 0x18], ebx
lea eax, [ebx*8]
sub eax, ebx
mov ebx, dword [esp + 0x14]
movq xmm0, qword [ebx + eax*4 + 0x10]
lea eax, [ebx + eax*4]
test ecx, ecx
je 0x5084af
mov ecx, dword [eax + 0x18]
movq qword [esp + 0x78], xmm0
mov dword [esp + 0x80], ecx
cmp edx, 3
jbe 0x50846d
mov eax, dword [esp + 0x78]
mov ecx, dword [esp + 0x7c]
mov dword [esp + 0x7c], eax
lea eax, [edx - 3]
mov dword [esp + 0x78], eax
mov eax, dword [esp + 0x50]
movq xmm0, qword [esp + 0x78]
movq qword [eax], xmm0
mov dword [eax + 8], ecx
jmp 0x5084bd
cmp dword [edi + 0xa8], 1
jne 0x507d45
mov eax, 1
bsr ecx, eax
shl ecx, 8
jmp 0x507d59
mov eax, dword [edi + 0x74]
mov ecx, dword [edi + 0x9c]
mov eax, dword [eax]
inc eax
bsr eax, eax
shl eax, 8
sub ecx, eax
mov edi, dword [esp + 0x14]
lea ebx, [ecx + edx]
mov edx, dword [esp + 0x4c]
mov dword [esp + 0x1c], ebx
lea eax, [edi + 0x1c]
lea ecx, [edx - 1]
nop
mov dword [eax], 0x40000000
lea eax, [eax + 0x1c]
sub ecx, 1
jne 0x507d70
xor eax, eax
mov dword [esp + 0x40], eax
test esi, esi
je 0x507e8d
nop dword [eax]
mov ecx, dword [esp + 0x44]
mov ebx, dword [esp + 0x44]
mov ecx, dword [ecx + eax*8]
mov eax, dword [ebx + eax*8 + 4]
mov ebx, dword [esp + 0x1c]
mov dword [esp + 0x34], ecx
mov dword [esp + 0x54], eax
cmp edx, eax
ja 0x507e7c
lea eax, [edx*8]
sub eax, edx
lea edi, [edi + eax*4]
add edi, 4
mov eax, dword [esp + 0x20]
bsr esi, ecx
cmp dword [eax + 0xa8], 1
jne 0x507de4
lea eax, [edx - 2]
bsr eax, eax
add eax, 0x10
add eax, esi
shl eax, 8
add eax, ebx
jmp 0x507e57
mov eax, dword [eax + 0x7c]
mov ebx, esi
mov eax, dword [eax + esi*4]
inc eax
bsr eax, eax
sub ebx, eax
mov eax, dword [esp + 0x20]
shl ebx, 8
add ebx, dword [eax + 0xa4]
cmp esi, 0x14
jb 0x507e0f
shl esi, 9
add ebx, 0xffffda00
add ebx, esi
lea eax, [edx - 3]
cmp eax, 0x7f
jbe 0x507e1f
bsr ecx, eax
add ecx, 0x24
jmp 0x507e26
movzx ecx, byte [edx + 0x5a6a15]
mov esi, dword [esp + 0x20]
mov eax, dword [esi + 0x78]
mov eax, dword [eax + ecx*4]
movzx ecx, byte [ecx + 0x5a68d4]
inc eax
bsr eax, eax
sub ecx, eax
lea eax, [ebx + 0x33]
mov ebx, dword [esp + 0x1c]
shl ecx, 8
add ecx, dword [esi + 0xa0]
add ecx, dword [esp + 0x1c]
add eax, ecx
mov ecx, dword [esp + 0x34]
mov esi, dword [esp + 0x38]
mov dword [edi + 4], edx
inc edx
mov dword [edi], ecx
mov dword [edi + 8], esi
mov dword [edi - 4], eax
add edi, 0x1c
cmp edx, dword [esp + 0x54]
jbe 0x507dc2
mov esi, dword [esp + 0x24]
mov edi, dword [esp + 0x14]
mov eax, dword [esp + 0x40]
inc eax
mov dword [esp + 0x40], eax
cmp eax, esi
jb 0x507d90
lea ebx, [edx - 1]
mov esi, 1
mov dword [esp + 0x18], ebx
mov dword [esp + 0x24], esi
cmp ebx, esi
jb 0x508408
mov eax, dword [esp + 0x2c]
nop dword [eax]
cmp dword [eax - 4], 0
jne 0x507ebb
mov edi, dword [eax]
inc edi
jmp 0x507ec0
mov edi, 1
mov edx, dword [esp + 0x20]
cmp dword [edx + 0xb0], 2
jne 0x507ed7
mov ebx, 0x800
lea esi, [edx + 0x70]
jmp 0x507f1a
cmp dword [edx + 0xa8], 1
jne 0x507eea
mov ebx, 0x600
lea esi, [edx + 0x70]
jmp 0x507f1a
mov eax, dword [esp + 0x28]
mov ebx, dword [edx + 0x98]
movzx ecx, byte [eax + esi - 1]
mov esi, dword [esp + 0x5c]
lea edx, [ebx - 0x100]
mov eax, dword [esi]
mov eax, dword [eax + ecx*4]
inc eax
bsr eax, eax
shl eax, 8
cmp eax, edx
cmovbe edx, eax
sub ebx, edx
mov edx, dword [esp + 0x20]
cmp dword [edx + 0xa8], 1
jne 0x507f2e
lea eax, [edi + 1]
bsr esi, eax
shl esi, 8
jmp 0x507f82
cmp edi, 0x20000
jne 0x507f52
push 0
push esi
push 0x1ffff
call fcn.00509980
mov edx, dword [esp + 0x2c]
add esp, 0xc
lea esi, [eax + 0x100]
jmp 0x507f82
cmp edi, 0x3f
jbe 0x507f5f
bsr ecx, edi
add ecx, 0x13
jmp 0x507f66
movzx ecx, byte [edi + 0x5a69d8]
mov eax, dword [edx + 0x74]
movzx esi, byte [ecx + 0x5a6864]
mov eax, dword [eax + ecx*4]
inc eax
bsr eax, eax
sub esi, eax
shl esi, 8
add esi, dword [edx + 0x9c]
cmp dword [edx + 0xa8], 1
lea eax, [edi - 1]
jne 0x507f96
bsr ecx, edi
shl ecx, 8
jmp 0x507fe8
cmp eax, 0x20000
jne 0x507fb8
push 0
push dword [esp + 0x60]
push 0x1ffff
call fcn.00509980
add esp, 0xc
lea ecx, [eax + 0x100]
jmp 0x507fe8
cmp eax, 0x3f
jbe 0x507fc5
bsr ecx, eax
add ecx, 0x13
jmp 0x507fcc
movzx ecx, byte [eax + 0x5a69d8]
mov eax, dword [edx + 0x74]
mov eax, dword [eax + ecx*4]
movzx ecx, byte [ecx + 0x5a6864]
inc eax
bsr eax, eax
sub ecx, eax
shl ecx, 8
add ecx, dword [edx + 0x9c]
mov edx, dword [esp + 0x2c]
mov eax, dword [edx - 0xc]
sub eax, ecx
add eax, ebx
mov ebx, dword [edx + 0x10]
add eax, esi
cmp eax, ebx
jg 0x508012
mov dword [edx + 0x18], 0
mov ebx, eax
mov dword [edx + 0x14], 0
mov dword [edx + 0x1c], edi
mov dword [edx + 0x10], eax
mov edi, dword [edx + 0x18]
test edi, edi
je 0x5080a9
mov ecx, dword [esp + 0x24]
mov edx, dword [edx + 0x14]
sub ecx, edi
lea eax, [ecx*8]
sub eax, ecx
mov ecx, dword [esp + 0x14]
movq xmm0, qword [ecx + eax*4 + 0x10]
mov ecx, dword [ecx + eax*4 + 0x18]
movq qword [esp + 0x68], xmm0
mov dword [esp + 0x70], ecx
cmp edx, 3
jbe 0x508061
mov eax, dword [esp + 0x68]
mov ecx, dword [esp + 0x6c]
mov dword [esp + 0x6c], eax
lea eax, [edx - 3]
mov dword [esp + 0x68], eax
jmp 0x508095
mov esi, dword [esp + 0x2c]
xor eax, eax
cmp dword [esi + 0x1c], eax
sete al
dec eax
add eax, edx
je 0x508095
mov esi, dword [esp + 0x68]
cmp eax, 3
jne 0x508080
lea edx, [esi - 1]
jmp 0x508089
mov edx, dword [esp + eax*4 + 0x68]
cmp eax, 2
jb 0x50808d
mov ecx, dword [esp + 0x6c]
mov dword [esp + 0x6c], esi
mov dword [esp + 0x68], edx
mov edx, dword [esp + 0x2c]
movq xmm0, qword [esp + 0x68]
movq qword [edx + 0x20], xmm0
mov dword [edx + 0x28], ecx
jmp 0x5080b9
movq xmm0, qword [edx + 4]
mov eax, dword [edx + 0xc]
movq qword [edx + 0x20], xmm0
mov dword [edx + 0x28], eax
mov esi, dword [esp + 0x28]
mov eax, dword [esp + 0x24]
add esi, eax
cmp esi, dword [esp + 0x60]
ja 0x508387
cmp eax, dword [esp + 0x18]
je 0x508404
lea eax, [ebx + 0x80]
cmp dword [edx + 0x2c], eax
jle 0x508387
xor edx, edx
test edi, edi
setne dl
test edi, edi
jne 0x5080fe
mov eax, dword [esp + 0x2c]
mov eax, dword [eax + 0x1c]
mov dword [esp + 0x38], eax
jmp 0x508106
mov dword [esp + 0x38], 0
mov edi, dword [esp + 0x20]
cmp dword [edi + 0xa8], 1
jne 0x508120
mov eax, 1
bsr ecx, eax
shl ecx, 8
jmp 0x508134
mov eax, dword [edi + 0x74]
mov ecx, dword [edi + 0x9c]
mov eax, dword [eax]
inc eax
bsr eax, eax
shl eax, 8
sub ecx, eax
push dword [esp + 0x4c]
lea eax, [ecx + ebx]
mov ebx, dword [esp + 0x48]
mov dword [esp + 0xa8], eax
mov eax, dword [esp + 0x30]
push edx
add eax, 0x20
push eax
push dword [esp + 0x48]
lea eax, [esp + 0xa4]
push esi
push eax
push edi
push ebx
call dword [esp + 0xbc]
mov edi, dword [esp + 0x44]
mov dword [esp + 0x60], eax
mov eax, dword [esp + 0x5c]
sub eax, esi
push eax
mov eax, dword [esp + 0xcc]
add eax, edi
push eax
lea eax, [esp + 0x68]
push eax
lea eax, [esp + 0x10c]
push ebx
push eax
call fcn.00509a30
mov edx, dword [esp + 0x74]
add esp, 0x34
test edx, edx
je 0x508387
mov ecx, dword [ebx + edx*8 - 4]
cmp ecx, dword [esp + 0xa0]
ja 0x5083a9
lea eax, [ecx + edi]
cmp eax, 0x1000
jae 0x5083a9
xor ecx, ecx
mov dword [esp + 0x34], ecx
test edx, edx
je 0x508387
lea eax, [ebx - 4]
mov edx, dword [eax + 4]
lea ebx, [eax + 8]
mov dword [esp + 0x64], ebx
mov ebx, dword [ebx]
mov dword [esp + 0x54], edx
test ecx, ecx
je 0x5081e9
mov eax, dword [eax]
inc eax
jmp 0x5081ed
mov eax, dword [esp + 0x4c]
mov dword [esp + 0x8c], eax
cmp ebx, eax
jb 0x508374
mov esi, dword [esp + 0x14]
lea ecx, [ebx + 0x5a6a15]
add edi, ebx
mov dword [esp + 0x1c], ecx
lea eax, [edi*8]
sub eax, edi
lea esi, [esi + eax*4]
mov eax, 0xfffffffe
sub eax, dword [esp + 0x24]
mov dword [esp + 0xac], eax
mov eax, 0xfffffffd
sub eax, dword [esp + 0x24]
mov dword [esp + 0x58], esi
mov dword [esp + 0xb0], eax
nop dword [eax]
mov eax, dword [esp + 0x20]
bsr edx, edx
cmp dword [eax + 0xa8], 1
jne 0x50826d
mov eax, dword [esp + 0xac]
add edx, 0x10
add eax, edi
bsr eax, eax
add edx, eax
shl edx, 8
add edx, dword [esp + 0xa4]
jmp 0x5082e7
mov eax, dword [eax + 0x7c]
mov esi, edx
mov eax, dword [eax + edx*4]
inc eax
bsr eax, eax
sub esi, eax
mov eax, dword [esp + 0x20]
shl esi, 8
add esi, dword [eax + 0xa4]
cmp edx, 0x14
jb 0x508298
shl edx, 9
add esi, 0xffffda00
add esi, edx
mov eax, dword [esp + 0xb0]
add eax, edi
cmp eax, 0x7f
jbe 0x5082ae
bsr ecx, eax
add ecx, 0x24
jmp 0x5082b5
mov eax, dword [esp + 0x1c]
movzx ecx, byte [eax]
mov edx, dword [esp + 0x20]
mov eax, dword [edx + 0x78]
mov eax, dword [eax + ecx*4]
movzx ecx, byte [ecx + 0x5a68d4]
inc eax
bsr eax, eax
sub ecx, eax
shl ecx, 8
add ecx, dword [edx + 0xa0]
mov edx, dword [esp + 0xa4]
add ecx, esi
mov esi, dword [esp + 0x58]
add edx, 0x33
add edx, ecx
mov eax, dword [esp + 0x18]
cmp edi, eax
ja 0x5082f5
cmp edx, dword [esi]
jge 0x50836c
jmp 0x508320
lea ecx, [eax + 1]
lea eax, [ecx*8]
sub eax, ecx
mov ecx, dword [esp + 0x14]
lea eax, [ecx + eax*4]
mov ecx, edi
sub ecx, dword [esp + 0x18]
mov dword [esp + 0x18], edi
mov dword [eax], 0x40000000
lea eax, [eax + 0x1c]
sub ecx, 1
jne 0x508312
mov esi, dword [esp + 0x14]
lea eax, [edi*8]
mov ecx, dword [esp + 0x14]
sub eax, edi
dec dword [esp + 0x1c]
dec edi
mov dword [esi + eax*4 + 8], ebx
dec ebx
mov esi, dword [esp + 0x54]
mov dword [ecx + eax*4 + 4], esi
mov esi, dword [esp + 0x38]
mov dword [ecx + eax*4 + 0xc], esi
mov esi, ecx
mov dword [esi + eax*4], edx
mov esi, dword [esp + 0x58]
mov edx, dword [esp + 0x54]
sub esi, 0x1c
mov dword [esp + 0x58], esi
cmp ebx, dword [esp + 0x8c]
jae 0x508240
mov ecx, dword [esp + 0x34]
mov edi, dword [esp + 0x24]
mov eax, dword [esp + 0x64]
inc ecx
mov dword [esp + 0x34], ecx
cmp ecx, dword [esp + 0x40]
jb 0x5081d0
mov esi, dword [esp + 0x24]
mov eax, dword [esp + 0x2c]
inc esi
mov ebx, dword [esp + 0x18]
add eax, 0x1c
mov dword [esp + 0x24], esi
mov dword [esp + 0x2c], eax
cmp esi, ebx
jbe 0x507eb0
jmp 0x508408
mov edx, dword [ebx + edx*8 - 8]
lea eax, [edi*8]
mov ebx, dword [esp + 0x14]
sub eax, edi
mov esi, dword [esp + 0x38]
mov dword [esp + 0xbc], ecx
mov dword [esp + 0xb8], edx
cmp dword [ebx + eax*4 + 8], 0
mov dword [esp + 0xc0], esi
jne 0x5083e0
mov eax, dword [ebx + eax*4 + 0xc]
jmp 0x5083e2
xor eax, eax
movups xmm1, xmmword [esp + 0xb4]
sub edi, eax
xor ebx, ebx
movaps xmm2, xmmword [esp + 0xd0]
cmp edi, 0x1000
cmovbe ebx, edi
jmp 0x507ccb
mov ebx, dword [esp + 0x18]
mov ecx, dword [esp + 0x14]
lea eax, [ebx*8]
sub eax, ebx
movups xmm1, xmmword [ecx + eax*4]
movq xmm2, qword [ecx + eax*4 + 0x10]
mov eax, dword [ecx + eax*4 + 0x18]
movaps xmm0, xmm1
psrldq xmm0, 8
movd ecx, xmm0
movaps xmm0, xmm1
psrldq xmm0, 0xc
movd esi, xmm0
mov dword [esp + 0x98], eax
movups xmmword [esp + 0xb4], xmm1
mov edx, dword [esp + 0xb8]
movaps xmmword [esp + 0xd0], xmm2
lea eax, [ecx + esi]
cmp ebx, eax
jbe 0x507cc9
sub ebx, ecx
sub ebx, esi
jmp 0x507ccb
xor eax, eax
test esi, esi
sete al
dec eax
add eax, edx
je 0x50849c
mov esi, dword [esp + 0x78]
cmp eax, 3
jne 0x508487
lea edx, [esi - 1]
jmp 0x508490
mov edx, dword [esp + eax*4 + 0x78]
cmp eax, 2
jb 0x508494
mov ecx, dword [esp + 0x7c]
mov dword [esp + 0x7c], esi
mov dword [esp + 0x78], edx
mov eax, dword [esp + 0x50]
movq xmm0, qword [esp + 0x78]
movq qword [eax], xmm0
mov dword [eax + 8], ecx
jmp 0x5084bd
mov ecx, dword [esp + 0x50]
movq qword [ecx], xmm0
mov eax, dword [eax + 0x18]
mov dword [ecx + 8], eax
mov edx, dword [esp + 0x18]
lea ecx, [edx + 1]
lea eax, [ecx*8]
mov dword [esp + 0x1c], ecx
sub eax, ecx
mov edi, ecx
lea esi, [ebx + eax*4]
mov eax, dword [esp + 0x98]
movups xmmword [esi], xmm1
movq qword [esi + 0x10], xmm2
mov dword [esi + 0x18], eax
test edx, edx
je 0x508569
jmp 0x5084f4
mov ebx, dword [esp + 0x14]
lea eax, [edx*8]
dec edi
sub eax, edx
lea esi, [esi - 0x1c]
movups xmm1, xmmword [ebx + eax*4]
lea edx, [ebx + eax*4]
mov ebx, edi
movq xmm0, qword [edx + 0x10]
movq qword [esp + 0x110], xmm0
movaps xmm0, xmm1
psrldq xmm0, 8
movd ecx, xmm0
movups xmm0, xmmword [edx]
psrldq xmm1, 0xc
movups xmmword [esi], xmm0
movq xmm0, qword [edx + 0x10]
movd eax, xmm1
movq qword [esi + 0x10], xmm0
add ecx, eax
mov eax, dword [edx + 0x18]
mov dword [esi + 0x18], eax
mov eax, dword [esp + 0x18]
sub eax, ecx
cmp ecx, dword [esp + 0x18]
sbb edx, edx
and edx, eax
mov dword [esp + 0x18], edx
ja 0x5084f0
mov ecx, dword [esp + 0x1c]
cmp ebx, ecx
ja 0x50869b
mov ebx, dword [esp + 0x14]
lea eax, [edi*8]
sub ecx, edi
sub eax, edi
lea ebx, [ebx + eax*4]
add ebx, 8
inc ecx
mov dword [esp + 0x1c], ecx
nop
mov edx, dword [esp + 0x30]
mov esi, dword [ebx + 4]
add edx, esi
mov edi, dword [ebx]
mov eax, dword [ebx - 4]
mov dword [esp + 0x34], edi
mov dword [esp + 0x64], eax
mov dword [esp + 0x28], edx
test edi, edi
je 0x50868b
push edi
push eax
push dword [esp + 0x38]
push esi
push dword [esp + 0x6c]
call fcn.0050a560
mov ecx, dword [esp + 0x50]
add esp, 0x14
mov edx, dword [esp + 0x48]
add ecx, 0xffffffe0
mov eax, dword [edx + 0xc]
cmp dword [esp + 0x28], ecx
ja 0x50871f
mov ecx, dword [esp + 0x30]
movups xmm0, xmmword [ecx]
movups xmmword [eax], xmm0
cmp esi, 0x10
jbe 0x508621
movups xmm0, xmmword [ecx + 0x10]
lea edx, [ecx + 0x10]
mov ecx, dword [esp + 0x48]
lea eax, [esi - 0x10]
mov ecx, dword [ecx + 0xc]
add ecx, 0x10
lea edi, [ecx + eax]
movups xmmword [ecx], xmm0
cmp eax, 0x10
jle 0x508619
add ecx, 0x10
add edx, 0x10
movups xmm0, xmmword [edx]
lea edx, [edx + 0x20]
movups xmmword [ecx], xmm0
movups xmm0, xmmword [edx - 0x10]
movups xmmword [ecx + 0x10], xmm0
add ecx, 0x20
cmp ecx, edi
jb 0x508601
mov edi, dword [esp + 0x34]
mov edx, dword [esp + 0x48]
add dword [edx + 0xc], esi
cmp esi, 0xffff
jbe 0x50863e
mov eax, dword [edx + 4]
sub eax, dword [edx]
sar eax, 3
mov dword [edx + 0x24], 1
mov dword [edx + 0x28], eax
mov eax, dword [edx + 4]
mov ecx, dword [esp + 0x64]
mov word [eax + 4], si
mov eax, dword [edx + 4]
mov dword [eax], ecx
lea ecx, [edi - 3]
cmp ecx, 0xffff
jbe 0x50866b
mov eax, dword [edx + 4]
sub eax, dword [edx]
sar eax, 3
mov dword [edx + 0x24], 2
mov dword [edx + 0x28], eax
mov eax, dword [edx + 4]
mov word [eax + 6], cx
lea eax, [edi + esi]
mov ecx, dword [esp + 0x30]
add dword [edx + 4], 8
add ecx, eax
mov dword [esp + 0x30], ecx
mov dword [esp + 0x28], ecx
mov ecx, dword [esp + 0x1c]
add ebx, 0x1c
sub ecx, 1
mov dword [esp + 0x1c], ecx
jne 0x508580
mov edi, dword [esp + 0x20]
cmp dword [edi + 0xb0], 2
je 0x5086bb
mov eax, dword [edi + 0x88]
inc eax
bsr eax, eax
shl eax, 8
mov dword [edi + 0x98], eax
mov eax, dword [edi + 0x8c]
inc eax
mov ecx, dword [esp + 0x28]
bsr eax, eax
shl eax, 8
mov dword [edi + 0x9c], eax
mov eax, dword [edi + 0x90]
inc eax
bsr eax, eax
shl eax, 8
mov dword [edi + 0xa0], eax
mov eax, dword [edi + 0x94]
inc eax
bsr eax, eax
shl eax, 8
mov dword [edi + 0xa4], eax
cmp ecx, dword [esp + 0x60]
jb 0x507b70
mov ecx, dword [esp + 0x11c]
mov eax, dword [esp + 0x3c]
sub eax, dword [esp + 0x30]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0052b789
mov esp, ebp
pop ebp
ret
push ecx
push dword [esp + 0x2c]
push dword [esp + 0x38]
push eax
call fcn.0050a270
add esp, 0x10
jmp 0x50861d