The &xcenter; "Memory" widget shows approximately how much physical RAM is left for applications to use. This is displayed in kilobytes (KB) and updated once a second.

The number displayed here is less than the amount of memory that applications can actually use. So if the number displayed here goes towards zero, this does not mean that your applications will not be able to allocate more memory. Instead, this widget displays how much physical memory can be allocated before the system would have to swap out other data to make room for a new allocation. So when this amount becomes too small, this only means that your swap file will probably have to be expanded.

Note that you can drag and drop fonts and colors onto the memory widget.

You can also double-click on the widget to have the "&os2; Kernel" object opened quickly, which, among other things, allows you to change the system's memory widget.

Implementation Details

Internally, this widget uses the Dos16MemAvail API, an old 16-bit API that is no longer documented by IBM.

The documentation for OS/2 1.3 says that this reports "the size of the largest block of free memory". This is obviously not true any more, since all 32-bit OS/2 versions (since 2.0) no longer allocate memory in blocks, but with 4 KB page granularity instead.

From my experience, this API now does indeed show the amount of free physical memory in the system, that is, the amount of RAM that is currently not used by OS/2, either because it has never been used or swapped out or released again by a process. (From my testing, this API returns the same values as Theseus does for the free physical RAM.) This free RAM can be used by applications immediately without &os2; having to make room by swapping out other memory pages.