Linux, new patches improve VRAM management: better performance for 8 GB GPUs
Video memory management is one of the main limitations for modern gaming, especially on GPUs equipped with 8 GB of VRAM or less. With the increasing complexity of graphics, more recent titles require growing amounts of dedicated memory, putting pressure on systems that do not have sufficiently large buffers.
In this context, Natalie Vock's work, a developer from Valve involved in the development of the Linux graphics stack, comes into play. She proposed a series of kernel patches accompanied by user-space tools designed to optimize VRAM allocation.
The current behavior of the Linux kernel, under VRAM saturation conditions, can lead to suboptimal decisions: when video memory runs out, the system may move data related to the active game into system memory (via GTT, Graphics Translation Table), instead of freeing resources occupied by background applications. This approach introduces performance degradation, linked to the lower bandwidth and higher latency of RAM compared to VRAM. The result manifests as stuttering and instability in frame pacing.
Tests conducted with Cyberpunk 2077 on an 8 GB GPU highlight how the system can use over 1.3 GB of GTT memory, even though the game does not fully saturate the available VRAM.
The proposed patches introduce a new memory prioritization mechanism, allowing the operating system to identify and protect the foreground application, typically the game. The main component, called dmemcg-booster (Device Memory Control Groups), prevents game data from being "evicted" from VRAM. If necessary, it is the background processes that will be moved to system memory instead.
Alongside this is the plasma-foreground-booster, a tool designed for KDE environments, capable of automatically signaling which window should have priority in resource allocation. The initial results show improved use of available VRAM. In the case of Cyberpunk 2077, video memory usage increases from around 6 GB to over 7.4 GB, while GTT decreases from about 1.37 GB to around 650 MB. This does not imply a reduction in overall memory consumption, but rather a more efficient management of it. The main benefit is greater performance stability over time, especially in scenarios where VRAM is under greater pressure.
The patches are currently compatible with open-source drivers, particularly for AMD and Intel GPUs. Proprietary solutions, such as those from NVIDIA, do not support the necessary mechanisms to implement this type of memory control.
The changes are in the process of being integrated into some Linux distributions and are awaiting possible inclusion in the main kernel. The interest in this solution is also linked to potential applications in gaming on dedicated platforms, including configurations with hardware limited in terms of VRAM.