Function at 0x10020560
Capabilities:
Get memory capacity

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10096a95
mov eax, dword fs:[0]
push eax
sub esp, 0x220
mov eax, dword [0x100c2354]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
push 0x3c
lea eax, [ebp - 0x8c]
mov dword [ebp - 0x90], 0x40
push 0
push eax
call fcn.1006a7b0
mov esi, dword [sym.imp.KERNEL32.dll_GlobalMemoryStatusEx]
lea eax, [ebp - 0x90]
add esp, 0xc
push eax
call esi
call fcn.1002ead0
mov ecx, eax
push 1
mov edx, dword [eax]
mov eax, dword [edx + 8]
call eax
movzx eax, al
sub eax, 1
jne 0x1002072c
push 0x73
push 0x1009e560
lea ecx, [ebp - 0xc4]
mov dword [ebp - 0xb4], eax
mov dword [ebp - 0xb0], 0xf
mov byte [ebp - 0xc4], al
call fcn.10009610
push 3
push 0x1009c854
lea ecx, [ebp - 0xac]
mov dword [ebp - 4], 0
mov dword [ebp - 0x9c], 0
mov dword [ebp - 0x98], 0xf
mov byte [ebp - 0xac], 0
call fcn.10009610
mov byte [ebp - 4], 1
call fcn.1002ead0
mov edi, eax
lea ecx, [ebp - 0x194]
push 0x1f
lea eax, [ebp - 0xc4]
push eax
lea eax, [ebp - 0xac]
push eax
call fcn.100046b0
mov esi, eax
push str._old_memorys_size:
push esi
mov byte [ebp - 4], 2
call fcn.10005890
add esp, 8
mov ecx, esi
push dword [ebp - 0x7c]
push dword [ebp - 0x80]
call fcn.10016680
mov eax, dword [edi]
mov ecx, edi
push esi
call dword [eax + 0x1c]
lea ecx, [ebp - 0x194]
call fcn.10006210
mov edx, dword [ebp - 0x98]
mov byte [ebp - 4], 0
cmp edx, 0x10
jb 0x100206ca
mov ecx, dword [ebp - 0xac]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x100206c0
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x10020bb4
push edx
push ecx
call fcn.1002fc08
add esp, 8
mov edx, dword [ebp - 0xb0]
mov dword [ebp - 0x9c], 0
mov dword [ebp - 0x98], 0xf
mov byte [ebp - 0xac], 0
mov dword [ebp - 4], 0xffffffff
cmp edx, 0x10
jb 0x10020726
mov ecx, dword [ebp - 0xc4]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x1002071c
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x10020bb9
push edx
push ecx
call fcn.1002fc08
add esp, 8
mov esi, dword [sym.imp.KERNEL32.dll_GlobalMemoryStatusEx]
push 2
call fcn.10007880
xor ebx, ebx
add esp, 4
test eax, eax
setne bl
test eax, eax
jne 0x10020aa6
push 0x3c
push eax
lea eax, [ebp - 0x4c]
mov dword [ebp - 0x50], 0x40
push eax
call fcn.1006a7b0
add esp, 0xc
lea eax, [ebp - 0x50]
push eax
call esi
push 0x3c
lea eax, [ebp - 0x4c]
mov dword [ebp - 0x50], 0x40
push 0
push eax
call fcn.1006a7b0
add esp, 0xc
lea eax, [ebp - 0x50]
push eax
call esi
mov ebx, dword [ebp - 0x40]
sub ebx, dword [ebp - 0x80]
mov esi, dword [ebp - 0x3c]
sbb esi, dword [ebp - 0x7c]
mov dword [ebp - 0xc8], ebx
mov dword [ebp - 0xcc], esi
js 0x10020891
jg 0x100207aa
cmp ebx, 0x40000000
jbe 0x10020891
call fcn.1002ead0
mov ecx, eax
push 1
mov edx, dword [eax]
mov eax, dword [edx + 8]
call eax
movzx eax, al
sub eax, 1
jne 0x10020a9d
push eax
push 0x40000000
push esi
push ebx
call fcn.100303c0
push 0x73
push 0x1009e560
lea ecx, [ebp - 0xac]
mov dword [ebp - 0x94], eax
mov ebx, edx
mov dword [ebp - 0x9c], 0
mov dword [ebp - 0x98], 0xf
mov byte [ebp - 0xac], 0
call fcn.10009610
push 3
push 0x1009c854
lea ecx, [ebp - 0xc4]
mov dword [ebp - 4], 3
mov dword [ebp - 0xb4], 0
mov dword [ebp - 0xb0], 0xf
mov byte [ebp - 0xc4], 0
call fcn.10009610
mov byte [ebp - 4], 4
call fcn.1002ead0
mov edi, eax
lea ecx, [ebp - 0x194]
push 0x2b
lea eax, [ebp - 0xac]
push eax
lea eax, [ebp - 0xc4]
push eax
call fcn.100046b0
mov esi, eax
push str._diff_size_GB_:
push esi
mov byte [ebp - 4], 5
call fcn.10005890
add esp, 8
mov ecx, esi
push ebx
push dword [ebp - 0x94]
call fcn.10016680
mov eax, dword [edi]
mov ecx, edi
push esi
call dword [eax + 0x1c]
jmp 0x10020a70
test esi, esi
jl 0x1002098e
jg 0x100208a7
cmp ebx, 0x100000
jbe 0x1002098e
call fcn.1002ead0
mov ecx, eax
push 1
mov edx, dword [eax]
mov eax, dword [edx + 8]
call eax
movzx eax, al
sub eax, 1
jne 0x10020a9d
push eax
push 0x100000
push esi
push ebx
call fcn.100303c0
push 0x73
push 0x1009e560
lea ecx, [ebp - 0xac]
mov dword [ebp - 0x94], eax
mov ebx, edx
mov dword [ebp - 0x9c], 0
mov dword [ebp - 0x98], 0xf
mov byte [ebp - 0xac], 0
call fcn.10009610
push 3
push 0x1009c854
lea ecx, [ebp - 0xc4]
mov dword [ebp - 4], 6
mov dword [ebp - 0xb4], 0
mov dword [ebp - 0xb0], 0xf
mov byte [ebp - 0xc4], 0
call fcn.10009610
mov byte [ebp - 4], 7
call fcn.1002ead0
mov edi, eax
lea ecx, [ebp - 0x194]
push 0x2d
lea eax, [ebp - 0xac]
push eax
lea eax, [ebp - 0xc4]
push eax
call fcn.100046b0
mov esi, eax
push str._diff_size_MB_:
push esi
mov byte [ebp - 4], 8
call fcn.10005890
add esp, 8
mov ecx, esi
push ebx
push dword [ebp - 0x94]
call fcn.10016680
mov eax, dword [edi]
mov ecx, edi
push esi
call dword [eax + 0x1c]
jmp 0x10020a70
call fcn.1002ead0
mov ecx, eax
push 1
mov edx, dword [eax]
mov eax, dword [edx + 8]
call eax
movzx eax, al
sub eax, 1
jne 0x10020a9d
push eax
push 0x400
push esi
push ebx
call fcn.100303c0
push 0x73
push 0x1009e560
lea ecx, [ebp - 0xac]
mov dword [ebp - 0x94], eax
mov ebx, edx
mov dword [ebp - 0x9c], 0
mov dword [ebp - 0x98], 0xf
mov byte [ebp - 0xac], 0
call fcn.10009610
push 3
push 0x1009c854
lea ecx, [ebp - 0xc4]
mov dword [ebp - 4], 9
mov dword [ebp - 0xb4], 0
mov dword [ebp - 0xb0], 0xf
mov byte [ebp - 0xc4], 0
call fcn.10009610
mov byte [ebp - 4], 0xa
call fcn.1002ead0
mov edi, eax
lea ecx, [ebp - 0x194]
push 0x2f
lea eax, [ebp - 0xac]
push eax
lea eax, [ebp - 0xc4]
push eax
call fcn.100046b0
mov esi, eax
push str._diff_size_KB_:
push esi
mov byte [ebp - 4], 0xb
call fcn.10005890
add esp, 8
mov ecx, esi
push ebx
push dword [ebp - 0x94]
call fcn.10016680
mov edx, dword [edi]
mov ecx, edi
push esi
call dword [edx + 0x1c]
lea ecx, [ebp - 0x194]
call fcn.10006210
lea ecx, [ebp - 0xc4]
call fcn.10005150
lea ecx, [ebp - 0xac]
call fcn.10005150
mov ebx, dword [ebp - 0xc8]
mov esi, dword [ebp - 0xcc]
mov eax, ebx
mov edx, esi
jmp 0x10020b98
call fcn.1002ead0
mov ecx, eax
push 2
mov edx, dword [eax]
mov eax, dword [edx + 8]
call eax
movzx eax, al
sub eax, 1
jne 0x10020b94
push 0x73
push 0x1009e560
lea ecx, [ebp - 0xfc]
mov dword [ebp - 0xec], eax
mov dword [ebp - 0xe8], 0xf
mov byte [ebp - 0xfc], al
call fcn.10009610
push 3
push 0x1009e22c
lea ecx, [ebp - 0xe4]
mov dword [ebp - 4], 0xc
mov dword [ebp - 0xd4], 0
mov dword [ebp - 0xd0], 0xf
mov byte [ebp - 0xe4], 0
call fcn.10009610
mov byte [ebp - 4], 0xd
call fcn.1002ead0
mov edi, eax
lea ecx, [ebp - 0x22c]
push 0x34
lea eax, [ebp - 0xfc]
push eax
lea eax, [ebp - 0xe4]
push eax
call fcn.100046b0
mov esi, eax
push str.OptimizeMemory
push esi
mov byte [ebp - 4], 0xe
call fcn.10005890
push str.__InternalOptMemory_failed._result:
push esi
call fcn.10005890
add esp, 0x10
mov ecx, esi
push ebx
call fcn.100202a0
mov eax, dword [edi]
mov ecx, edi
push esi
call dword [eax + 0x1c]
lea ecx, [ebp - 0x22c]
call fcn.10006210
lea ecx, [ebp - 0xe4]
call fcn.10005150
lea ecx, [ebp - 0xfc]
call fcn.10005150
xor eax, eax
xor edx, edx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.1002ff7e
mov esp, ebp
pop ebp
ret
call fcn.1006db89
call fcn.1006db89
int3