Fossilize icon indicating copy to clipboard operation
Fossilize copied to clipboard

Extremely long shader compilation times

Open Daktyl198 opened this issue 1 year ago • 5 comments

Using Proton Experimental as my default proton version, I'm seeing EXTREMELY long shader compilation times. I'm talking over an hour for certain games. Deadlock takes 15 minutes and re-compiles every time there's an update. I'm trying to run Once Human right now and it's been compiling shaders for 45 minutes and it's only at 57%.

I have a Ryzen 3700X and 32GB of RAM, along with 7900XT. I can compile the Cosmic desktop environment from source code faster than I can most of these shaders. I believe there's something wrong with Proton and how it's handling the compilation of shaders. If this is unusual or there's anything I can do to improve the situation, I'd love to know.

Daktyl198 avatar Sep 28 '24 13:09 Daktyl198

Hello @Daktyl198, this reads like Steam's shader pre-cache subsystem, which is run through Fossilize, not Proton, so I've transferred this issue to the Fossilize issue tracker.

kisak-valve avatar Sep 28 '24 13:09 kisak-valve

You are correct. I had not looked at the process name, and assumed the two were related. Thank you for the assistance.

Daktyl198 avatar Sep 28 '24 13:09 Daktyl198

Can confirm that Deadlock frequently needs to recompile shaders and takes a long time too. Even just skipping the compile takes a minute.

cryticx avatar Oct 05 '24 01:10 cryticx

I'm having a similar issue with Overwatch 2. It looks like when pressing "play" to start the game only a single thread of fossilize pops up, where I would prefer to have as many as reasonable on my CPU.

The background process option does this with an option in steam_dev.cfg, "unShaderBackgroundProcessingThreads", where supplying an amount of threads after it will greatly speed up the background process, but only the background one.

hugeblank avatar Feb 12 '25 06:02 hugeblank

I think Fossilize implemented a protocol channel which will remove all pressure restrictions if fossilize should work in foreground. I wonder if that is properly used by the Steam client if you press play.

kakra avatar Feb 12 '25 10:02 kakra