Function at 0x475480
Capabilities:
Get memory capacity

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x6c
mov eax, dword [0x519100]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ecx + 0x7c]
push esi
push edi
mov dword [ebp - 0x50], ebx
mov esi, dword [ebx + 0x10]
mov dword [ebp - 0x58], esi
test esi, esi
je 0x47570f
push 0x40
lea eax, [ebp - 0x48]
push 0
push eax
call fcn.00486ef0
add esp, 0xc
mov dword [ebp - 0x48], 0x40
lea eax, [ebp - 0x48]
push eax
call dword [sym.imp.KERNEL32.dll_GlobalMemoryStatusEx]
test eax, eax
je 0x4754da
mov edx, dword [ebp - 0x38]
mov edi, dword [ebp - 0x34]
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0x14]
jmp 0x4754f0
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x475513
mov ecx, dword [ebp - 0x5c]
mov eax, dword [ebp - 0x60]
mov edi, dword [ebp - 0x64]
mov edx, dword [ebp - 0x68]
test edi, edi
jne 0x4754fc
cmp edx, 0x6000000
jbe 0x475513
test ecx, ecx
jne 0x475507
cmp eax, 0x4000000
jbe 0x475513
add dword [ebx + 0x14], 0x1000000
jmp 0x47570f
xor ecx, ecx
mov eax, esi
mov edx, 4
mul edx
push 0x4ed614
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00484ca6
mov esi, eax
add esp, 8
mov dword [ebp - 0x54], esi
test esi, esi
jne 0x475552
lea eax, [esi + 8]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0048471b
mov esp, ebp
pop ebp
ret 8
xor edi, edi
cmp dword [ebx], edi
je 0x475582
xor ecx, ecx
cmp dword [ebx + 0xc], ecx
jbe 0x475704
xor edx, edx
mov eax, dword [ebx]
add eax, edx
cmp dword [eax], 0
je 0x475577
mov dword [esi + edi*4], eax
inc edi
cmp edi, dword [ebp - 0x58]
je 0x4755c6
inc ecx
add edx, 0xc
cmp ecx, dword [ebx + 0xc]
jb 0x475565
jmp 0x4755c6
mov esi, dword [ebx + 4]
test esi, esi
je 0x475704
mov esi, dword [esi]
mov eax, dword [esi]
mov dword [ebp - 0x4c], eax
cmp eax, esi
je 0x475704
mov ebx, dword [ebp - 0x54]
nop
add eax, 0x18
cmp dword [eax], 0
je 0x4755b1
mov dword [ebx + edi*4], eax
inc edi
cmp edi, dword [ebp - 0x58]
je 0x4755c0
lea ecx, [ebp - 0x4c]
call fcn.0043e270
mov eax, dword [ebp - 0x4c]
cmp eax, esi
jne 0x4755a0
mov ebx, dword [ebp - 0x50]
mov esi, dword [ebp - 0x54]
cmp edi, 1
jbe 0x475704
mov eax, dword [ebx]
test eax, eax
je 0x4755f2
cmp dword [eax], 0
je 0x4755de
add dword [eax + 8], 2
mov eax, dword [ebx + 0xc]
lea ecx, [eax + eax*2]
mov eax, dword [ebx]
cmp dword [eax + ecx*4 - 0xc], 0
je 0x4755f2
add dword [eax + ecx*4 - 4], 2
push 0x475440
push 4
push edi
push esi
call fcn.004a3560
mov eax, dword [ebx]
add esp, 0x10
test eax, eax
je 0x475626
cmp dword [eax], 0
je 0x475612
add dword [eax + 8], 0xfffffffe
mov eax, dword [ebx + 0xc]
lea ecx, [eax + eax*2]
mov eax, dword [ebx]
cmp dword [eax + ecx*4 - 0xc], 0
je 0x475626
add dword [eax + ecx*4 - 4], 0xfffffffe
mov eax, dword [ebx + 0x18]
mov edx, edi
mov ecx, dword [ebp - 0x54]
xor esi, esi
mov dword [ebp - 0x4c], eax
mov ebx, dword [ebp - 0x4c]
shr edx, 2
mov eax, dword [ecx + edi*4 - 4]
mov dword [ebp - 0x58], edx
cmp dword [eax + 4], ebx
mov ebx, dword [ebp - 0x50]
jbe 0x47566d
lea esi, [edi - 1]
test esi, esi
je 0x47566d
mov ebx, dword [ebp - 0x4c]
lea ecx, [ecx + esi*4]
add ecx, 0xfffffffc
mov eax, dword [ecx]
cmp dword [eax + 4], ebx
jbe 0x475667
sub ecx, 4
sub esi, 1
jne 0x475658
mov ebx, dword [ebp - 0x50]
mov ecx, dword [ebp - 0x54]
test edx, edx
je 0x4756b4
cmp esi, edi
sbb eax, eax
and esi, eax
mov eax, dword [ecx + esi*4]
mov dword [ebp - 0x4c], eax
mov eax, dword [eax]
test eax, eax
je 0x4756ac
push eax
call fcn.00484967
mov eax, dword [ebp - 0x4c]
add esp, 4
mov edx, dword [ebp - 0x58]
mov ecx, dword [ebp - 0x54]
mov dword [eax], 0
mov dword [eax + 8], 0
mov dword [eax + 4], 0
dec dword [ebx + 0x10]
sub edx, 1
mov dword [ebp - 0x58], edx
jne 0x475671
mov edi, dword [ebx + 4]
test edi, edi
je 0x475704
mov eax, dword [edi]
mov esi, dword [eax]
mov dword [ebp - 0x50], esi
cmp esi, eax
je 0x475704
cmp dword [esi + 0x18], 0
je 0x4756d9
lea ecx, [ebp - 0x50]
call fcn.0043e270
mov esi, dword [ebp - 0x50]
jmp 0x4756fd
lea ecx, [ebp - 0x4c]
mov dword [ebp - 0x4c], esi
call fcn.0043e270
push esi
mov ecx, edi
call fcn.00465c00
push 0x28
push eax
call fcn.00484729
mov esi, dword [ebp - 0x4c]
add esp, 8
mov dword [ebp - 0x50], esi
mov edi, dword [ebx + 4]
cmp esi, dword [edi]
jne 0x4756c6
push dword [ebp - 0x54]
call fcn.00484967
add esp, 4
mov ecx, dword [ebp - 4]
xor eax, eax
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0048471b
mov esp, ebp
pop ebp
ret 8