protonscr

Shader Pre-caching causes 100% CPU usage for 10 minutes after closing a game.

steamclosed Steam clientProton
ValveSoftware/steam-for-linux#6332 · opened 2019-06-21 by Anonycow · updated 2021-12-24 · 12 comments · github
AAnonycow 2019-06-21 github

Your system information

  • Steam client version (build number or date): Latest beta, June 17 2019
  • Distribution (e.g. Ubuntu): Arch
  • Opted into Steam client beta?: [Yes/No] Yes
  • Have you checked for system updates?: [Yes/No] Yes

Please describe your issue in as much detail as possible:

I'm playing Path of Exile through SteamPlay. This game has the most shader pre-caching content out of all games I've played so far (steam_pipeline_cache is 2.4 GB).
I have encountered several problems.

  1. Every single time there is a shader pre-caching update, ALL of it must be re-downloaded. So far I have downloaded 1.5 GB, 1.6 GB, 1.7 GB, and 1.8 GB updates in sequence, but the final result is only 2.4 GB (I assume there is network compression). This takes a very long time on a third-world 4mbps capped connection.
  2. On top of that, Steam decides that it wants to prioritize shader pre-caching content over game updates, so you can't update the game before you've downloaded all of the shader pre-caching content(20 MB game update, 1.8 GB of shaders, every time). The game update doesn't show up in the downloads list before the shader content has finished downloading and you can't launch the game before it's finished downloading, either.
  3. Shader pre-caching content is downloaded silently while ingame, even if background downloads are disabled. This can make multiplayer games very, very unplayable and frustrating until you realize 30 minutes into the game that Steam has been downloading the whole time and it's downloaded 200MB/1.6GB so far.
  4. After closing the game (Path of Exile), every single time, Steam will start burning 100% CPU for 10 minutes after it's closed, regardless of how long you played. In htop it shows as CJobMgr::m:Work thread. This no longer happens if shader pre-caching is disabled.

For these reasons I have disabled shader pre-caching.

Note that I have a i7-7700K CPU overclocked to 4.7 GHz, so this burns quite a lot of power.

Steps for reproducing this issue:

  1. Enable shader pre-caching
  2. Launch a game with large amounts of shader pre-caching content like Path of Exile
  3. Close it
  4. See 100% CPU usage

Note, I am using a custom build of Proton (proton_tkg_4.10.r1.ge2fa6bd9) however the CPU usage comes from the steam process itself and not from Proton. Also using DXVK Async pipecompiler which comes from that build, hopefully shouldn't cause problems.

Kkisak-valve maintainer 2019-06-21 github

Hello @Anonycow, in general, multi-issue issue reports are bad for any issue tracker. Since you've highlighted your fourth issue in the issue report's title, only that issue will be tracked here.

The second issue reads like #6299.

Please open separate issue reports for the other issues.

AAmosar 2019-06-25 github

I've also this issue with rocket league for example
When I close it steam one of my core and use it at 100% and it doesn't stop If I launch the game to play another game :/
image
And in shader_log.txt I have those informations:

[2019-06-25 22:41:35] [AppID 271590] Finished Shader Swarm download job: No Error
[2019-06-25 22:41:35] [AppID 391220] Starting Shader Swarm download job.
[2019-06-25 22:41:35] [AppID 391220] Target manifest 5997794046070952295 of size 11340417.
[2019-06-25 22:41:35] [AppID 391220] Source manifest 6754517564336469335 of size 9743766.
[2019-06-25 22:41:44] Committed bucket 6882496 (AppID 391220) from 6754517564336469335 to 5997794046070952295.
[2019-06-25 22:41:44] [AppID 391220] Finished Shader Swarm download job: No Error
[2019-06-25 22:42:15] FOZ underflow, file truncated?
[2019-06-25 22:42:15] Processing FOZ cache file at /home/amosar/.local/share/Steam/steamapps/shadercache/252950/steamapp_pipeline_cache.foz

System informations
Full logs:
compat_log.txt
shader_log.txt

PPlagman 2019-07-02 github

Thanks; we have fixes in the pipeline for all these symptoms.

Bbk201doesntexist 2020-01-16 github

Any word on said fixes? This behaviour is still seen today with Path Of Exile.
Edit: I apologize if I made it sound like I'm displeased or anything like that. I'll happily provide any logs or even submit a new bug report on this issue, if that is deemed necessary.

Ddavidbrum25 2020-04-02 github

Hi, can confirm that the high cpu usage after exit is still going on. And if you try to close steam after closing the game, steam crashes or never close, you need to kill the process. at least 25% cpu usage on exit.

Edit: This only happens to me with Path of Exile.

Ssiyia2 2020-11-19 github

Same thing with Killing Floor 1 under proton it happens with either opengl or vulkan/dx9 backend. Cpu isnt at 100%, but around 30% in my case and there is a lot of hdd thrasing (my steam library is on a secondary hdd) for about 6 minutes.

MMarc-Pierre-Barbier 2020-12-19 github

i just got this with fallout 4 all core 100% cpu

Ssiyia2 2020-12-22 github

Issue persists with latest steam update that's supposed to fix shader cache

MMarc-Pierre-Barbier 2020-12-22 github

i just realized this was the wrong place to post since for me it was on the game startup and not on closure
it's still 12threads at 100% tho

Kkisak-valve maintainer 2021-11-19 github

Hello, is anyone still experiencing this issue with the same severity as the opening post?

Steam's shader pre-caching sub-component is expected to do some post-game-session processing to figure out if new shaders were seen during gameplay and Path of Exile has a very large collection of shaders compared to most games.

Ssiyia2 2021-11-21 github

I tried it with killing floor via proton which had that problem, and with latest steam beta and mesa 21.2.5 no excess cpu usage is noted after exiting the app

Kkisak-valve maintainer 2021-12-24 github

Closing as outdated.

Nothing extracted yet.