Function at 0x418160
Capabilities:
Get number of processors

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x456b10
mov eax, dword fs:[0]
push eax
sub esp, 0x1c
push ebx
push esi
push edi
mov eax, dword [0x47306c]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x20], esi
mov edi, dword [ebp + 8]
push edi
call fcn.00419240
mov ebx, eax
mov al, byte [ebx + 0x30]
test al, al
mov byte [ebp - 0xd], al
setne cl
cmp byte [ebx + 0x31], 0
mov byte [ebp - 0x14], cl
setne cl
cmp dword [esi + 0x60], 0
mov byte [ebp - 0x1c], cl
jne 0x4181d1
push dword [esi + 0x38]
push 0
push 0xc3a
call dword [0x4758c8]
lea ecx, [esi + 8]
mov dword [esi + 0x60], eax
call fcn.0041cd90
cmp dword [ebx + 8], 0x10000
jae 0x4181f5
mov eax, dword [ebx]
test eax, eax
je 0x4181ea
cmp eax, 6
je 0x4181ea
cmp eax, 7
jne 0x4181f5
sub esp, 0x10
mov ecx, esi
push edi
call fcn.0041a8d0
mov eax, dword [ebx]
cmp eax, 5
ja case.default.0x4182d7
jmp dword [eax*4 + 0x4186a4]
push edi
mov ecx, esi
call fcn.00419240
mov edx, eax
mov dword [ebp - 0x18], edx
mov eax, dword [edx + 8]
cmp eax, 0x10000
jae 0x4182cf
cmp byte [edx + 0x32], 0
je 0x418239
sub esp, 0x10
mov ecx, esi
push edi
call fcn.0041a8d0
mov edx, dword [ebp - 0x18]
mov eax, dword [edx + 8]
cmp eax, 0x10000
jae 0x4182cf
mov eax, dword [edx + 0x14]
mov edi, 0x7fffffff
test eax, eax
mov esi, 0x10000
cmovne edi, eax
mov eax, dword [edx + 0x10]
test eax, eax
cmovne esi, eax
sub esp, 0x18
lea eax, [edx + 0x34]
mov ecx, esp
push eax
call fcn.0040a140
push 0x60
push edi
push esi
mov esi, dword [ebp - 0x20]
push dword [ebp - 0x1c]
push 1
lea ecx, [esi + 0x68]
call fcn.0041b4a0
mov edi, dword [ebp - 0x18]
add eax, dword [edi + 0x18]
mov dword [edi + 8], eax
cmp eax, 0x10000
jae 0x4182cc
mov ecx, dword [edi + 0xc]
test ecx, ecx
je case.default.0x4182d7
mov eax, dword [esi + 0x6c]
test eax, eax
je 0x4182af
push 0x8000
push 0
push ecx
push dword [eax + 0x58]
call dword [0x4758dc]
mov dword [edi + 0xc], 0
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
mov edi, dword [ebp + 8]
mov eax, dword [ebx + 4]
cmp eax, 4
ja case.default.0x4182d7
jmp dword [eax*4 + 0x4186bc]
push 0
push dword [ebp - 0x14]
lea eax, [ebx + 0x2c]
mov ecx, esi
push eax
lea eax, [ebx + 0x4c]
push eax
lea eax, [ebx + 0x64]
push eax
lea eax, [ebx + 0xc]
push eax
push dword [ebx + 8]
call fcn.004186d0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
push 1
jmp 0x4182e0
cmp byte [ebx + 0x2c], 0
lea edi, [ebx + 0x2c]
push 0
lea eax, [ebx + 0x4c]
mov ecx, esi
jne 0x41832b
push dword [ebp - 0x14]
push edi
jmp 0x4182ec
push 0
push edi
push eax
lea eax, [ebx + 0x64]
mov byte [edi], 0
push eax
lea eax, [ebx + 0xc]
push eax
push dword [ebx + 8]
call fcn.004186d0
cmp byte [ebp - 0xd], 0
mov bl, al
mov byte [edi], 0
je 0x418354
xor cl, cl
call fcn.00414890
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
push edi
mov ecx, esi
call fcn.00419240
mov ebx, eax
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x24], 0
lea ecx, [ebx + 0x4c]
mov dword [ebp - 4], 0
lea edx, [ebp - 0x28]
call fcn.004148c0
cmp byte [ebx + 0x2c], 0
jne 0x4183b7
mov ecx, dword [ebp - 0x24]
test ecx, ecx
je 0x4183b7
mov edi, dword [ebp - 0x28]
mov edx, ecx
shr ecx, 2
mov eax, 0x90909090
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
lea eax, [ebp - 0x28]
push eax
push dword [ebx + 8]
lea ecx, [esi + 0x68]
call fcn.0041c230
test al, al
jne 0x4183ed
mov eax, dword [ebp - 0x28]
test eax, eax
je case.default.0x4182d7
cmp dword [ebp - 0x24], 0
jbe case.default.0x4182d7
push eax
call fcn.004350dd
add esp, 4
jmp case.default.0x4182d7
mov al, byte [ebx + 0x2c]
test al, al
mov byte [ebp + 0xb], al
sete al
cmp byte [ebp - 0xd], 0
mov byte [ebx + 0x2c], al
je 0x418423
push 0x40005
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
xor eax, eax
cmp byte [ebp + 0xb], al
sete al
add eax, 0x95
push eax
call dword [sym.imp.WINMM.dll_PlaySoundW]
mov eax, dword [ebp - 0x28]
test eax, eax
je 0x418439
cmp dword [ebp - 0x24], 0
jbe 0x418439
push eax
call fcn.004350dd
add esp, 4
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
push edi
mov ecx, esi
call fcn.00419240
mov edi, eax
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x24], 0
mov dword [ebp - 4], 1
lea edx, [ebp - 0x28]
cmp byte [edi + 0x2c], 0
mov eax, 0x64
mov ecx, 0x4c
cmove ecx, eax
add ecx, edi
call fcn.004148c0
lea eax, [ebp - 0x28]
push eax
push dword [edi + 8]
lea ecx, [esi + 0x68]
call fcn.0041c230
test al, al
je 0x4183ca
mov bl, byte [edi + 0x2c]
test bl, bl
sete al
cmp byte [ebp - 0xd], 0
mov byte [edi + 0x2c], al
je 0x418423
push 0x40005
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
xor eax, eax
test bl, bl
jmp 0x418414
push edi
mov ecx, esi
call fcn.00419240
push edi
mov ecx, esi
mov ebx, eax
call fcn.00419240
mov edi, eax
mov eax, dword [esi + 0x6c]
test eax, eax
je 0x41850a
push 0
push 4
lea ecx, [ebp - 0x18]
push ecx
push dword [edi + 8]
push dword [eax + 0x58]
call dword [0x4758cc]
test eax, eax
je 0x41850a
mov eax, dword [ebp - 0x18]
cmp eax, dword [edi + 0x1c]
sete al
jmp 0x418513
mov dword [ebp - 0x18], 0
xor al, al
mov byte [ebx + 0x2c], al
test al, al
jne 0x41851f
mov eax, dword [ebx + 0x1c]
jmp 0x418522
mov eax, dword [ebx + 0x20]
mov dword [ebp - 0x14], eax
mov eax, dword [esi + 0x6c]
test eax, eax
jne 0x418544
xor cl, cl
mov al, cl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
push 0
push 4
lea ecx, [ebp - 0x14]
push ecx
push dword [ebx + 8]
push dword [eax + 0x58]
call dword [0x4758d0]
test eax, eax
setne cl
mov byte [ebp - 0xe], cl
test eax, eax
je 0x41859e
mov al, byte [ebx + 0x2c]
test al, al
mov byte [ebp + 0xb], al
sete al
cmp byte [ebp - 0xd], 0
mov byte [ebx + 0x2c], al
je 0x41859e
push 0x40005
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
xor ecx, ecx
cmp byte [ebp + 0xb], cl
push eax
sete cl
add ecx, 0x95
push ecx
call dword [sym.imp.WINMM.dll_PlaySoundW]
mov cl, byte [ebp - 0xe]
mov al, cl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
sub esp, 8
lea ecx, [esi + 0x68]
push dword [ebp - 0x14]
push dword [ebx + 0x24]
push dword [ebx + 8]
call fcn.00419630
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
mov eax, dword [ebx + 0x28]
mov edi, dword [ebx + 8]
mov dword [ebp - 0x20], eax
mov eax, dword [esi + 0x6c]
test eax, eax
je case.default.0x4182d7
push 0
push 4
lea ecx, [ebp + 8]
mov dword [ebp + 8], 0
push ecx
push edi
push dword [eax + 0x58]
call dword [0x4758cc]
test eax, eax
je case.default.0x4182d7
mov eax, dword [ebp + 8]
lea ecx, [esi + 0x68]
add eax, dword [ebp - 0x20]
sub esp, 8
mov dword [ebp + 8], eax
push dword [ebp - 0x14]
push eax
push edi
call fcn.00419630
test al, al
setne al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
push edi
mov ecx, esi
call fcn.00419240
mov ecx, eax
cmp dword [ecx], 1
je 0x418658
mov dword [ecx], 1
mov bl, byte [ecx + 0x2c]
test bl, bl
sete al
cmp byte [ecx + 0x30], 0
mov byte [ecx + 0x2c], al
je 0x418439
push 0x40005
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
xor eax, eax
test bl, bl
sete al
add eax, 0x95
push eax
call dword [sym.imp.WINMM.dll_PlaySoundW]
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c