Support us on Patreon to keep GamingOnLinux alive. This ensures all of our main content remains free for everyone. Just good, fresh content! Alternatively, you can donate through PayPal. You can also buy games using our partner links for GOG and Humble Store.
We do often include affiliate links to earn us some pennies. See more here.

Epic Games devs talk about solutions to the Unreal Engine stuttering issues in games

By -
Last updated: 5 Feb 2025 at 11:15 am UTC

If you've played a game using Unreal Engine, or for that matter any modern game engine, you've likely encountered various forms of stuttering. One major issue is shader stuttering, as games build up that cache and it seems Epic Games have a solution for Unreal Engine.

We might finally see games eventually perform a lot better on PC.

Their blog post is highly technical but it's good to see Epic developers are working on solutions, and giving advice to developers on some best practices. In super-simple basic terms: when developers make games, the shaders used to render 3D images are written in a language that needs to be changed so your GPU can actually run it.

"Shader compilation stuttering happens when a render engine discovers that it needs to compile a new shader right before it uses it for drawing something, so everything stops while waiting for the driver to finish compilation." - Epic Games

The issue, as Epic say, is that going way back games didn't have as many shaders, and so this code translation wasn't much of an issue when running a game. But, games have grown a lot bigger and more complex resulting in all the stuttering.

"Rendering an object usually involves several shaders (e.g. a vertex shader and a pixel shader working together), as well as a number of other settings for the GPU: culling mode, blend mode, depth and stencil comparison modes etc. Together, these items describe the configuration, or state, of the GPU pipeline.

Older graphics APIs like Direct3D 11 and OpenGL allow for changing parts of the state individually and at arbitrary times, which means that the driver only sees the complete configuration when the game issues a draw request. Some settings influence the executable shader code, so there are cases when the driver can only start compiling shaders when the draw command is processed. This can take tens of milliseconds or more for a single draw command, resulting in very long frames when a shader is used for the first time—a phenomenon known to most gamers as hitching or stuttering.

Modern APIs require developers to package all the shaders and settings they will use for a draw request into a Pipeline State Object and set it as a single unit. Crucially, PSOs can be constructed at any time, so in theory engines can create everything they need sufficiently early (for example during loading), so that compilation has time to finish before rendering." - Epic Games

Making use of modern graphics APIs like Direct3D 12 and Vulkan with Pipeline State Objects (PSOs) is part of the solution. They even talk up Vulkan's Graphics Pipeline Library as a "good initiative". However, prior to Unreal Engine 5.2, they were suggesting developers run "automated level fly-throughs, and other such discovery methods" (like playing the game through) to build up a cache of the PSOs to bundle with the game (in a way, similar to Valve's shader precache system on Steam). The problem is, as they say, it has many limitations like being "resource-intensive and it must be kept up to date when content changes".

With Unreal Engine 5.2 they introduced a PSO precaching system, to enable developers to do a fair amount of this at game loading time. With GPU drivers saving these PSOs, they can be re-loaded and reduce loading time on subsequent game sessions and result in a smoother gameplay experience. This precache system is not finished though and still seeing lots of improvements:

"The precaching system has evolved a lot since its experimental introduction in 5.2 and it prevents most kinds of shader compilation stutters. However, it still has some coverage gaps and other limitations, so there are ongoing efforts to improve it further. We’re also working with hardware and software vendors to adapt drivers and graphics APIs to the way games use these systems in practice." - Epic Games

Epic ends the post with a few bits of useful advice for game developers on ensuring a smoother experience.

Article taken from GamingOnLinux.com.
3 Likes
About the author -
author picture
I am the owner of GamingOnLinux. After discovering Linux back in the days of Mandrake in 2003, I constantly checked on the progress of Linux until Ubuntu appeared on the scene and it helped me to really love it. You can reach me easily by emailing GamingOnLinux directly. You can also follow my personal adventures on Bluesky.
See more from me
You can also find comments for this article on social media: Mastodon
All posts need to follow our rules. For users logged in: please hit the Report Flag icon on any post that breaks the rules or contains illegal / harmful content. Guest readers can email us for any issues.
6 comments Subscribe

Doktor-Mandrake 6 hours ago
Thank the PC gods that epic are taking this seriously

And thank you Alex from digital foundry LOL
Ehvis 5 hours ago
View PC info
  • Supporter Plus
Thank the PC gods that epic are taking this seriously

But are they really? This is not exactly a new problem. In fact, I'd say the problem is as old as GPUs themselves. They just ignored it until it got so bad that it was actively affecting the perception of Epic.

Personally I think the problem is that shaders are not manually written anymore. And the ones generated by these engines are so complicated and allow so many combinations of conditional compilation that compilation effort got out of hand.
Doktor-Mandrake 5 hours ago
@Ehvis

Also I suppose have to ask, who's responsibility is it? Epic or the game developers, maybe abit of both? There's definitely some UE4 games that don't have shader stutter if the developers make it a priority, or at least minimise it

And even if shader stutter wasn't a thing, there's still things like traversal stutter and the constant streaming of assets that has been a hindrance too, bring back loading screens!
mr-victory 4 hours ago
> There’s a partial misconception that Direct3D 11 didn’t have these issues

Pre-GPL Apex Legends on Linux? Anyone?
Liam Dawe 3 hours ago
The Apex Legends issue on Linux was different though. You're running it on a system it wasn't even designed for.
tarmo888 3 hours ago
But are they really? This is not exactly a new problem. In fact, I'd say the problem is as old as GPUs themselves. They just ignored it until it got so bad that it was actively affecting the perception of Epic.

Personally I think the problem is that shaders are not manually written anymore. And the ones generated by these engines are so complicated and allow so many combinations of conditional compilation that compilation effort got out of hand.

Generated shaders are not as old as GPUs, but rather a new thing (last 10 years). Each those combinations (static switches) become a separate shader, so like the article says, it has become an issue because there are so many of those shaders to compile.

It isn't realistic anymore that all those shaders would be written manually, it would be waste of time.
While you're here, please consider supporting GamingOnLinux on:

Reward Tiers: Patreon. Plain Donations: PayPal.

This ensures all of our main content remains totally free for everyone! Patreon supporters can also remove all adverts and sponsors! Supporting us helps bring good, fresh content. Without your continued support, we simply could not continue!

You can find even more ways to support us on this dedicated page any time. If you already are, thank you!
Login / Register



Buy Games
Buy games with our affiliate / partner links: