Jump to content

Terrible Performance with Multi-Part Ships


Recommended Posts

So.. well I quit KSP for this some time last year and ended up stuck at one point trying to do what I wanted to with the game and the performance ended up tanking terribly and couldn't even play it.. and now I've re-visited the game again some 6 months later after (finally) upgrading my computer after 6 years on the old one and tried to get back to the same spot again. There was a big game update since I quit last and so I started over.. Finally get up to where I was before and.. even with my newer computer... performance is still crap and unplayable. I don't really understand what to do with this dumb game. I'm posting here for any remote insight what so ever to try and fix this.

 

OLD computer. Had this one from.. gosh, spring 2009 -> spring 2016.

I7-920 @ 4.4 ghz

24 GB ddr3 @ 1800 mhz

Pair of massively overclocked +40% water cooled GTX 470's.

 

New computer updated 2 months ago:

I7-3770k @ 4.8 ghz

16GB DDR3 @ 2397 Mhz

Single AMD R9 290X, 8GB overclocked edition from Sapphire Vapor-X Tri-X version.

 

 

What I'm trying to do: Use a combination of KIS + KAS and land 3 ships on the mun as a space refinery point for outer-system ships. Landed one ship down.. simple ship, 85 parts by the time it got there. Landed small single-kerbal ship down because I forgot to send an engineer. Landed 50 meters from first ship. Landed down "large" 4 x rockomax orange fuel tanks + lots of solar panels + up to 130k battery power + 4 drills + 5 storage tanks for ore + refinery / ore converter. Everything fine. Get it landed on the mun about 120 meters from the other 2 ships. Ore miner ship is about 340 parts. Then.. I start connecting hoses. After I connect hoses, then switch back to the ore refinery / miner via space center.. my FPS controlling this ship drops to 6-9 FPS. It's sitting here running on the other computer while I type this on my laptop. literally 0% gpu usage. 20% cpu usage, no one cpu thread/core on the 3770k is more than 20% utilization. There's nothing in my system that's being overloaded.. or even loaded at all. This is unacceptable and terrible FPS.. I can't move my Kerbal on EVA near this, I already accidentally knocked off some of the solar panels because it lag-bursted from the slow FPS.. This is a crazy powerful computer system and it runs an older, simple game like KSP like this? What the hell is going on here?

Edited by kithylin
Link to comment
Share on other sites

Okay let me try and talk you down.

1. You mentioned one of the ships comprises 340 parts. How many parts are there total in all of the structures you are trying to connect? Note that even with a 4.8 GHz CPU, 340 parts is close to what most players would consider the practical limit for a high FPS.

2. KSP is unlike most games as far as GPU usage goes. Most modern games are very heavy on graphics and visual effects, and they tend to contain large numbers of high-resolution models. KSP's part models are relatively simple and the stock game features very few eye-candy effects, so as a consequence KSP tends to be very light on GPU usage. However, every part in KSP contains a large amount of data about its motion, mass, connections to other parts, etc. and most of the calculations performed on these end up requiring data from every other part in the ship and must be performed in a specific order. Hence as the number of parts on a ship increases, the CPU usage increases geometrically.
tl;dr: Your awesome GPU isn't going to help much in KSP.

3. As far as that "20% cpu usage," can you check to see whether your task manager or whatever is accurately reporting thread usage? Your setup sounds like it's hyperthreaded, so it's possible that 20% of the full CPU power is being used, but one thread on one of the cores is being run at full throttle. Sadly the only surefire way around this is to get an even faster processor, but you're unlikely to find anything above 4.8 GHz.

4. KSP isn't as old or simple as it looks. Remember Minecraft? It looks low-res, but that's merely the visual style. Computationally it's in the middle of the pack at worst.

5. Mods, especially complex ones like KIS and KAS, are notorious for reducing performance. The modders do their best, but every feature they add makes the game run that much slower.

