Function at 0x497ea0
Capabilities:
Get number of processors

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4c5d88
mov eax, dword fs:[0]
push eax
sub esp, 0x80
mov eax, dword [0x512000]
xor eax, esp
mov dword [esp + 0x78], eax
push ebx
push esi
push edi
mov eax, dword [0x512000]
xor eax, esp
push eax
lea eax, [esp + 0x90]
mov dword fs:[0], eax
mov esi, ecx
mov ebx, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
call fcn.0046c860
inc dword [0x53ea44]
xorps xmm0, xmm0
movq qword [esp + 0x80], xmm0
mov dword [esp + 0x84], 0
mov edx, dword [eax + 4]
add edx, 0x30
mov dword [esp + 0x80], vtable.CDirect3DDevice.0
mov dword [esp + 0x10], edx
mov dword [esp + 0x98], 0
mov eax, dword [esi + 0x38]
mov dword [esp + 0x4c], eax
test eax, eax
je 0x497f64
mov ecx, dword [eax + 4]
mov dword [eax], vtable.CDirect3DTexture.0
test ecx, ecx
je 0x497f50
mov eax, dword [ecx]
push ecx
call dword [eax + 8]
mov eax, dword [esp + 0x4c]
mov dword [eax + 4], 0
push eax
call fcn.004abef7
mov edx, dword [esp + 0x14]
add esp, 4
mov dword [esi + 0x38], 0
mov eax, dword [edx + 4]
test byte [eax + 0x44], 2
je 0x497fc4
mov edx, 2
mov dword [esp + 0x4c], edx
cmp ebx, edx
jle 0x497f8a
lea ebx, [ebx]
add edx, edx
cmp ebx, edx
jg 0x497f80
mov dword [esp + 0x4c], edx
add eax, 0x60
lea ecx, [esp + 0x4c]
cmp dword [eax], edx
mov edx, 2
cmovb ecx, eax
mov eax, dword [ecx]
mov dword [esi + 0x3c], eax
mov dword [esp + 0x4c], edx
cmp edi, edx
jle 0x497fb2
add edx, edx
cmp edi, edx
jg 0x497fa8
mov dword [esp + 0x4c], edx
mov eax, dword [esp + 0x10]
mov eax, dword [eax + 4]
add eax, 0x64
cmp dword [eax], edx
mov edx, dword [esp + 0x10]
jmp 0x497fe5
add eax, 0x60
mov dword [esp + 0x4c], ebx
lea ecx, [esp + 0x4c]
cmp dword [eax], ebx
cmovb ecx, eax
mov eax, dword [ecx]
mov dword [esi + 0x3c], eax
mov eax, dword [edx + 4]
add eax, 0x64
mov dword [esp + 0x4c], edi
cmp dword [eax], edi
lea ecx, [esp + 0x4c]
cmovb ecx, eax
mov eax, dword [ecx]
mov dword [esi + 0x40], eax
mov eax, dword [edx + 4]
test byte [eax + 0x44], 0x20
je 0x498021
mov edx, dword [esi + 0x40]
lea ecx, [esp + 0x4c]
mov eax, dword [esi + 0x3c]
cmp eax, edx
mov dword [esp + 0x48], eax
lea eax, [esp + 0x48]
cmovge ecx, eax
mov dword [esp + 0x4c], edx
mov edx, dword [esp + 0x10]
mov eax, dword [ecx]
mov dword [esi + 0x3c], eax
mov dword [esi + 0x40], eax
mov ecx, dword [esi + 0x3c]
cmp ecx, ebx
jl 0x49822f
cmp dword [esi + 0x40], edi
jl 0x49822f
push 0x53da70
push 0x34
call fcn.004abfa1
add esp, 8
mov dword [esp + 0x4c], eax
test eax, eax
je 0x498062
mov dword [eax + 4], 0
mov dword [eax], vtable.CDirect3DTexture.0
mov dword [eax + 0x30], 0
jmp 0x498068
xor eax, eax
mov dword [esp + 0x4c], eax
mov dword [esi + 0x38], eax
test eax, eax
jne 0x49813b
mov dword [esp + 0x7c], 0xf
mov dword [esp + 0x78], eax
mov byte [esp + 0x68], al
push edi
push ebx
push 0x5006d8
lea eax, [esp + 0x5c]
mov byte [esp + 0xa4], 3
push eax
lea eax, [esp + 0x78]
push eax
call fcn.00498d20
add esp, 0x14
mov dword [esp + 0x60], 0
cmp dword [esp + 0x64], 0x10
lea eax, [esp + 0x50]
cmovae eax, dword [esp + 0x50]
mov byte [eax], 0
cmp dword [esp + 0x64], 0x10
jb 0x4980d0
push dword [esp + 0x50]
call fcn.004abef7
add esp, 4
cmp dword [esp + 0x7c], 0x10
lea edx, [esp + 0x68]
mov dword [esp + 0x64], 0xf
cmovae edx, dword [esp + 0x68]
mov dword [esp + 0x60], 0
mov byte [esp + 0x50], 0
mov byte [esp + 0x98], 4
cmp byte [edx], 0
jne 0x498104
xor ecx, ecx
jmp 0x498119
mov ecx, edx
lea esi, [ecx + 1]
lea esp, [esp]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x498110
sub ecx, esi
push ecx
push edx
lea ecx, [esp + 0x58]
call fcn.0042add0
push 0x50ed00
lea eax, [esp + 0x54]
mov byte [esp + 0x9c], 3
push eax
call fcn.004aee7c
mov ecx, dword [0x53ea48]
test ecx, ecx
jne 0x49814c
mov eax, 0x80004005
jmp 0x498180
mov eax, dword [ecx]
lea edx, [esp + 0x48]
push 0
push edx
push 1
push 0x15
push 0
push 1
push dword [esi + 0x40]
push dword [esi + 0x3c]
push ecx
call dword [eax + 0x5c]
mov ecx, dword [esp + 0x4c]
push dword [esp + 0x48]
mov dword [esp + 0x14], eax
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [esp + 0x10]
test eax, eax
jns 0x498199
push eax
lea ecx, [esp + 0x18]
call fcn.00472490
push 0x50ee08
lea eax, [esp + 0x18]
push eax
call fcn.004aee7c
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0x24]
mov dword [esp + 0x98], 0xffffffff
mov dword [eax + 8], edi
imul edi, ebx
mov dword [eax], 0x28
mov dword [eax + 4], ebx
mov dword [eax + 0xc], 0x200001
mov dword [eax + 0x10], 0
shl edi, 2
dec dword [0x53ea44]
mov dword [eax + 0x14], edi
mov dword [eax + 0x18], 0
mov dword [eax + 0x1c], 0
mov dword [eax + 0x20], 0
mov dword [eax + 0x24], 0
jne 0x49820c
mov ecx, dword [0x53ea48]
test ecx, ecx
je 0x49820c
mov eax, dword [ecx]
push ecx
call dword [eax + 8]
mov dword [0x53ea48], 0
mov ecx, dword [esp + 0x90]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x78]
xor ecx, esp
call fcn.004abee8
mov esp, ebp
pop ebp
ret 8
mov dword [esp + 0x64], 0xf
mov dword [esp + 0x60], 0
mov byte [esp + 0x50], 0
mov byte [esp + 0x98], 1
mov eax, dword [edx + 4]
push dword [eax + 0x64]
push dword [eax + 0x60]
lea eax, [esp + 0x70]
push dword [esi + 0x40]
push ecx
push edi
push ebx
push 0x500690
push eax
lea eax, [esp + 0x70]
push eax
call fcn.00498d20
add esp, 0x24
mov dword [esp + 0x78], 0
cmp dword [esp + 0x7c], 0x10
lea eax, [esp + 0x68]
cmovae eax, dword [esp + 0x68]
mov byte [eax], 0
cmp dword [esp + 0x7c], 0x10
jb 0x49829e
push dword [esp + 0x68]
call fcn.004abef7
add esp, 4
cmp dword [esp + 0x64], 0x10
lea edx, [esp + 0x50]
mov dword [esp + 0x7c], 0xf
cmovae edx, dword [esp + 0x50]
mov dword [esp + 0x78], 0
mov byte [esp + 0x68], 0
mov byte [esp + 0x98], 2
cmp byte [edx], 0
jne 0x4982d2
xor ecx, ecx
jmp 0x4982e0
mov ecx, edx
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4982d7
sub ecx, esi
push ecx
push edx
lea ecx, [esp + 0x70]
call fcn.0042add0
push 0x50ed00
lea eax, [esp + 0x6c]
mov byte [esp + 0x9c], 1
push eax
call fcn.004aee7c
int3