Function at 0x5a0820
Capabilities:
Access peb ldr_data
Get number of processors

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x64
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp + 8]
mov edx, 0xffffffff
cmp ecx, 0
sete bl
mov esi, dword [0x5ae2e4]
cmp eax, 0
sete bh
mov edi, esi
add edi, 0x23ac
mov dword [0x5ae2e8], edi
and bl, bh
test bl, 1
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x1c], edx
jne 0x5a0a8c
jmp 0x5a08ba
mov eax, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x24]
mov edx, dword [ecx]
mov esi, dword [ebp - 0x28]
cmp edx, esi
mov dword [ebp - 0x2c], edx
mov dword [ebp - 0x30], eax
je 0x5a0a7f
jmp 0x5a092e
xor eax, eax
mov dword [0x5ae2e4], 0x1bb2
mov dword [ebp - 0x1c], eax
jmp 0x5a0a8c
mov eax, dword [ebp - 0x10]
cmp eax, 0
setne cl
mov edx, dword [ebp - 0x34]
mov byte [ebp - 0x35], cl
mov dword [ebp - 0x2c], edx
jmp 0x5a092e
mov eax, dword [ebp - 0x18]
add eax, 0x1c8c
mov ecx, dword [ebp - 0x18]
add ecx, 0x155
mov dword [0x5ae2e8], eax
mov dword [0x5ae2e4], ecx
mov ecx, dword fs:[0x18]
mov eax, dword [0x5ae2e4]
add eax, 0xfffffead
mov dword [0x5ae2e8], eax
mov dword [0x5ae2e4], 0xaa5
mov eax, dword [ecx + 0x30]
mov dword [0x5ae2e8], 0x877
mov eax, dword [eax + 0xc]
mov ecx, eax
add ecx, 0x14
mov eax, dword [eax + 0x14]
mov dword [0x5ae2e4], 0x41ef
cmp eax, ecx
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x34], eax
je 0x5a0890
jmp 0x5a08a4
mov eax, dword [ebp - 0x2c]
mov ecx, eax
add ecx, 0x24
mov edx, dword [eax + 0x28]
mov esi, dword [eax + 0x10]
mov edi, dword [ebp - 0x10]
cmp esi, edi
sete bl
mov bh, byte [ebp - 0x35]
and bh, bl
test bh, 1
mov edi, eax
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x3c], ecx
mov dword [ebp - 0x40], edx
mov dword [ebp - 0x44], esi
mov dword [ebp - 0x48], edi
jne 0x5a0994
mov eax, 0x1179
mov ecx, dword [ebp - 0x3c]
mov dx, word [ecx]
shr dx, 1
movzx esi, dx
cmp dx, 0
mov dword [ebp - 0x4c], esi
mov dword [ebp - 0x20], eax
je 0x5a0872
xor eax, eax
mov ecx, 0x1179
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x54], ecx
jmp 0x5a09ae
mov eax, dword [ebp - 0x48]
add eax, 0xfffffff8
mov dword [0x5ae2e4], 0x1179
mov dword [ebp - 0x1c], eax
jmp 0x5a0a8c
mov eax, dword [ebp - 0x54]
mov ecx, dword [ebp - 0x50]
mov edx, dword [ebp - 0x40]
mov si, word [edx + ecx*2]
mov di, si
add di, 0xffbf
mov bx, si
add bx, 0x20
cmp di, 0x1a
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x5c], ecx
mov word [ebp - 0x5e], si
mov word [ebp - 0x60], bx
jb 0x5a09e8
mov ax, word [ebp - 0x5e]
mov word [ebp - 0x60], ax
mov ax, word [ebp - 0x60]
mov ecx, dword [ebp - 0x14]
mov edx, dword [ebp - 0x5c]
cmp word [ecx + edx*2], ax
sete bl
cmp ax, 0
sete bh
mov al, bl
xor al, 1
or bh, al
test bh, 1
mov al, bl
mov esi, dword [ebp - 0x58]
mov byte [ebp - 0x61], bl
mov byte [ebp - 0x62], al
mov dword [ebp - 0x68], esi
jne 0x5a0a46
mov eax, dword [ebp - 0x5c]
add eax, 1
mov ecx, dword [ebp - 0x58]
add ecx, 0xffffe887
mov edx, dword [ebp - 0x4c]
cmp eax, edx
mov esi, ecx
mov bl, byte [ebp - 0x61]
mov byte [ebp - 0x62], bl
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x54], esi
mov dword [ebp - 0x68], ecx
jb 0x5a09ae
mov eax, dword [ebp - 0x68]
mov cl, byte [ebp - 0x62]
mov dword [0x5ae2e8], 0x1bcb
test cl, 1
mov edx, eax
mov esi, dword [ebp - 0x44]
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x6c], eax
mov dword [ebp - 0x70], esi
jne 0x5a0a6e
jmp 0x5a0872
mov eax, dword [ebp - 0x70]
mov ecx, dword [ebp - 0x6c]
mov dword [0x5ae2e4], ecx
mov dword [ebp - 0x1c], eax
jmp 0x5a0a8c
mov eax, dword [ebp - 0x30]
mov dword [0x5ae2e4], eax
jmp 0x5a0890
mov eax, dword [ebp - 0x1c]
add esp, 0x64
pop esi
pop edi
pop ebx
pop ebp
ret