Skip to content

stutter issues in linux #1350

@senecaso

Description

@senecaso

Your system information

  • System information from steam in a gist: System Information
  • Have you checked for system updates?: Yes

Please describe your issue in as much detail as possible:

I frequently get "stutter" problems when playing CS on my machine. This manifests itself in my FPS (as reported by cl_showfps 1) dropping suddenly and sharply. I will be happily playing with 175 FPS, and suddenly it will drop to 15-30 FPS and stay there for 5-30s. This occurs about once every 15mins or so. I have googled around and seen that a large number of other users are experiencing the same issues, but I have not seen a solid conclusion to address the issue yet. After doing some tracing through the issue, I think I may have found a clue, but I will need help from the community to trace the issue down further.

What I have found is that when my FPS drops is when a software interrupt is being processed by the system. This results in a large spike in the amount of CPU being spent in the kernel. I can't say for sure this is the cause, but there is certainly a correlation.

Here is some output I gathered from dstat. In the output, you will notice that a software interrupt occurs at 17:33:03 (look for the siq column) and see that the SYS CPU spikes at the same time. At the same time, I also grabbed output from nvidia-smi. You can see that at approximately the same time, the GPU and memory utilization on the card hits the floor. I'm not sure how this relates, but you will also notice that just before the stutter got really bad in the game, you can see that the graphics Mhz dropped from 131 to 75 MHz and stays there until the FPS recovers around 17:33:26. I have been able to consistently reproduce this behaviour.

Unfortunately this is where my experience falls off. I'm not sure how I can gather information about what is causing the software interrupt that is causing this issue. If dtrace were available, I would use that as I suspect the issue at hand is exactly as described in that article. Does anyone out there know how to track down the source of this interrupt? I'm hoping that if we can track it down that we might be able to come up with a workaround, or perhaps Valve would be able to address it directly in the code.

I should add that I am gathering the dstat and nvidia-smi output while playing CS in a 1440x960 window with the video settings maxed out. However, I have also reproduced the issue playing fullscreen and windowed with all videos settings set to low or disabling them entirely. Whatever the issue is, its not resolved by reducing the pressure on the video system.

Steps for reproducing this issue:

  1. start an offline game with bots. I have reproduced the issue on Canals, Nuke, and Inferno
  2. ensure cl_showfps 1 is on (although the issue happens with it off as well)
  3. play until the FPS drops and the game-play gets choppy
  4. check the output of dstat and nvidia-smi for the presence of software interrupts that coincide with the poor performance

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions