Jump to content

KSP OpenGL RAM magic


Recommended Posts

I was overjoyed when I recently tried the -force-opengl option with KSP and found its memory footprint reduced from over 3.7GB (unplayable on 32bit) to stable 1.9GB.

Then it started crashing again so I set out to find the cause and I couldn't believe what I found. The reason was I ran out of RAM completely - I hit the 7GB limit for apps on my 8GB RAM laptop, the sole culprit being KSP.

Javascript is disabled. View full album

How is that possible? How could simply running a 32bit KSP encumber the memory so much? Magic?

Link to comment
Share on other sites

That's one of two possible things. One is that you have a video card built into the motherboard that actually uses some of the system's RAM as video memory.

The other is quite simply one heck of a memory leak, and I'm sure it's not surprising to find that if it's using that much RAM, you're going to have issues. OpenGL is not as stable as it ought to be on all video cards, especially those designed and optimised for use with DirectX.

Link to comment
Share on other sites

AFAIK, OpenGL does not actually reduce your actual memory footprint - it simply optimizes your memory usage.

To put it simple:

- DirectX loads it all and keeps it all in one process, and since there is a 3.7 Gb cap on 32-bit, it cannot go past that point.

- OpenGL also loads it all, but it uses only what is needed at the moment, allowing stuff that is currently unused reside in the background, ready to be called for. Hence, it allows you to step over 3.7 Gb barrier - until one of two things happen: the actual memory usage caps the barrier, or you run out of RAM.

OpenGL is WAY more optimized than DirectX; sadly, you need a very skilled programmer to use it effectively, and obviously, guys from Unity are not that skilled.

That being said, OpenGL is NOT an option for a weak PCs. On the contrary, you need a good machine with lots of RAM in order to use it up to its potential.

Edited by biohazard15
Link to comment
Share on other sites

That's one of two possible things. One is that you have a video card built into the motherboard that actually uses some of the system's RAM as video memory.

The other is quite simply one heck of a memory leak, and I'm sure it's not surprising to find that if it's using that much RAM, you're going to have issues. OpenGL is not as stable as it ought to be on all video cards, especially those designed and optimised for use with DirectX.

I have 1.5GB VRAM GTX660m so I doubt that.

AFAIK, OpenGL does not actually reduce your actual memory footprint - it simply optimizes your memory usage.

To put it simple:

- DirectX loads it all and keeps it all in one process, and since there is a 3.7 Gb cap on 32-bit, it cannot go past that point.

- OpenGL also loads it all, but it uses only what is needed at the moment, allowing stuff that is currently unused reside in the background, ready to be called for. Hence, it allows you to step over 3.7 Gb barrier - until one of two things happen: the actual memory usage caps the barrier, or you run out of RAM.

OpenGL is WAY more optimized than DirectX; sadly, you need a very skilled programmer to use it effectively, and obviously, guys from Unity are not that skilled.

That being said, OpenGL is NOT an option for a weak PCs. On the contrary, you need a good machine with lots of RAM in order to use it up to its potential.

So I need 16GB RAM to play KSP 32bit with mods? Wow.

I think it probably has something to do with the EVE mod as the crashing started happening when it played around with it. I'll look further into it.

Link to comment
Share on other sites

So I need 16GB RAM to play KSP 32bit with mods? Wow.

It wouldn't do you any good, since 32 bit executable cannot index all of it anyway. 3.7GB is the hard cap - period, regardless of how much ram you have.

Link to comment
Share on other sites

It wouldn't do you any good, since 32 bit executable cannot index all of it anyway. 3.7GB is the hard cap - period, regardless of how much ram you have.

Not in this case since it takes up nearly 5GB already. As vexx32 said there's probably some kind of memory leak going on.

Link to comment
Share on other sites

I have 1.5GB VRAM GTX660m so I doubt that.

So I need 16GB RAM to play KSP 32bit with mods? Wow.

I think it probably has something to do with the EVE mod as the crashing started happening when it played around with it. I'll look further into it.

I have 12 Gb, and I'm not hitting anything; but there are memory leaks, indeed - be it Unity itself, KSP or some mod. Currently, I start at 2.7 Gb, and after several hours of gameplay it approaches 3.5 Gb - I usually restart the game at this point in order to avoid sudden crashes.

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...