System.GetMemoryMap

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

procedure GetMemoryMap(var AMemoryMap: TMemoryMap);

C++

extern DELPHI_PACKAGE void __fastcall GetMemoryMap(TMemoryMap &AMemoryMap);

Properties

Type Visibility Source Unit Parent
procedure
function
public
GETMEM.INC
System.hpp
System System

Description

Fetches the memory map.

GetMemoryMap returns a map of the address space of the process. For the purposes of the map, the entire 4GB address space is broken down into 64K chunks. There are 65536 such chunks. GetMemoryMap obtains a status value for each of them in the TMemoryMap array. The sum of the number of blocks with the status of csUnallocated multiplied by the chunk size (64K) gives an indication of how much more memory the application can allocate before it will run out of address space.



Status Value Description

csUnallocated

Free

csAllocated

In use by the process.

csReserved

Reserved for future use by the process.

csSysAllocated

In use by the operating system.

csSysReserved

Reserved for future use by the operating system.


See Also