An independent Valve contractor has just assigned themselves the most daunting task yet: to make gaming viable on 8 GB GPUs.
With A Simple Trick, Valve Contractor Unlocked Smooth Gaming On 8 GB GPUs
Gaming on low-end GPUs, especially with 8 GB VRAM, is becoming harder and harder. With the majority of games releasing in unoptimized states these days, and the vast majority of PC gamers going for budget hardware as PC component prices rise, PC gaming is becoming harder for the general audience.
But it looks like someone who shares the same feelings as gamers these days has developed a brand new VRAM management tool to help low-end GPUs become viable again.
According to Natalie Vock, an independent contractor who works with Valve on RADV, the open-source Vulkan driver for AMD GPUs, it looks like gaming on 8 GB GPUs can be possible once more. Shared by Natalie on the Pixelcluster GPU blog, the developer shares how she has managed to fix the GPU VRAM dilemma.
It may sound unbelievable to some, but not everyone has a datacenter beast with 128GB of VRAM shoved in their desktop PCs. Around the world, people tell the tale of a particularly fierce group of Linux gamers: Those who dare attempt to play games with only 8 gigabytes of VRAM, or even less. Truly, it takes exceedingly strong resilience and determination to face the stutters and slowdowns bound to occur when the system starts running low on free VRAM. Carnage erupts inside the kernel driver as every application fights for as much GPU memory as it can hold on to. Any game caught up in this battle for resources will surely not leave unscathed.
That is, until now. Because I fixed it.
Natalie Vock - Pixelcluster GPU blog
The research first takes a look at what happens when running a game on a low-end GPU with 8 GB VRAM. It is stated that on a standard desktop PC, a browser running a few tabs will eat up a small portion of the GPU's VRAM along with a few other applications. Even before starting a game, 1/4th of the VRAM is already eaten up by these applications. And when running a game such as Cyberpunk 2077, almost the entirety of the 8 GB VRAM budget is consumed.
Desktop PCs also share memory resources between the GPU VRAM and the system memory, referred to as GTT. This memory is accessible to the GPU, but instead of running at the full bandwidth offered by the GPU, the data being sent over to the system ram is operated at a much lower speed (256 GB/s vs 16 GB/s) in the said example. This causes a slowdown. And Cyberpunk 2077 allocates 650 Megs to the GTT, but despite this allocation, the game still requested some memory allocations to the VRAM, which ended up in the GTT. This process is called "eviction".
The answer to eviction cases comes in the form of cgroups, which are useful for organizing random batches of processes into a single organizationall piece. They can set a limit for the RAM and the CPU. That's where the next step of cgroups comes in, called "dmem cgroup controller", written by Maarten, Maxime Ripard from Red Hat, and Natalie. With this, the kernel can offer memory protection as a means to protect from eviction. But further tuning had to be made, and with patches from Natalie, memory usage is handled much more aggressively.
The result can be seen when Cyberpunk 2077 is booted once again with the patches in place. Even with a bunch of heavy applications running in the background, the game doesn't allocate additional resources to the memory. And this makes gaming smoother and easily manageable on GPUs with 8 GB or even lower memory (6 GB).
Prioritization via cgroups now allows the game to use pretty much every last byte of VRAM for actual gaming purposes. It’s a bit hard to compare precise numbers on how the game performs, because the VRAM shortage slowly develops over time as you run around in the game, but the improvement should be obvious when comparing how games feel when you play them for a while. Instead of performance slowly degrading over time, games should perform much more stable - as long as the game itself doesn’t use more VRAM than you actually have. Generally, it seems like even modern games stay within a memory budget of ~8GB or a bit less, so if you have a GPU with 8GB of VRAM, you should be good to go with today’s games.
Natalie Vock - Pixelcluster GPU blog
Currently, dmem cgroups are compatible with AMD and Intel GPUs. NVIDIA doesn't support them due to their proprietary kernel modules. Also, iGPU support is up in the air, but the main problem is that they do not feature dedicated memory and rely on GTT (System Memory). But this patch may yield some benefits. So great work shared by Natalie, and we hope that these benefits roll down to actual games running on low-end GPUs.
Follow Wccftech on Google to get more of our news coverage in your feeds.
