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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4c8210
mov eax, dword fs:[0]
push eax
sub esp, 0x40
push ebx
push esi
push edi
mov eax, dword [0x4f7f44]
xor eax, esp
push eax
lea eax, [esp + 0x50]
mov dword fs:[0], eax
mov ebx, dword [ebp + 8]
cmp dword [ebx + 0x54], 0
je 0x41d9c3
lea eax, [esp + 0x28]
lea ecx, [ebx + 0x44]
call fcn.00413a10
mov ecx, dword [eax]
test ecx, ecx
je 0x41d8dd
mov ecx, dword [ecx]
mov eax, dword [eax + 8]
mov edx, dword [ecx + 8]
cmp edx, eax
ja 0x41d8e9
sub eax, edx
mov ecx, dword [ecx + 4]
mov esi, dword [ecx + eax*4]
mov eax, dword [esi]
mov dword [esp + 0x34], eax
test eax, eax
je 0x41d905
push 1
add eax, 4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchangeAdd]
mov edx, dword [esi + 0xc]
mov ecx, dword [esi + 8]
mov eax, dword [esi + 0x10]
mov dword [esp + 0x40], edx
mov dl, byte [esi + 0x14]
mov dword [esp + 0x3c], ecx
mov dword [esp + 0x44], eax
mov byte [esp + 0x48], dl
mov dword [esp + 0x58], 0
cmp dword [ebx + 0x54], 0
je 0x41d97d
mov eax, dword [ebx + 0x50]
mov edx, dword [ebx + 0x48]
mov eax, dword [edx + eax*4]
mov esi, dword [eax]
test esi, esi
je 0x41d95f
push 0xffffffffffffffff
lea eax, [esi + 4]
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchangeAdd]
dec eax
jne 0x41d95b
test esi, esi
je 0x41d95b
mov edx, dword [esi]
mov eax, dword [edx]
push 1
mov ecx, esi
call eax
mov ecx, dword [esp + 0x3c]
inc dword [ebx + 0x50]
mov eax, dword [ebx + 0x50]
cmp dword [ebx + 0x4c], eax
ja 0x41d971
mov dword [ebx + 0x50], 0
dec dword [ebx + 0x54]
jne 0x41d97d
mov dword [ebx + 0x50], 0
or ecx, dword [esp + 0x40]
je 0x41d98e
lea ecx, [esp + 0x34]
mov edx, ebx
call fcn.0041dd50
mov dword [esp + 0x58], 0xffffffff
mov eax, dword [esp + 0x34]
test eax, eax
je 0x41d9b9
push 0xffffffffffffffff
add eax, 4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchangeAdd]
dec eax
jne 0x41d9b9
mov ecx, dword [esp + 0x34]
mov edx, dword [ecx]
mov eax, dword [edx]
push 1
call eax
cmp dword [ebx + 0x54], 0
jne 0x41d8c9
cmp dword [ebx + 0x6c], 0
je 0x41da19
mov eax, dword [ebx + 0x68]
mov ecx, dword [ebx + 0x60]
mov eax, dword [ecx + eax*4]
mov esi, dword [eax]
test esi, esi
je 0x41d9f5
push 0xffffffffffffffff
lea edx, [esi + 4]
push edx
call dword [sym.imp.KERNEL32.dll_InterlockedExchangeAdd]
dec eax
jne 0x41d9f5
test esi, esi
je 0x41d9f5
mov eax, dword [esi]
mov edx, dword [eax]
push 1
mov ecx, esi
call edx
inc dword [ebx + 0x68]
mov eax, dword [ebx + 0x68]
cmp dword [ebx + 0x64], eax
ja 0x41da07
mov dword [ebx + 0x68], 0
dec dword [ebx + 0x6c]
jne 0x41da13
mov dword [ebx + 0x68], 0
cmp dword [ebx + 0x6c], 0
jne 0x41d9c9
mov eax, dword [ebx + 0x74]
mov esi, dword [ebx + 0x78]
cmp eax, esi
setne cl
mov byte [esp + 0x17], cl
cmp eax, esi
jne 0x41da45
mov al, cl
mov ecx, dword [esp + 0x50]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov ebx, edi
mov al, byte [ebx + 0x84]
mov esi, dword [ebx + 0x78]
mov edi, dword [ebx + 0x74]
mov byte [esp + 0x20], al
mov ebx, esi
sub ebx, edi
mov eax, 0x2aaaaaab
imul ebx
sar edx, 2
mov ecx, edx
shr ecx, 0x1f
add ecx, edx
cmp ecx, 1
jle 0x41db5e
mov eax, dword [esi - 0x18]
mov dword [esp + 0x34], eax
test eax, eax
je 0x41da8a
push 1
add eax, 4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchangeAdd]
mov edx, dword [esi - 0x10]
mov eax, dword [esi - 0xc]
mov ecx, dword [esi - 8]
mov dword [esp + 0x3c], edx
mov dl, byte [esi - 4]
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], ecx
mov byte [esp + 0x48], dl
mov dword [esp + 0x58], 1
mov eax, dword [edi]
mov dword [esp + 0x1c], eax
test eax, eax
je 0x41dac4
push 1
add eax, 4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchangeAdd]
mov eax, dword [esi - 0x18]
mov dword [esp + 0x18], eax
test eax, eax
je 0x41daee
push 0xffffffffffffffff
add eax, 4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchangeAdd]
dec eax
jne 0x41daee
mov ecx, dword [esp + 0x18]
test ecx, ecx
je 0x41daee
mov eax, dword [ecx]
mov edx, dword [eax]
push 1
call edx
mov eax, dword [esp + 0x1c]
mov dword [esi - 0x18], eax
mov eax, dword [edi + 8]
mov ecx, dword [edi + 0xc]
mov dword [esi - 0x10], eax
mov eax, dword [esp + 0x20]
mov dword [esi - 0xc], ecx
mov ecx, dword [edi + 0x10]
push eax
mov dword [esi - 8], ecx
mov dl, byte [edi + 0x14]
lea ecx, [esp + 0x38]
push ecx
mov byte [esi - 4], dl
lea ecx, [ebx - 0x18]
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
push eax
push edi
call fcn.0041f520
mov dword [esp + 0x68], 0xffffffff
mov esi, dword [esp + 0x44]
add esp, 0x10
test esi, esi
je 0x41db5e
push 0xffffffffffffffff
lea ecx, [esi + 4]
push ecx
call dword [sym.imp.KERNEL32.dll_InterlockedExchangeAdd]
dec eax
jne 0x41db5e
mov edx, dword [esi]
mov eax, dword [edx]
push 1
mov ecx, esi
call eax
mov edi, dword [ebp + 8]
mov eax, dword [edi + 0x78]
cmp dword [edi + 0x74], eax
je 0x41db91
mov esi, dword [eax - 0x18]
test esi, esi
je 0x41db8d
push 0xffffffffffffffff
lea ecx, [esi + 4]
push ecx
call dword [sym.imp.KERNEL32.dll_InterlockedExchangeAdd]
dec eax
jne 0x41db8d
test esi, esi
je 0x41db8d
mov edx, dword [esi]
mov eax, dword [edx]
push 1
mov ecx, esi
call eax
add dword [edi + 0x78], 0xffffffe8
mov ecx, dword [edi + 0x74]
cmp ecx, dword [edi + 0x78]
jne 0x41da43
mov al, byte [esp + 0x17]
mov ecx, dword [esp + 0x50]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4