6. You may actually be encountering log spam. Press Alt+F12 and look at the Console / Debug Log to see if it's showing repeated error messages. Occasionally when something breaks, particularly in a mod, the log gets flooded with error messages every frame, so not only is the game being tripped up by whatever the error is, it's being bogged down even more with producing debug messages and writing them to the disk repeatedly. If you happen to have a traditional hard drive, that last bit is going to hit particularly hard.

Link to comment
Share on other sites

I'm pretty sure that...

2 hours ago, kithylin said:

...this "dumb" game...

...has nothing to do with your problem:

Have you made sure you are not running KSP with your IGP (from your i7 3770K) instead of your R9 290X?

Maybe start to check that first, because a 0% GPU usage is a bit suspicious...

Link to comment
Share on other sites

3 hours ago, kithylin said:

literally 0% gpu usage. 20% cpu usage, no one cpu thread/core on the 3770k is more than 20% utilization.

Hmmm... I assume you are running Windows, right? The utilization which Windows shows in the task manager is usually the utilization of all cores combined. Which means that it is possible that one core runs like hell while the others are sleeping. Which is a very known scenario that a lot of people experience whith high part count.

The current version of KSP has a very ineffective way of calculating fuel and energy flow therefore wasting a LOT of cpu power. This has been fixed/will be fixed in the new version coming out soon(TM).. The prerelease of this new version is already available and I confirm that it runs much, much, much more smoother.

Link to comment
Share on other sites

There's an even better tool than that which I'll link when I'm not on a mobile.

EVE will stress your gpu if you have loads of volumetric clouds, otherwise even high poly models don't really affect fps. Two ships and 430 parts, you didn't say how many were on the third... there is something of a limit to loaded parts dependent on system above which performance starts falling off really badly. Simple answer right now is just that, simplify.

Link to comment
Share on other sites

5 hours ago, parameciumkid said:

Okay let me try and talk you down.

1. You mentioned one of the ships comprises 340 parts. How many parts are there total in all of the structures you are trying to connect? Note that even with a 4.8 GHz CPU, 340 parts is close to what most players would consider the practical limit for a high FPS.

2. KSP is unlike most games as far as GPU usage goes. Most modern games are very heavy on graphics and visual effects, and they tend to contain large numbers of high-resolution models. KSP's part models are relatively simple and the stock game features very few eye-candy effects, so as a consequence KSP tends to be very light on GPU usage. However, every part in KSP contains a large amount of data about its motion, mass, connections to other parts, etc. and most of the calculations performed on these end up requiring data from every other part in the ship and must be performed in a specific order. Hence as the number of parts on a ship increases, the CPU usage increases geometrically.
tl;dr: Your awesome GPU isn't going to help much in KSP.

3. As far as that "20% cpu usage," can you check to see whether your task manager or whatever is accurately reporting thread usage? Your setup sounds like it's hyperthreaded, so it's possible that 20% of the full CPU power is being used, but one thread on one of the cores is being run at full throttle. Sadly the only surefire way around this is to get an even faster processor, but you're unlikely to find anything above 4.8 GHz.

4. KSP isn't as old or simple as it looks. Remember Minecraft? It looks low-res, but that's merely the visual style. Computationally it's in the middle of the pack at worst.

5. Mods, especially complex ones like KIS and KAS, are notorious for reducing performance. The modders do their best, but every feature they add makes the game run that much slower.

6. You may actually be encountering log spam. Press Alt+F12 and look at the Console / Debug Log to see if it's showing repeated error messages. Occasionally when something breaks, particularly in a mod, the log gets flooded with error messages every frame, so not only is the game being tripped up by whatever the error is, it's being bogged down even more with producing debug messages and writing them to the disk repeatedly. If you happen to have a traditional hard drive, that last bit is going to hit particularly hard.

I know you're trying to help but I very specifically said in my first message " no one cpu thread/core on the 3770k is more than 20% utilization.", so no, it's not overloading any of the cores. Not a single one is above 20%. Also KSP is now 5 years old, it was originally released in 2011. They should of fixed problems like this by now. And a system like mine should easily be able to handle even a 1000 part ship if KSP would actually use any of my computer. But it doesn't seem to.

