Function at 0x4a981c
Capabilities:
Get memory capacity

Disassembly:
sub esp, 0x104
mov ecx, dword [esp + 0x114]
mov dword [esp + 8], ebx
mov ebx, dword [esp + 0x10c]
mov dword [esp + 0xc], ebp
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], edi
mov dword [esp + 0x100], eax
movsx edx, byte [ecx + 0x508e50]
mov byte [esp + 0xfc], dl
movsx edi, dl
movsx esi, word [edi*2 + 0x503950]
mov ecx, dword [esp + 0x110]
lea edx, [eax + edi*4]
mov dword [ecx], esi
mov esi, dword [edx + 0xb4]
test esi, esi
mov dword [esp + 0x2c], esi
jne 0x4a9a8a
lea edi, [eax + edi*4]
cmp dword [edi + 0x100], 0
je 0x4a989e
mov dword [esp + 0x30], eax
push dword [esp + 0xfc]
mov eax, dword [esp + 0x34]
call fcn.004aad64
lea eax, [esp + 0x100]
call fcn.004a9c5c
xor al, 1
je 0x4a9a8a
mov ecx, 8
xor eax, eax
lea edi, [esp + 0x48]
rep stosd dword es:[edi], eax
lea ecx, [esp + 0x48]
push ecx
call sub.KERNEL32.DLL_GlobalMemoryStatus
mov eax, dword [esp + 0x60]
mov edx, 0xcccccccd
mul edx
shr edx, 4
cmp dword [esp + 0x64], edx
jb 0x4a99b9
mov edx, dword [esp + 0x100]
cmp dword [edx + 0xa0], 0
jne 0x4a991a
xor edi, edi
mov dword [esp + 0x1c], edi
mov esi, dword [edx + 0xf4]
mov dword [esp + 0x18], esi
fild qword [esp + 0x18]
fcomp dword [edx + 0xec]
fnstsw ax
sahf
jae 0x4a99b9
jp 0x4a99b9
mov ecx, dword [esp + 0x100]
mov dword [esp + 0x68], ecx
push 1
push 0
mov eax, dword [esp + 0x70]
call fcn.004aa0f4
test eax, eax
jne 0x4a9a43
mov esi, dword [esp + 0x100]
mov dword [esp + 0x6c], esi
push 0
mov eax, dword [esp + 0x70]
call fcn.004aaebc
mov ecx, 8
xor eax, eax
lea edi, [esp + 0x88]
rep stosd dword es:[edi], eax
lea ecx, [esp + 0x88]
push ecx
call sub.KERNEL32.DLL_GlobalMemoryStatus
mov eax, dword [esp + 0xa0]
mov edx, 0xcccccccd
mul edx
shr edx, 4
cmp dword [esp + 0xa4], edx
jae 0x4a9993
mov eax, dword [esp + 0x100]
call fcn.004a9674
mov edx, dword [esp + 0x100]
mov dword [esp + 0xa8], edx
push dword [esp + 0xfc]
mov eax, dword [esp + 0xac]
call fcn.004aad64
jmp 0x4a9a43
mov ecx, dword [esp + 0x100]
cmp dword [ecx + 0xf4], 0
je 0x4a9a43
mov eax, dword [esp + 0x100]
mov dword [esp + 0x28], eax
push 0
mov eax, dword [esp + 0x2c]
call fcn.004aaebc
mov ecx, 8
xor eax, eax
lea edi, [esp + 0xc8]
rep stosd dword es:[edi], eax
lea ecx, [esp + 0xc8]
push ecx
call sub.KERNEL32.DLL_GlobalMemoryStatus
mov eax, dword [esp + 0xe0]
mov edx, 0xcccccccd
mul edx
shr edx, 4
cmp dword [esp + 0xe4], edx
jae 0x4a9a22
mov eax, dword [esp + 0x100]
call fcn.004a9674
mov edx, dword [esp + 0x100]
mov dword [esp + 0xac], edx
push dword [esp + 0xfc]
mov eax, dword [esp + 0xb0]
call fcn.004aad64
lea eax, [esp + 0x100]
call fcn.004a9c5c
xor al, 1
je 0x4a9a8a
mov ecx, dword [esp + 0x100]
mov dword [esp + 0xe8], ecx
push 1
push 0
mov eax, dword [esp + 0xf0]
call fcn.004aa0f4
test eax, eax
je 0x4a9a85
lea eax, [esp + 0x100]
call fcn.004a9c5c
xor al, 1
je 0x4a9a8a
call fcn.004a8aa4
mov edx, dword [esp + 0x2c]
mov ecx, dword [edx]
movsx edx, byte [esp + 0xfc]
mov esi, dword [esp + 0x100]
lea edx, [esi + edx*4]
mov dword [edx + 0xb4], ecx
mov ecx, dword [esp + 0x2c]
mov edi, dword [ecx + 4]
mov edx, dword [esp + 0x2c]
mov ecx, dword [edi + 0x5c]
sub edx, dword [edi]
sar edx, cl
mov dword [esp + 0xf8], edx
mov edx, dword [edi + 0x14]
mov ecx, dword [esp + 0xf8]
btr dword [edx], ecx
test ebx, ebx
je 0x4a9c0a
mov esi, ecx
mov ebp, 1
and ecx, 0x1f
shr esi, 5
shl ebp, cl
mov eax, dword [esp + 0xf8]
test ebx, 0x20
je 0x4a9b3f
cmp dword [edi + 0x28], 0
jne 0x4a9b37
lea ecx, [edi + 0x24]
mov edx, dword [edi + 0x10]
mov dword [ecx + 4], edx
mov dword [esp + 4], 4
mov edx, dword [ecx + 4]
add edx, 0x1f
shr edx, 5
mov dword [esp + 0xf4], ecx
mov dword [esp], edx
call fcn.004ba190
mov ecx, dword [esp + 0xf4]
test eax, eax
mov dword [ecx], eax
je 0x4a9bf5
mov ecx, dword [edi + 0x24]
mov edx, ebp
or dword [ecx + esi*4], edx
test ebx, 1
je 0x4a9b8b
cmp dword [edi + 0x20], 0
jne 0x4a9b83
lea ecx, [edi + 0x1c]
mov edx, dword [edi + 0x10]
mov dword [ecx + 4], edx
mov dword [esp + 4], 4
mov edx, dword [ecx + 4]
add edx, 0x1f
shr edx, 5
mov dword [esp + 0xf0], ecx
mov dword [esp], edx
call fcn.004ba190
mov ecx, dword [esp + 0xf0]
test eax, eax
mov dword [ecx], eax
je 0x4a9bf5
mov ecx, dword [edi + 0x1c]
mov edx, ebp
or dword [ecx + esi*4], edx
test ebx, 2
je 0x4a9b9b
mov ecx, dword [edi + 0x2c]
mov edx, ebp
or dword [ecx + esi*4], edx
test ebx, 8
je 0x4a9bab
mov ecx, dword [edi + 0x34]
mov edx, ebp
or dword [ecx + esi*4], edx
cmp byte [edi + 0x58], 0
je 0x4a9c0a
test ebx, 0x10
je 0x4a9c0a
cmp dword [edi + 0x40], 0
jne 0x4a9c02
lea ecx, [edi + 0x3c]
mov edx, dword [edi + 0x10]
mov dword [ecx + 4], edx
mov dword [esp + 4], 4
mov edx, dword [ecx + 4]
add edx, 0x1f
shr edx, 5
mov dword [esp + 0xec], ecx
mov dword [esp], edx
call fcn.004ba190
mov ecx, dword [esp + 0xec]
test eax, eax
mov dword [ecx], eax
jne 0x4a9c02
call fcn.0046dbec
mov dword [esp], eax
call fcn.00463074
mov ecx, dword [edi + 0x3c]
mov edx, ebp
or dword [ecx + esi*4], edx
cmp byte [0x50f1c8], 0
je 0x4a9c3f
test ebx, 2
mov edx, dword [esp + 0x110]
mov esi, dword [edx]
jne 0x4a9c3f
push dword [esp + 0x2c]
mov eax, edi
push dword [esp + 0x118]
push esi
push dword [esp + 0x114]
push ebx
call fcn.004ae2a8
mov eax, dword [esp + 0x2c]
mov ebx, dword [esp + 8]
mov ebp, dword [esp + 0xc]
mov esi, dword [esp + 0x10]
mov edi, dword [esp + 0x14]
add esp, 0x104
ret 0x10