This call returns the size of the largest block of free memory.
DosMemAvail
MemAvailSize (PULONG) - output
DosMemAvail allows an application to determine how heavily used system memory is at a particular time. The returned value is a "snapshot" that may be valid only at the moment this function is issued and can be expected to change at any time due to system activity.
This call can be used as an indicator for memory availability before a call to DosAllocHuge is made.