3 hours ago, dueb said:

I'm pretty sure that...

...has nothing to do with your problem:

Have you made sure you are not running KSP with your IGP (from your i7 3770K) instead of your R9 290X?

Maybe start to check that first, because a 0% GPU usage is a bit suspicious...

I'm using Asus Sabertooth P67 motherboard. It doesn't even allow/support using the IGP at all. Dedicated GPU only. That's not the issue.

2 hours ago, Carraux said:

Hmmm... I assume you are running Windows, right? The utilization which Windows shows in the task manager is usually the utilization of all cores combined. Which means that it is possible that one core runs like hell while the others are sleeping. Which is a very known scenario that a lot of people experience whith high part count.

The current version of KSP has a very ineffective way of calculating fuel and energy flow therefore wasting a LOT of cpu power. This has been fixed/will be fixed in the new version coming out soon(TM).. The prerelease of this new version is already available and I confirm that it runs much, much, much more smoother.

And nope, I have the task manager split to show all 8 threads, no one thread is above 20% and most are 15%. It's not using much or any of the processor at all.

2 hours ago, RedKraken said:

For windows, process explorer 

https://technet.microsoft.com/en-us/sysinternals/processexplorer.aspx

will show u much greater detail than task manager...individual core utilization etc

Its gold. 

Windows task manager shows indiviual core utilization already, and I've enabled that. It's just a setting.. thanks but 3rd party program isn't going to show anything different.

 

Bottom line.. I don't know what's wrong with KSP. I guess I'll just have to delete it again and hope some how in another year or more that who ever makes KSP releases an update to actually use gpu/cpu to handle large-part-count ships. I basically have a monstrous beast of a computer, there's no reason KSP shouldn't fly at 60 FPS constantly no matter how many parts or mods I'm using.... so it's pretty upsetting to see it ever dive down to single digit FPS for any reason.

EDIT: Added screenshot so you can all see. Low cpu usage, 0% gpu usage.. no ISP in this system.. KSP just.. won't use anything with my computer when it's under the worst load it should be using everything..... Oddly I load it up today and it's 16 FPS.. that's still deplorable though.

 

KSP-Info1.jpg

Edited by kithylin
Link to comment
Share on other sites

If you're using 1.1.3, you might want to wait until 1.2. It has enormously improved performance with high part-count ships. There's a YouTube somewhere where someone docks a couple of 1000+ part ships in orbit; the game freezes for a second or so as it recalculates physics but after that it's smooth as butter.

Link to comment
Share on other sites

44 minutes ago, Brikoleur said:

If you're using 1.1.3, you might want to wait until 1.2. It has enormously improved performance with high part-count ships. There's a YouTube somewhere where someone docks a couple of 1000+ part ships in orbit; the game freezes for a second or so as it recalculates physics but after that it's smooth as butter.

Aha! So there is an update coming? Maybe I can actually play it again soon. :)

Edited by kithylin
Link to comment
Share on other sites

2 hours ago, kithylin said:

Aha! So there is an update coming? Maybe I can actually play it again soon. :)

Version 1.2-pre is in public beta, available on Steam and the Squad store.

Link to comment
Share on other sites

4 hours ago, kithylin said:

And nope, I have the task manager split to show all 8 threads, no one thread is above 20% and most are 15%. It's not using much or any of the processor at all.

No you don't understand multithreading. A single-threaded program which max out its CPU usage will show you a 12.5% for each thread in your 4C8T task manager. "It's not using much", but as a single-threaded program that's the best it can do.

Now in KSP world. Within a ship, the physics calculation is still single-threaded. Since you have a high part count ship, it's almost surely the bottleneck. Now, I don't know exactly why that has to be single threaded, but my gut feeling is that it comes from Unity engine (considering that the benefit of multithreading across ships comes from Unity engine upgrade). If that's the case, then probably don't expect any version in the near future can max out your "task manager cpu%" to 100% for any single high part count ship. It doesn't scale that way.

