That would work on consoles, where there are only a few hardware and software variations that need to be accounted for. It doesn't work on PC where there are far more variations that need individually compiled shaders.Surely the real solution to this problem is to just "install" the shaders during game updates? We've already solved the timing problem for downloading the update itself, so just have the software distribution platform trigger a post-update installation that compiles shaders.
So that’s why Atomic Heart is recompiling shaders nearly every time I run it. Driver updates.Unfortunately, Nvidia warns that users will still have to generate shaders in-game after downloading a title for the first time. The Auto Shader Compiler system only generates the new shaders needed after subsequent driver updates following that first run of a new title.
Yes, that's why I specify quote around "install". The game already includes everything it needs to compile shaders, so split that off into a headless app that can be run by Steam/EGS/etc. Then. The user can have a nice tickbox in their settings for "run post-update tasks automatically". If the feature is on, shader compilation is a silent feature as intrusive as game updates already are. If it's off, at least now the store itself can provide a consistent UI for the experience. The problem right now is most games that compile shaders on launch will be full screen at their menu while doing it. At least if it was a headless app Steam/etc. runs, I can do other things uninterrupted in the meantime.That would work on consoles, where there are only a few hardware and software variations that need to be accounted for. It doesn't work on PC where there are far more variations that need individually compiled shaders.
Edit: Unless by "install" you mean "compile"? In which case, shader compilation is a very resource intensive process, I don't miss the days when a random automatic update would slow my PC to a crawl while I'm using it. Such an update process would have to be carefully implemented to prevent issues.
The shaders are different for different graphics cards - and TIL even driver versions - so including all the possible permutations in the base install is a non-starter.Surely the real solution to this problem is to just "install" the shaders during game updates? We've already solved the timing problem for downloading the update itself, so just have the software distribution platform trigger a post-update installation that compiles shaders.
That would be handy. You can always alt-tab out of the game is doing its thing but being able to tell Steam or what have you to compile the shaders as part of the install process would be a boon.The problem right now is most games that compile shaders on launch will be full screen at their menu while doing it. At least if it was a headless app Steam/etc. runs, I can do other things uninterrupted in the meantime.
Sorry, shader compilation would not be a silent feature as intrusive as game updates already are, even if you optimize it to run slower it still takes a ton of memory.Yes, that's why I specify quote around "install". The game already includes everything it needs to compile shaders, so split that off into a headless app that can be run by Steam/EGS/etc. Then. The user can have a nice tickbox in their settings for "run post-update tasks automatically". If the feature is on, shader compilation is a silent feature as intrusive as game updates already are. If it's off, at least now the store itself can provide a consistent UI for the experience. The problem right now is most games that compile shaders on launch will be full screen at their menu while doing it. At least if it was a headless app Steam/etc. runs, I can do other things uninterrupted in the meantime.
The shaders are different for different graphics cards - and TIL even driver versions - so including all the possible permutations in the base install is a non-starter.
I suppose the publisher could pre-compile a number of different versions and let players download the appropriate one but it’s just much simpler to have everyone do their own. It’s not something that needs to be done very often.
Exactly, and this applies to any kind of post-update nonsense too. Some games strip away unused localization data, others might further decompress assets, whatever. I just find it frustrating how we went from software having an installer, whose entire job was to make the software ready to use, to store fronts which are just downloaders.That would be handy. You can always alt-tab out of the game is doing its thing but being able to tell Steam or what have you to compile the shaders as part of the install process would be a boon.
The Steam Deck does exactly this and downloads shaders as just another update for each game. If it were to work on PCs then Steam would have to offer shaders for each GPU.Surely the real solution to this problem is to just "install" the shaders during game updates? We've already solved the timing problem for downloading the update itself, so just have the software distribution platform trigger a post-update installation that compiles shaders.
I don't know where you're getting that metric from but I'm totally fine with calling that enough to justify developing the option to automate shader compilation...Sorry, 63% is not the vast majority of users.
Is that true? Maybe for gamers, but AFAIK most computers actually go to sleep overnight, and only wake up briefly to do updates if necessary. Certainly most laptops will work this way...For the vast majority of users, their computer is on overnight, and that's when Steam/Windows/etc. download and install updates.
It's how it's worked on Linux since at least 2020. If you're unlucky, you download the shaders as an intermediate representation along with the game or game update, which then get compiled for your machine - in the background when the machine's idle, or when you launch the game. They get queued for recompilation on driver updates. If you're lucky, someone with similar hardware and driver version has already compiled them and uploaded them back to Valve, so you get the shaders already compiled without having to do anything. I don't know why Windows is so behind on this.Surely the real solution to this problem is to just "install" the shaders during game updates? We've already solved the timing problem for downloading the update itself, so just have the software distribution platform trigger a post-update installation that compiles shaders.
Sorry, shader compilation would not be a silent feature as intrusive as game updates already are, even if you optimize it to run slower it still takes a ton of memory.
Which is the only group of people routinely inconvenienced by shader compilation anyway.Is that true? Maybe for gamers
Look, we're pretty much on the same side the debate, there's no need to move goalposts. Automatic background shader compilation is a good idea and as I said in my very first comment on the matter:I don't know where you're getting that metric from but I'm totally fine with calling that enough to justify developing the option to automate shader compilation...
So why are you debating with me by saying there are ways to mitigate the inconvenience?Such an update process would have to be carefully implemented to prevent issues.
If your PC is automatically going into suspend mode (as opposed to as a result of user input), I don't believe it's that difficult for an app to delay entering suspend mode, and do the work then. Or, heck, could even notice when the PC is idle-ish, and do work in the background at low priority, pausing when no longer idle, though that's of course a fair bit more difficult.Is that true? Maybe for gamers, but AFAIK most computers actually go to sleep overnight, and only wake up briefly to do updates if necessary. Certainly most laptops will work this way...
So are you saying steam would monitor for driver updates? It isn’t only game updates that trigger this.Yes, that's why I specify quote around "install". The game already includes everything it needs to compile shaders, so split that off into a headless app that can be run by Steam/EGS/etc. Then. The user can have a nice tickbox in their settings for "run post-update tasks automatically". If the feature is on, shader compilation is a silent feature as intrusive as game updates already are. If it's off, at least now the store itself can provide a consistent UI for the experience. The problem right now is most games that compile shaders on launch will be full screen at their menu while doing it. At least if it was a headless app Steam/etc. runs, I can do other things uninterrupted in the meantime.
I mean Steam Hardware Survey already does monitor your driver version, wouldn't be hard to check it once a night at 2am and, if so, run shader compilation for relevant games. Regardless of whose update breaks the cache, this is a problem that I think should be solved when the update is installed, not deferred to when the user is actually trying to use the software in question.So are you saying steam would monitor for driver updates? It isn’t only game updates that trigger this.
Surely the real solution to this problem is to just "install" the shaders during game updates? We've already solved the timing problem for downloading the update itself, so just have the software distribution platform trigger a post-update installation that compiles shaders.
EDIT:
I think the wording above is implying I want games to distribute pre-compiled shaders to be installed with updates. That's not what I'm saying. I explicity mean once the game is updated, Steam/etc. itself can run each game's specific shader compilation tool. Steam already supports this kind of functionality through installScripts, they just don't have an option to have it run automatically during updates, and instead wait until the user hits play. Even that, I think, is vastly better as a user experience compared to pressing play, Steam saying the game is ready to play, having the game go full screen, and then being stuck at a compilation progress bar.
So pause the compilation while the computer is in active use? Delay sleep/hibernation temporarily to allow the compilation to complete if needed? It's not like there aren't tons of examples of potentially expensive background processes that we have learned to schedule effectively.
It seems to me that they need to compile one reference shader per (game, hardware, driver, etc) tuple, and hash the resulting asm, and then go grab the rest from an online cache. Then pretty much only one person has to suffer the pain per unique config, and there are only so many unique configs. Hard to understand why that still hasn't been implemented in this day and age.Honestly they need to revamp the entire shader compilation process. Rebuilding in the background is fine, but doesn't fix new games sitting at a shader compilation screen and then still suffering from shader compilation stutter.
There has to be a better and more efficient way than what we have been doing. The current way works great for platforms that can cache and distribute (consoles, steamdeck, etc), but it really does suck on PC.
Is that true? Maybe for gamers, but AFAIK most computers actually go to sleep overnight, and only wake up briefly to do updates if necessary. Certainly most laptops will work this way...
memories of living in a share house with 2mbps rural DSL and all the times we wanted to watch something on netflix but nope it's time for SYSTEM UPDATE and we couldn't even use another device instead because the console was using all the bandwidthEdit 2: Sorry, you're not to blame, you just triggered one of my pet peeves. I switch laptops a lot, and nothing is more frustrating than going "fuck, I need to use my Windows/Mac laptop for XXXX specific task", picking it up then having to wait 30 minutes while it goes completely crazy catching up on updates.
It's how it's worked on Linux since at least 2020. If you're unlucky, you download the shaders as an intermediate representation along with the game or game update, which then get compiled for your machine - in the background when the machine's idle, or when you launch the game. They get queued for recompilation on driver updates. If you're lucky, someone with similar hardware and driver version has already compiled them and uploaded them back to Valve, so you get the shaders already compiled without having to do anything. I don't know why Windows is so behind on this.
It seems to me that they need to compile one reference shader per (game, hardware, driver, etc) tuple, and hash the resulting asm, and then go grab the rest from an online cache. Then pretty much only one person has to suffer the pain per unique config, and there are only so many unique configs. Hard to understand why that still hasn't been implemented in this day and age.
Sorry I was unclear. I didn't mean the company spending compute time precomputing shaders. I just mean after your box finishes, it checks the first shader hash against something other people uploaded, and if your hash is already there, you get the other ones. If you are the first one, you upload when you have a full set (for that game). That's it. NVIDIA has plenty of money for a little cloud storage, hence the constant driver updates. They could push them out every six months like it was back in the day, they upped the delivery rate for no real benefit to them beyond PR.Easy answer:
View attachment 132036
Nobody with a significant economic interest has identified a way to profit from it. So they just can't be arsed.
Current method makes each consumer pay for the process, with their time, power, GPU usage. Explain to megacorps CEO why they should change that (use the language of a child aged 8-10).
Who is checking that the one person who compiles and uploads the compiled shaders doesn't upload malware that runs on the GPU?It seems to me that they need to compile one reference shader per (game, hardware, driver, etc) tuple, and hash the resulting asm, and then go grab the rest from an online cache. Then pretty much only one person has to suffer the pain per unique config, and there are only so many unique configs. Hard to understand why that still hasn't been implemented in this day and age.
As long as they don’t work to eliminate the need to reticulate splines before the game starts…
The problem is most acute on unreal engine and with developers who develop a million shader permutations and then relying on Epic's tooling to capture those shader permutations. Epic needs better tools to capture the shader permutations and possibly unreal developers need to be mindful of the number of shader permutations. The problem is not insurmountable because other engines and studios have sold this problem long ago.Honestly they need to revamp the entire shader compilation process. Rebuilding in the background is fine, but doesn't fix new games sitting at a shader compilation screen and then still suffering from shader compilation stutter.
There has to be a better and more efficient way than what we have been doing. The current way works great for platforms that can cache and distribute (consoles, steamdeck, etc), but it really does suck on PC.
I have a question related to this. A couple of weeks ago I was playing BG3 on Windows. And I've been playing it for a while, through various driver updates, and I've never noticed this long compiling shaders step before.I don't understand why this has suddenly become a problem. For the over a decade I was playing PC games from hard drives, game startup times were around a minute. When I got my first SSD, startup times dropped to less than ten seconds. They stayed there for over a decade. Now suddenly every new game starts up like an octogenarian reorganizing their sock drawer. Halo Infinite, loading from a very nice NVMe SSD, takes over ten god damned minutes to get into gameplay, the vast majority of which is staring at a splash screen while the world's widest loading bar slowly fills up. What in the blue blazes of fuck are developers doing!?
Lolwut? How do you even begin to make that assertion...their computer is on overnight