Skip to content
Tech News
← Back to articles

Microsoft is working to eliminate PC gaming's "compiling shaders" wait times

read original get Shader Compilation Optimization Tool → more articles
Why This Matters

Microsoft's initiative to precompile shaders aims to significantly reduce the long wait times during game loading on PCs, enhancing the gaming experience by providing faster, console-like load times. This development is a major step toward improving performance consistency across diverse hardware configurations in the Windows ecosystem, benefiting both developers and gamers. By automating shader precompilation and updates, Microsoft is helping to streamline game optimization and reduce frustration caused by shader compilation delays.

Key Takeaways

Modern gamers are used to loading up a new game for the first time and being forced to wait multiple minutes while a “compiling shaders” step whirs away, optimizing advanced 3D effects for their specific hardware. This week at GDC, Microsoft provided some updates about its Advanced Shader Deliver for Windows efforts, which are designed to fix the problem by generating collections of precompiled shaders that can be downloaded ahead of time.

In a console environment, developers can optimize and precompile their graphics shaders to work well with a set driver and GPU environment. On PC, though, developers tend to leave their shaders as uncompiled code that can then be compiled and cached at runtime based on the specific hardware and drivers on the player’s machine.

Microsoft’s Advanced Shader Delivery infrastructure aims to fix this problem by automating the process of precompiling shaders that work across “a large matrix of drivers and GPUs in the Windows ecosystem,” as the company puts it. To enable that, developers use Microsoft’s Direct3D API to create a State Object Database (SODB) that represents in-game assets at the game engine level. That database of assets is then fed into multiple shader compilers to create a Precompiled Shader Database (PSDB) that supports multiple display adapters from different hardware vendors.

Credit: Nvidia An Nvidia graphic outlines the process of going from shader code to compiled shader. Credit: Nvidia An Nvidia graphic outlines the process of going from shader code to compiled shader.

That PSDB can then be downloaded alongside the game, providing what Microsoft calls “console-like load times across the hardware ecosystem” on PC. That PSDB can also be automatically updated when hardware vendors register a driver update, letting players download a new precompiled shader as a patch rather than recompiling locally every time their hardware drivers change.