Bug #9488
Persistent framerate drops during unreasonable moments of maxed-out GPU loads
0%
Description
I've found heavy (semi-)persistent drops in framerate on moments when GPU-load occasionally seem to get maxed-out in unreasonable circumstances, dropping the framerate all the way from 60 FPS to ~20 FPS. This happens throughout the game and both 32 bit and 64 bit versions on Windows. Strangely enough causing a (graphical) context switch (by pressing the Win-button) seems to (temporarily) relieve the problem, reducing the max GPU load and returning the framerate to 'normal' values. However, in-game context switches or just in a matter of time, the problem of max-GPU load seems to return and cause the drop in framerate again. Doing a screen-recording using NVidia's ShawdowPlay seems to prevent the excessive GPU-load altogether and thereby eliminating the problem. However, this should obviously not be necessary to play a game.
- In the following video I demonstrate the problem: https://youtu.be/PCJWhRBzCu0
Steps to Replicate:
I'd say: see the video above! But here's a description:
- Make sure NVidia Shadowplay is NOT enabled by default. Also make sure 'Shadow time' is turned off, as it will also be recording frames in the background. The problem will not be visible with ShadowPlay enabled!
- Do a clean install of KSP (I used the Steam version)
- Make sure some way of showing the framerate is enabled (I used Steam's framerate overlay)
- It can be useful to use Process Explorer or any other tool to keep track of KSP's GPU and CPU loads.
- Start the game (In windowed mode it's easier to keep track of GPU loads and to do quick context switches)
- Usually the problem is already visible in the menu screen (not reaching 60 FPS or more). May switching between game modes and buildings is necessary to 'induce' the problem.
- Whenever you see a drop in framerate or a maxed-out GPU-load, try to induce a (graphical) context switch (e.g. by simply pressing the Win-button as I did in my video)
- Not always, but most of the time, a context switch 'returns' the GPU-load to normal values and thereby also returns the framerate back to original values (for me, usually 60 FPS)
- NOTE: Try to run the game with ShadowPlay enabled and you will not see any performance issues (except for maybe the slight load that ShadowPlay itself causes).
Expected:
No semi-persistent un-explainable excessive GPU-loads that cause a heavy drop in framerate.
Result/Observed:
(Semi-)persistent framerate drops during unreasonable moments of maxed-out GPU loads.
Fixes/Workarounds:
- Forcing a (graphical) context switch seems to (at least temporarily) return the GPU-load back to normal levels and thereby also fix the framerate.
- Enabling screen-recording/capture with NVidia's ShadowPlay seems to 'solve' the problem.
Notes:
Odd enough, while trying to record the problem using NVidia's ShadowPlay, the drops in framerate do NOT occur. Somehow ShadowPlay seems to 'prevent' the maxing-out of the GPU-load and hence no drops in framerate occur. This is also why I had to record the videos with a handheld camera. So this might also be a driver issue, but then I expect things to get worse when recording as opposed to when not-recording, which leads me to believe it might be a problem in the rendering pipeline.
- NOTE: This video, that I shot for another bug-report, show the game running with ShadowPlay, specifically the 'Shadow time' option, enabled: https://youtu.be/mE1ro_bKqmA
Version:
both 64bit and 32bit:
build id = 01230
2016.04.19 at 19:58:54 CEST
Branch: master
Related issues
History
#1 Updated by sal_vager over 8 years ago
- Severity changed from High to Normal
Duplicate of issue 9478 but has more info.
And please use the correct priorities as per the wiki, high is for literally game breaking issues, this doesn't break the game.
#2 Updated by sal_vager over 8 years ago
- Related to Bug #9478: Persistent framerate problems with KSP 1.1.0.1230 (or Unity 5) added
#3 Updated by sal_vager over 8 years ago
- Status changed from New to Need More Info
Saturnine, the logs are showing some odd stuff, and you have a hidden folder in your GameData.
Please try a new install in case you have some corruption, and make sure there's no extra folders in GameData.
Thanks.
#4 Updated by Saturnine over 8 years ago
sal_vager wrote:
Saturnine, the logs are showing some odd stuff, and you have a hidden folder in your GameData.
Please try a new install in case you have some corruption, and make sure there's no extra folders in GameData.
Thanks.
I can assure you the problem is also there with a complete fresh install. Tried that yesterday. The hidden folder is a .git repository to keep track of changes mods make. With or without the folder: same problems. Yesterday, for the bug report #9478, I cleaned the whole install and threw everything away: same problems. I already concluded that they were of no consequence, so today I removed all mods and all config file and restored everything of relevance with Steam... only things I kept was the .git folder.
#5 Updated by Saturnine over 8 years ago
If you like, I can clean once more and retrieve logs again? And/or maybe try some other things using the debug window??
#6 Updated by Saturnine over 8 years ago
- File Logs-CleanInstall-LowFPS.zip Logs-CleanInstall-LowFPS.zip added
- File Logs-CleanInstall-ShadowPlay-NoLowFPS.zip Logs-CleanInstall-ShadowPlay-NoLowFPS.zip added
- Status changed from Need More Info to Updated
- Assignee set to sal_vager
- % Done changed from 0 to 10
I Hereby added the logs for runs with completely clean installs.
I did not make a video again, but tried to follow more or less the exact same steps as in my video.
See also the text file called performed-actions.txt in each zip file for exact reproduction scenarios.
If I can be of any more assistance, let me know.
#7 Updated by sal_vager over 8 years ago
- Assignee deleted (
sal_vager)
#8 Updated by Saturnine over 8 years ago
Just a question as a newbie on this bug-tracker: Is/was it ok to put the status to updated and assignee you so you could review my update? What is the correct way for getting it confirmed or otherwise 'taken up' or dismissed?
Besides, I still think this bug might qualify for high priority. Especially if it turns out to be reproducible. I will shortly be able to test if running the game on my Laptop shows similar problems.
#9 Updated by cpcallen over 8 years ago
- File KSP.log KSP.log added
- File settings.cfg settings.cfg added
I am experiencing a very similar issue on my MacBook Pro (mid 2010) running OS X 10.11.4:
- Normally KSP runs at around 15 FPS.
- Sometimes the framerate will suddenly drop to about 3 FPS (slow enough that I can easily count individual frames).
- Putting the machine to sleep (by closing screen) and then waking it will restore frame rate to usual brisk rate, at least for a while.
Prior to 1.1.1, I had only ever seen this happen on a few rare occasions when the machine was running on battery and/or was quite hot (say, because the vents were partially blocked by a laptop case or because it was sitting on a soft surface).
Since roughly around 1.1.1 came out, this has begun to happen very regularly, usually at random within 10-60 seconds of playing. (I cannot say for certain that it started exactly when 1.1.1 came out, but I played quite a lot of 1.1.0 with no problem, while the last few days it has basically been impossible to play because of this problem.)
The problem can often be triggered byloading a larger craft: craft loads up fine, I can move the viewpoint around to look at it, and then a few seconds later everything grinds to a (near) halt. Sleep and wake, everything O.K. for another 5-30 seconds and then back to molasses.
The framerate drops also happen at random, affect all scenes, including the main menus.
Oddly, the framerate as displayed in the "Performance" section of the debug menu appears to bear no relationship to the actual framerate: it normally reports around 25 FPS (with the odd spike up to as much as 60 FPS), regardless of whether things are running normally (which I estimate to be closer to 15 FPS for most scenes) or in painfully-slowly (3 FPS - seriously: I counted 43 frames in 15 seconds, despite debug menu continuing to report an absolutely steady 25 FPS).
I am pretty sure this is GPU rather than CPU related, because Activity Monitor shows the CPU usage dropping proportionately to the framerate, with the CPU otherwise mostly idle.
I have attached the KSP.log file from a test with a fresh 1.1.2 install, with the following sequence of activity:
- Started from Steam.
- I type part of the above bug report.
- Switch to KSP, find it at opening menu running at 3 FPS.
- Sleep, wake, unlock screen: framerate back to perhaps 30 FPS.
- Create new Sandbox game, go into SPH
- In Finder, move a large .craft file into saves/Craft/SPH
- Attempt to open craft in SPH; turns out is has MechJeb module.
- Remove MechJeb from .craft using emacs
- Framerate has dropped to 3 FPS again.
- Sleep, wake, unlock screen: framerate back to perhaps 30 FPS.
- Attempt to open craft in SPH; turns out is had two MechJeb modules.
- Remove second MechJeb from .craft using emacs
- Framerate has dropped to 3 FPS again.
- Exit SPH
- Check settings via escap menu
- Quit savegame
- Check settings via main menu
- Quit game
System Information (excerpt):
Hardware Overview:
Model Name: MacBook Pro
Model Identifier: MacBookPro6,2
Processor Name: Intel Core i7
Processor Speed: 2.8 GHz
Number of Processors: 1
Total Number of Cores: 2
L2 Cache (per Core): 256 KB
L3 Cache: 4 MB
Memory: 8 GB
Processor Interconnect Speed: 4.8 GT/s
Boot ROM Version: MBP61.0057.B11
SMC Version (system): 1.58f17
NVIDIA GeForce GT 330M:
Chipset Model: NVIDIA GeForce GT 330M
Type: GPU
Bus: PCIe
PCIe Lane Width: x16
VRAM (Total): 512 MB
Vendor: NVIDIA (0x10de)
Device ID: 0x0a29
Revision ID: 0x00a2
ROM Revision: 3560
gMux Version: 1.9.21
Displays:
Color LCD:
Display Type: LCD
Resolution: 1680 x 1050
Pixel Depth: 32-Bit Color (ARGB8888)
Main Display: Yes
Mirror: Off
Online: Yes
Built-In: Yes
Please fix, as the game really isn't actually playable at 3 FPS.
#10 Updated by cpcallen over 8 years ago
I rolled back to 1.1.0 (yay, Time Machine!), and at first I thought the problem had gone away completely - I was able to play without problem several sessions of an hour or more - but more recently it has been acting up almost as badly as 1.1.2 does.
I have used gfxCardStatus to verify that the machine is not accidentally switching to integrated graphics (it is not).
I notice that all graphics performance on the machine is affected: when KSP's framerate drops to ~3FPS, other grahpical activities (like scrolling Google Chrome windows) also becomes extra sluggish - that is, even more sluggish than it would normally be when KSP is running normally.
I see there was another, earlier report of this problem in the forums
#11 Updated by reinderien over 8 years ago
I believe that my issue [[http://forum.kerbalspaceprogram.com/index.php?/topic/138794-severe-intermittent-lag/#comment-2556961]] is the same as this one.
Commonalities with what I read above: I also have an nVidia chipset (though it's a different one, the Quadro FX 880M); I also have an Intel processor; I am running the same version of KSP; and I see the same symptoms.
I will say, however, that since being very careful about laptop cooling, this issue has not reoccurred at all.
#12 Updated by TriggerAu over 8 years ago
- Status changed from Updated to Needs Clarification
- % Done changed from 10 to 0
Setting this to needs clarification as per the bug cleanup underway: http://forum.kerbalspaceprogram.com/index.php?/topic/143980-time-to-clean-up-the-bug-tracker
Would be great to hear feedback on this from 1.1.3 and info re bug. Thanks