Edited by FancyMouse
Link to comment
Share on other sites

I would expect anything in danger of colliding has to be on the same thread ( you can easily make gross collision checks ), otherwise I don't know why it has to be single threaded either. It does use two cores these days, which is a start ( although I run FAR, so it might just be FAR ) - so I can finally get double-digit cpu usage %. The OP didn't mention anything about the log - please do check the log for NREs.

As promised, better process explorer tool: http://processhacker.sourceforge.net/

Edited by Van Disaster
Link to comment
Share on other sites

2 hours ago, FancyMouse said:

No you don't understand multithreading. A single-threaded program which max out its CPU usage will show you a 12.5% for each thread in your 4C8T task manager. "It's not using much", but as a single-threaded program that's the best it can do.

Now in KSP world. Within a ship, the physics calculation is still single-threaded. Since you have a high part count ship, it's almost surely the bottleneck. Now, I don't know exactly why that has to be single threaded, but my gut feeling is that it comes from Unity engine (considering that the benefit of multithreading across ships comes from Unity engine upgrade). If that's the case, then probably don't expect any version in the near future can max out your "task manager cpu%" to 100% for any single high part count ship. It doesn't scale that way.

Not to argue but actually in single-threaded applications Cpu thread #0 is always at 100% if it is maxed out. I can run old Prime95 and it does this (CPU #0 maxed out), so does CineBench run in single-core mode, as well as for example, Ark: Survival Evolved server will run 100% on a single cpu thread, always core #0. This is what single-threaded programs do when they are reaching their limits. The very definition of "Single-Threaded" means it's not able to use more than 1 thread, ever, for any reason. It does not mean it's going to spread out it's single thread across all 8 threads.. because that would be.. a multi-threaded program.

This is not what is happening with KSP. KSP Can't load any one single thread to more than 20%. 

Ark Evolved actually in the VAB building a ship will (and often does) throw up 70% - 80% on all 8 threads and is just happy as a clam to suck up all the CPU power available to it. I think it's physics in the in-game world that's still having issues. Regardless, it runs like excrementse at the moment and is totally unplayable at high part count ships.. regardless of the reason why. I'll hold out hope the above mentioned new update will fix it. If it doesn't.. then I guess I'll just have to delete the game and re-install later at the next update to see if it's actually playable yet.

It's still pretty astounding to me that in 5 years of development they still have yet to fix this issue. :(

Edited by kithylin
Link to comment
Share on other sites

If I may offer one more bit of subjective advice to the OP: You'll get friendlier responses if you adopt a humble attitude and direct your anger only at the problem and not at the developers or at the game itself. That means not throwing around words like "crap" and "unplayable." When the rest of us see stuff like that, for most our first response is either to ignore the post or treat the author as a noob.

Link to comment
Share on other sites

54 minutes ago, parameciumkid said:

If I may offer one more bit of subjective advice to the OP: You'll get friendlier responses if you adopt a humble attitude and direct your anger only at the problem and not at the developers or at the game itself. That means not throwing around words like "crap" and "unplayable." When the rest of us see stuff like that, for most our first response is either to ignore the post or treat the author as a noob.

Well uh, sorry? What else would you use to describe any game that runs single-digit or 11-15 FPS ?

 

I'm sorry if it seems rude or not so nice but "unplayable" is pretty much what I would consider anything in that situation.

Link to comment
Share on other sites

49 minutes ago, kithylin said:

I'm sorry if it seems rude or not so nice but "unplayable" is pretty much what I would consider anything in that situation.

Odd then that most of us are managing to play it just fine, with hardware much less beefy than yours to boot.

Link to comment
Share on other sites

3 minutes ago, Brikoleur said:

Odd then that most of us are managing to play it just fine, with hardware much less beefy than yours to boot.

Are you trying to work with 300 - 500 total part-count between multiple ships just a couple hundred meters apart and manage more than 16 FPS?

If so it would be awful nice if you could let me know your secret and how you are doing it.

