Calculating Graphics Memory
The video memory manager must calculate the total amount of graphics memory before it can report an accurate account of graphics memory. The following list of items describes how the video memory manager calculates the graphics memory numbers:
Total system memory
Total amount of system memory that is accessible to the operating system. Memory that the BIOS allocates does not appear in this total-system-memory number. For example, a computer with a 1 GB DIMM (that is, 1024 MB) and that also has a BIOS that reserves 1 MB of memory appears to have 1023 MB of system memory.
Total system memory that is available for graphics use
Total amount of system memory that is dedicated or shared to the GPU. This number is calculated as follows:
TotalSystemMemoryAvailableForGraphics = MAX((TotalSystemMemory / 2), 64MB)
Commit limit on aperture segment
The amount of system memory that the video memory manager allows display miniport drivers to pin down (that is, the amount of system memory that display miniport drivers can memory map through an aperture segment) for GPU use at any given instant. The total amount of system memory that is allocated for the GPU might exceed the commit limit greatly; however, the video memory manager ensures that only up to a commit limit amount is actually resident in an aperture segment at any one time.
By default, the commit limit on a particular aperture segment is the size of that segment. The display miniport driver can specify a different commit limit in the CommitLimit member of the DXGK_SEGMENTDESCRIPTOR structure when the driver describes the segment. A commit limit that is specified in such a way applies only to the particular segment that the driver describes.
In addition to per-segment commit limit, there is a global commit limit on all aperture segments. This global commit limit is also referred to as shared system memory. This value is computed by the video memory manager. However, although the display miniport driver can reduce this value to a lower value in the ApertureSegmentCommitLimit member of the DXGK_DRIVERCAPS structure, we do not recommend this practice.
The video memory manager does not allow a display miniport driver to violate the per-segment commit limit nor the global commit limit. If a particular segment has a commit limit of 1 GB but the global commit limit is 256 MB, the video memory manager does not allow a display miniport driver to map more than 256 MB of system memory into that segment.
Dedicated video memory
Sum of the size of all memory segments for which the display miniport driver did not specify the PopulatedFromSystemMemory member in the DXGK_SEGMENTFLAGS structure for each segment.
Dedicated system memory
Sum of the size of all memory segments for which the display miniport driver specifies the PopulatedFromSystemMemory member in the DXGK_SEGMENTFLAGS structure for each segment. This number cannot be greater than the total system memory that is available for graphics use (TotalSystemMemoryAvailableForGraphics).
Shared system memory
The maximum amount of system memory that is shared to the GPU. This number is calculated as follows:
MaxSharedSystemMemory = TotalSystemMemoryAvailableForGraphics - DedicatedSystemMemory
The amount of system memory that is shared to the GPU. This number is calculated as follows:
SharedSystemMemory = MIN(MIN(SumOfCommitLimitOnAllApertureSegment, DXGK_DRIVERCAPS.ApertureSegmentCommitLimit), MaxSharedSystemMemory)
Total video memory
The total amount of video memory. This number is calculated as follows:
TotalVideoMemory = DedicatedVideoMemory + DedicatedSystemMemory + SharedSystemMemory