
System lock-ups happen when game is GPU-limited and running below the FPS limit
LTCatt opened this issue · 4 comments
Bug Description
There are occasional occurrences of extreme stuttering where:
- The in-game FPS display appears normal (showing 60+ FPS), but actual frame updates may only occur once every few seconds
- The stuttering affects not just the game, but the entire system (as visible in recordings where the system clock in the lower-right corner also freezes)
Rec:
https://github.com/user-attachments/assets/2f0b921c-ad30-48ac-95bd-4e22fa8cf6a9
https://github.com/user-attachments/assets/bc8713af-11c3-4796-b910-a176b4b9a4b4
Reproduction Steps
Trigger conditions:
- CPU Render-Ahead Limit must be set to at least 1
- Frame rate limit must be set higher than actual performance (e.g., locked at 60 FPS when actual performance is only 50 FPS)
- Shader should be enabled (appears more likely to trigger with higher-performance requirement shader)
Log File
No useful information :/
latest.log
Crash Report
I was trying to diagnose a stuttering problem after I died. My game totally froze 3 times. My first thought was to look at the issues pages. I genuinely can't believe the problem was sodium.
The CPU Render-ahead Limit in Sodium is really not that clever, it is just a glClientWaitSync
that has the game wait for a semaphore that is created N frames ago. In other words, the main render thread is just waiting for the driver to finish some work, and it has no bearing on what the graphics driver or operating system is doing.
If you are experiencing full system freezes as a result of it, this is likely a problem with your software configuration, and not our mod.
To put it another way, essentially every game released in the last 10 years is doing exactly this, because otherwise the game could end up putting a possibly unlimited number of frames into the render queue, which it doesn't have the memory to be doing.