That ultimately is what I'm trying to find out with this thread: What am I doing wrong and how can I fix it to make it work faster.... I've had a few suggestions but nothing's come to fruit yet that actually helps.

Link to comment
Share on other sites

8 hours ago, kithylin said:

Are you trying to work with 300 - 500 total part-count between multiple ships just a couple hundred meters apart and manage more than 16 FPS?

No, I don't think I've ever made anything quite that big. 

Edited by Guest
Link to comment
Share on other sites

Just now, Brikoleur said:

No, I don't think I've ever made anything quite that big. Why are you?

Because I want to? Why not? The game doesn't have any built in limits to the amount of parts we can put together with something. Why should we be limited in what we want to put together just because the game's engine runs liquid-poor slow when we try it? It's an open-ended build game, we should be able to build what ever we want for any reason we want to.

Part of why I'm sad that we're halted from doing what ever our minds come up like this :(

 

The new update should fix things (hopefully).

Link to comment
Share on other sites

You mention using mods. KAS/KIS specifically. Have you tried doing the same mission plan with the same number of ships/number of parts in a completely stock game? I haven't played with KAS in quite some time because of the bugs I encountered (it was a while ago and I'm not familiar with recent performance), but it is possible that is exacerbating your issues.

Think of KSP as a car. I know the gas milage my car usually gets. Think of a mod like KAS/KIS as an accessory such as a car top carrier. Now, the shape of that car top carrier depends on who made it. Some people make it more aerodynamic than others. In the same way some mods are more efficient than others. Regardless of the aerodynamics involved, I'd be foolish to think that adding this accessory on top of my vehicle, which adds additional weight and drag, won't negatively impact my average gas milage.

Each mod you add (that is more than just a parts mod) is like adding another accessory to the outside of your car. If you expect performance to be just as good as stock, well, I would say your expectations are unrealistic. And some mods have more of a performance hit than others.

One other thing after rereading your posts. You mention connecting the vessels with hoses. As I said, I'm not too familiar with the current state of KAS/KIS, but if the game treats vessels connected by hoses like it treats vessels connected by docking ports, that could be part of the problem. KSP is capable of multithreading now. It handles separate vessels in separate threads when it can. However, once you dock two or more vessels together, they become one vessel which is now being handled by one thread. So with mods installed you may be reaching the single vessel part limit that your machine can handle once you connect everything together. If you undock, or in this case unhose, you may experience a small pause while the game splits vessels unto separate threads, but your frame rate should improve.

Also, you really need to check the log for errors. Either error spam or just a mod having an error period could be a potential performance hit.

Or just wait for 1.2 to be released and then wait for your mods to be updated and hope that is enough improvement for you. And remember, there may be no hard coded limits to number of parts in the game, but there are very real practical limits. I haven't seen any physics based games with user created objects handle large creations without either performance issues or slowing the simulation to allow accuracy.

Link to comment
Share on other sites

Hi

i have similar problem. KSP (64)  runs all fine 60fps, untill i get with my ship within 4km range of another ship. then it goes to 1fps.  

I dont do hi partcount ships.

KIS, KAS, KAX, RemoteTech, B9, BD armory, Extraplanetary launchpads, JSI, kerbalism, chatterer, firespiter, FAR, aviation lights, Near future, contract configurator, some mods i dont remember the names.

 picture would be better: 

Spoiler

BYAy1QD.jpg

 

Log doesnt show sh*t. just meaningles gibberish:

[Exception]: NullReferenceException: Object reference not set to an instance of an object

CPU gets 2 out of 8 cores used to approx 50%

 

Win 10

I7-4790K

GTX-980ti

12288MB RAM

Link to comment
Share on other sites

OP, you obviously require an infinicomputer. They allow you do to an infinite number of things with no performance penalties. Each costs one (1) infinity dollars. See exchange rate table for international shopping.

Computers have limits. Software has limits. The universe has limits. You can't make a too-large ship. If you find the game unplayable because you want to do that and can't... well that's life. You can't.

Edited by 5thHorseman
Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...