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

Disassembly:
push 0xffffffffffffffff
push 0x5fa3de
mov eax, dword fs:[0]
push eax
sub esp, 0x17c
mov eax, dword [0x667050]
xor eax, esp
mov dword [esp + 0x178], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x667050]
xor eax, esp
push eax
lea eax, [esp + 0x190]
mov dword fs:[0], eax
mov eax, dword [esp + 0x1a4]
mov ebx, dword [esp + 0x1a0]
mov dword [esp + 0x74], eax
mov ecx, dword [esp + 0x1a8]
mov edx, dword [esp + 0x1ac]
xor edi, edi
mov dword [esp + 0x198], edi
push 0x80000
mov dword [esp + 0x28], edi
mov dword [esp + 0x2c], edi
mov dword [esp + 0x90], ecx
mov dword [esp + 0x94], edx
mov dword [esp + 0x38], edi
xor ebp, ebp
mov dword [esp + 0x6c], edi
mov dword [esp + 0x58], 0x6124ac
mov dword [esp + 0x64], edi
call fcn.005e693a
add esp, 4
mov dword [esp + 0x5c], eax
mov dword [esp + 0x58], 0x80000
mov dword [esp + 0x3c], edi
mov dword [esp + 0x1c], 0xffffffff
mov eax, dword [esp + 0x1b0]
mov ecx, dword [esp + 0x1b4]
push 1
mov byte [esp + 0x19c], 2
push edi
mov dword [esp + 0x8c], eax
mov eax, dword [ebx + 0xb4]
push edi
lea esi, [esp + 0x88]
mov byte [esp + 0x27], 0
mov byte [esp + 0x26], 0
mov dword [esp + 0x88], edi
mov dword [esp + 0x8c], edi
mov dword [esp + 0x94], ecx
call fcn.0051ea00
test al, al
jne 0x515139
push 0x6111d4
lea ecx, [esp + 0xb8]
call dword [0x610498]
mov byte [esp + 0x198], 3
mov esi, dword [ebx]
add esi, 0x34
call dword [0x6103b0]
push eax
mov eax, dword [esi]
lea edx, [esp + 0xb8]
push edx
push 0x10000002
mov ecx, ebx
call eax
lea ecx, [esp + 0xb4]
mov byte [esp + 0x198], 2
call dword [0x6105a0]
mov eax, dword [esp + 0x1b4]
cmp eax, edi
mov ecx, dword [esp + 0x1b0]
ja 0x515161
cmp ecx, edi
jbe 0x5157d7
cmp eax, edi
jb 0x51516f
ja 0x515161
cmp ecx, 0x80000
jbe 0x51516f
mov ecx, 0x80000
mov dword [esp + 0x98], edi
jmp 0x515176
mov dword [esp + 0x98], eax
mov edx, dword [esp + 0x5c]
cmp edx, edi
mov eax, dword [ebx + 0xb4]
je 0x515854
cmp dword [eax], 0xffffffff
je 0x515854
push edi
lea esi, [esp + 0x40]
push esi
push ecx
mov dword [esp + 0x48], edi
mov ecx, dword [eax]
push edx
push ecx
call dword [0x610284]
test eax, eax
je 0x515854
mov eax, dword [esp + 0x3c]
cmp eax, edi
seta cl
test cl, cl
je 0x515854
sub dword [esp + 0x1b0], eax
mov dl, byte [ebx + 0x100]
sbb dword [esp + 0x1b4], edi
test dl, dl
jne 0x51590a
mov eax, dword [esp + 0x3c]
cmp eax, edi
mov dword [esp + 0x30], eax
mov dword [esp + 0x40], edi
mov dword [esp + 0x50], edi
jbe 0x5157a9
mov esi, dword [esp + 0x1b8]
lea ebx, [ebx]
mov eax, dword [ebx + 0x104]
cmp eax, edi
je 0x515218
mov eax, dword [eax + 4]
cmp eax, 0xffffffff
je 0x515218
push eax
call fcn.005e691c
mov eax, dword [esi]
mov edx, dword [eax + 4]
mov ecx, esi
mov byte [esp + 0x78], 0
call edx
xor ecx, ecx
cmp dword [esp + 0x1ac], ecx
jg 0x515241
jl 0x51523c
cmp dword [esp + 0x1a8], eax
ja 0x515241
mov byte [esp + 0x78], 1
mov ecx, dword [esp + 0x78]
mov eax, dword [esi]
push ecx
mov ecx, dword [esp + 0x34]
lea edx, [esp + 0x44]
push edx
mov edx, dword [esp + 0x64]
push ecx
mov ecx, dword [esp + 0x5c]
add edx, ecx
push edx
mov edx, dword [eax + 8]
mov ecx, esi
call edx
test al, al
je 0x51596e
mov eax, dword [esp + 0x40]
add dword [esp + 0x50], eax
sub dword [esp + 0x30], eax
mov eax, dword [esi]
mov edx, dword [eax + 0x10]
mov ecx, esi
call edx
test eax, eax
jbe 0x51579f
mov dword [esp + 0x20], edi
mov eax, dword [esi]
mov edx, dword [eax + 0x18]
lea ecx, [esp + 0x20]
push ecx
mov ecx, esi
call edx
cmp eax, edi
mov dword [esp + 0x94], eax
mov dword [esp + 0x44], edi
mov dword [esp + 0x48], edi
je 0x515796
mov eax, dword [esp + 0x20]
cmp eax, edi
jbe 0x515796
sub dword [esp + 0x1a8], eax
sbb dword [esp + 0x1ac], edi
lea esp, [esp]
mov esi, dword [esp + 0x74]
mov eax, esi
call fcn.004855a0
mov edx, dword [esp + 0x34]
cmp edx, eax
jae 0x515ac8
mov ecx, dword [esi + 4]
test ecx, ecx
je 0x5152fa
mov eax, dword [esi + 8]
sub eax, ecx
sar eax, 3
cmp edx, eax
jb 0x515300
call dword [0x6105e8]
mov edx, dword [esp + 0x34]
mov eax, esi
mov ecx, dword [eax + 4]
mov edi, dword [ecx + edx*8]
lea eax, [ecx + edx*8]
mov eax, dword [eax + 4]
test eax, eax
mov dword [esp + 0x6c], edi
mov dword [esp + 0x70], eax
je 0x51532a
add eax, 4
mov ecx, 1
lock xadd dword [eax], ecx
lea edx, [esp + 0xec]
push edx
mov byte [esp + 0x19c], 5
call fcn.00515b40
cmp byte [esp + 0x1b], 0
mov byte [esp + 0x198], 6
jne 0x5155d3
lea eax, [esp + 0x118]
push eax
call fcn.004d7a10
add esp, 4
test al, al
je 0x5154ac
mov eax, dword [esp + 0x11c]
mov esi, 8
cmp dword [esp + 0x130], esi
jae 0x515386
lea eax, [esp + 0x11c]
push eax
call dword [0x6101d0]
mov ecx, dword [esp + 0x11c]
and eax, 0xfffffffe
cmp dword [esp + 0x130], esi
jae 0x5153a7
lea ecx, [esp + 0x11c]
push eax
push ecx
call dword [0x6101c8]
cmp dword [esp + 0x130], esi
mov eax, dword [esp + 0x11c]
jae 0x5153c6
lea eax, [esp + 0x11c]
push eax
call dword [0x610200]
cmp eax, 1
je 0x5154ac
call dword [0x6103b0]
mov edx, dword [ebx]
mov edx, dword [edx + 0x30]
mov esi, eax
lea eax, [esp + 0x118]
push eax
push esi
mov ecx, ebx
call edx
test al, al
jne 0x515536
mov eax, dword [ebx]
mov edx, dword [eax + 0x34]
push esi
lea ecx, [esp + 0x11c]
push ecx
push 0x10000004
mov ecx, ebx
call edx
test al, al
jne 0x515536
lea eax, [esp + 0xec]
push eax
mov byte [esp + 0x19c], 5
call fcn.00512f10
mov byte [esp + 0x198], 2
mov esi, dword [esp + 0x70]
test esi, esi
je 0x515466
lea ecx, [esi + 4]
or edx, 0xffffffff
lock xadd dword [ecx], edx
jne 0x515466
mov eax, dword [esi]
mov edx, dword [eax + 4]
mov ecx, esi
call edx
lea eax, [esi + 8]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
jne 0x515466
mov edx, dword [esi]
mov eax, dword [edx + 8]
mov ecx, esi
call eax
mov eax, dword [esp + 0x1c]
cmp eax, 0xffffffff
je 0x515476
push eax
call dword [0x6103cc]
mov ecx, dword [esp + 0x5c]
push ecx
call fcn.005e6a6c
mov dword [esp + 0x19c], 0xffffffff
mov esi, dword [esp + 0x1c0]
add esp, 4
test esi, esi
je 0x515903
lea edx, [esi + 4]
or eax, 0xffffffff
lock xadd dword [edx], eax
jmp 0x5158e3
cmp byte [esp + 0x1a], 0
jne 0x51553b
mov eax, dword [esp + 0x14c]
mov ecx, dword [esp + 0x11c]
or eax, 0x8000000
cmp dword [esp + 0x130], 8
jae 0x5154db
lea ecx, [esp + 0x11c]
push 0
push eax
push 4
push 0
push 1
push 0x40000000
push ecx
call dword [0x6103ac]
cmp eax, 0xffffffff
mov dword [esp + 0x1c], eax
jne 0x51553b
call dword [0x6103b0]
mov esi, eax
mov eax, dword [ebx]
mov edx, dword [eax + 0x30]
lea ecx, [esp + 0x118]
push ecx
push esi
mov ecx, ebx
call edx
test al, al
jne 0x515536
mov eax, dword [ebx]
mov edx, dword [eax + 0x34]
push esi
lea ecx, [esp + 0x11c]
push ecx
push 0x10000001
mov ecx, ebx
call edx
test al, al
je 0x5159eb
mov byte [esp + 0x1a], 1
cmp dword [esp + 0x16c], 0
jne 0x51556d
cmp dword [esp + 0x170], 0
jne 0x51556d
mov eax, dword [esp + 0x154]
add dword [esp + 0x24], eax
mov ecx, dword [esp + 0x158]
mov ebp, eax
adc dword [esp + 0x28], ecx
mov dword [esp + 0x68], ecx
jmp 0x51559d
mov ebp, dword [esp + 0x8c]
sub ebp, dword [esp + 0x24]
mov eax, dword [esp + 0x90]
sbb eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x1ac]
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x1a8]
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], ecx
mov eax, dword [esp + 0x40]
mov edx, dword [ebx]
mov edx, dword [edx + 0x24]
push 0
push eax
lea ecx, [esp + 0xf4]
push ecx
mov ecx, ebx
mov byte [esp + 0x27], 1
call edx
mov ecx, dword [ebx + 0x104]
test ecx, ecx
je 0x5155d3
mov eax, dword [ecx]
mov eax, dword [eax + 8]
lea edx, [esp + 0xec]
push edx
call eax
xor ecx, ecx
cmp byte [esp + 0x1a], cl
mov dword [esp + 0x38], ecx
jne 0x515633
mov esi, dword [esp + 0x20]
cmp ebp, esi
jae 0x5155e9
mov esi, ebp
mov edx, dword [esp + 0x94]
mov eax, dword [esp + 0x44]
mov edi, dword [esp + 0x1c]
add eax, edx
cmp eax, ecx
je 0x515a4b
cmp edi, 0xffffffff
je 0x515a4b
push 0
lea ecx, [esp + 0x3c]
push ecx
push esi
push eax
push edi
call dword [0x610298]
test eax, eax
je 0x515a4b
mov eax, dword [esp + 0x38]
cmp esi, eax
jne 0x515a4b
xor ecx, ecx
jmp 0x515645
mov eax, dword [esp + 0x20]
cmp ebp, eax
mov edi, dword [esp + 0x1c]
jae 0x515641
mov eax, ebp
mov dword [esp + 0x38], eax
cmp ebp, eax
jne 0x515710
cmp dword [esp + 0x68], ecx
jne 0x515710
sub dword [esp + 0x20], eax
add dword [esp + 0x34], 1
add dword [esp + 0x44], eax
mov edx, dword [esp + 0x144]
mov eax, dword [esp + 0x148]
adc dword [esp + 0x48], ecx
cmp edi, 0xffffffff
mov ecx, dword [esp + 0x13c]
mov dword [esp + 0x9c], edx
mov edx, dword [esp + 0x140]
mov dword [esp + 0xa0], eax
mov eax, dword [esp + 0x134]
mov dword [esp + 0xac], ecx
mov ecx, dword [esp + 0x138]
mov dword [esp + 0xb0], edx
mov dword [esp + 0xa4], eax
mov dword [esp + 0xa8], ecx
je 0x5156f3
lea edx, [esp + 0x9c]
push edx
lea eax, [esp + 0xb0]
push eax
lea ecx, [esp + 0xac]
push ecx
push edi
call dword [0x6103c4]
push edi
call dword [0x6103cc]
test eax, eax
je 0x5156f3
mov dword [esp + 0x1c], 0xffffffff
mov edx, dword [ebx]
mov edx, dword [edx + 0x28]
lea eax, [esp + 0xec]
push eax
mov ecx, ebx
mov byte [esp + 0x1f], 0
mov byte [esp + 0x1e], 0
call edx
jmp 0x515722
sub ebp, eax
sbb dword [esp + 0x68], ecx
mov dword [esp + 0x20], ecx
mov dword [esp + 0x44], ecx
mov dword [esp + 0x48], ecx
lea eax, [esp + 0xec]
push eax
mov byte [esp + 0x19c], 5
call fcn.00512f10
mov byte [esp + 0x198], 2
mov esi, dword [esp + 0x70]
test esi, esi
je 0x515771
lea ecx, [esi + 4]
or edx, 0xffffffff
lock xadd dword [ecx], edx
jne 0x515771
mov eax, dword [esi]
mov edx, dword [eax + 4]
mov ecx, esi
call edx
lea eax, [esi + 8]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
jne 0x515771
mov edx, dword [esi]
mov eax, dword [edx + 8]
mov ecx, esi
call eax
cmp dword [esp + 0x20], 0
ja 0x5152d0
mov ecx, dword [esp + 0x40]
add dword [ebx + 0x110], ecx
mov esi, dword [esp + 0x1b8]
adc dword [ebx + 0x114], 0
xor edi, edi
mov edx, dword [esi]
mov eax, dword [edx + 0x1c]
mov ecx, esi
call eax
cmp dword [esp + 0x30], edi
ja 0x515200
mov eax, dword [esp + 0x1b4]
cmp eax, edi
mov ecx, dword [esp + 0x1b0]
ja 0x515161
cmp ecx, edi
ja 0x515153
mov eax, dword [esp + 0x1c]
cmp eax, 0xffffffff
je 0x5157d7
push eax
call dword [0x6103cc]
mov eax, dword [esp + 0x5c]
cmp eax, edi
je 0x5157e8
push eax
call fcn.005e6a6c
add esp, 4
mov dword [esp + 0x198], 0xffffffff
mov esi, dword [esp + 0x1bc]
cmp esi, edi
je 0x515828
lea ecx, [esi + 4]
or edx, 0xffffffff
lock xadd dword [ecx], edx
jne 0x515828
mov eax, dword [esi]
mov edx, dword [eax + 4]
mov ecx, esi
call edx
lea eax, [esi + 8]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
jne 0x515828
mov edx, dword [esi]
mov eax, dword [edx + 8]
mov ecx, esi
call eax
mov al, 1
mov ecx, dword [esp + 0x190]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x178]
xor ecx, esp
call fcn.005e693f
add esp, 0x188
ret 0x20
push 0x6111d4
lea ecx, [esp + 0xd4]
call dword [0x610498]
mov byte [esp + 0x198], 4
mov esi, dword [ebx]
add esi, 0x34
call dword [0x6103b0]
mov edx, dword [esi]
push eax
lea ecx, [esp + 0xd4]
push ecx
push 0x10000002
mov ecx, ebx
call edx
lea ecx, [esp + 0xd0]
mov byte [esp + 0x198], 2
call dword [0x6105a0]
mov eax, dword [esp + 0x1c]
cmp eax, 0xffffffff
je 0x5158b2
push eax
call dword [0x6103cc]
mov eax, dword [esp + 0x5c]
cmp eax, edi
je 0x5158c3
push eax
call fcn.005e6a6c
add esp, 4
mov dword [esp + 0x198], 0xffffffff
mov esi, dword [esp + 0x1bc]
cmp esi, edi
je 0x515903
lea eax, [esi + 4]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
jne 0x515903
mov edx, dword [esi]
mov eax, dword [edx + 4]
mov ecx, esi
call eax
lea ecx, [esi + 8]
or edx, 0xffffffff
lock xadd dword [ecx], edx
jne 0x515903
mov eax, dword [esi]
mov edx, dword [eax + 8]
mov ecx, esi
call edx
xor al, al
jmp 0x51582a
mov eax, dword [esp + 0x1c]
cmp eax, 0xffffffff
je 0x51591a
push eax
call dword [0x6103cc]
mov eax, dword [esp + 0x5c]
push eax
call fcn.005e6a6c
mov dword [esp + 0x19c], 0xffffffff
mov esi, dword [esp + 0x1c0]
add esp, 4
cmp esi, edi
je 0x515967
lea ecx, [esi + 4]
or edx, 0xffffffff
lock xadd dword [ecx], edx
jne 0x515967
mov eax, dword [esi]
mov edx, dword [eax + 4]
mov ecx, esi
call edx
lea eax, [esi + 8]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
jne 0x515967
mov edx, dword [esi]
mov eax, dword [edx + 8]
mov ecx, esi
call eax
xor al, al
jmp 0x51582a
mov eax, dword [esp + 0x84]
sub eax, dword [esp + 0x1b0]
mov ecx, dword [esp + 0x88]
sbb ecx, dword [esp + 0x1b4]
add eax, dword [esp + 0x7c]
mov edx, dword [ebx]
adc ecx, dword [esp + 0x80]
push ecx
push eax
mov eax, dword [edx + 0x38]
push 0x30000003
mov ecx, ebx
call eax
mov eax, dword [esp + 0x1c]
cmp eax, 0xffffffff
je 0x5159b5
push eax
call dword [0x6103cc]
mov ecx, dword [esp + 0x5c]
push ecx
call fcn.005e6a6c
mov dword [esp + 0x19c], 0xffffffff
mov esi, dword [esp + 0x1c0]
add esp, 4
cmp esi, edi
je 0x515903
lea edx, [esi + 4]
or eax, 0xffffffff
lock xadd dword [edx], eax
jmp 0x5158e3
lea eax, [esp + 0xec]
push eax
mov byte [esp + 0x19c], 5
call fcn.00512f10
mov byte [esp + 0x198], 2
mov esi, dword [esp + 0x70]
test esi, esi
je 0x515476
lea ecx, [esi + 4]
or edx, 0xffffffff
lock xadd dword [ecx], edx
jne 0x515476
mov eax, dword [esi]
mov edx, dword [eax + 4]
mov ecx, esi
call edx
lea eax, [esi + 8]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
jne 0x515476
mov edx, dword [esi]
mov eax, dword [edx + 8]
mov ecx, esi
call eax
jmp 0x515476
mov esi, dword [ebx]
add esi, 0x34
call dword [0x6103b0]
mov edx, dword [esi]
push eax
lea eax, [esp + 0x11c]
push eax
push 0x10000003
mov ecx, ebx
call edx
lea eax, [esp + 0xec]
push eax
mov byte [esp + 0x19c], 5
call fcn.00512f10
mov byte [esp + 0x198], 2
mov esi, dword [esp + 0x70]
test esi, esi
je 0x515ab9
lea ecx, [esi + 4]
or edx, 0xffffffff
lock xadd dword [ecx], edx
jne 0x515ab9
mov eax, dword [esi]
mov edx, dword [eax + 4]
mov ecx, esi
call edx
lea eax, [esi + 8]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
jne 0x515ab9
mov edx, dword [esi]
mov eax, dword [edx + 8]
mov ecx, esi
call eax
cmp edi, 0xffffffff
je 0x515476
push edi
jmp 0x515470
mov eax, dword [esp + 0x1c]
cmp eax, 0xffffffff
je 0x515ad8
push eax
call dword [0x6103cc]
mov eax, dword [esp + 0x5c]
push eax
call fcn.005e6a6c
mov dword [esp + 0x19c], 0xffffffff
mov esi, dword [esp + 0x1c0]
add esp, 4
test esi, esi
je 0x515903
lea ecx, [esi + 4]
or edx, 0xffffffff
lock xadd dword [ecx], edx
jne 0x515903
mov eax, dword [esi]
mov edx, dword [eax + 4]
mov ecx, esi
call edx
lea eax, [esi + 8]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
jne 0x515903
mov edx, dword [esi]
mov eax, dword [edx + 8]
mov ecx, esi
call eax
xor al, al
jmp 0x51582a