Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Pages: [1] 2

Author Topic: 0.51a - Mac - "GC overhead limit exceeded" error  (Read 18055 times)

Archduke Astro

  • Captain
  • ****
  • Posts: 456
  • 99 AU from anywhere
    • View Profile
0.51a - Mac - "GC overhead limit exceeded" error
« on: March 23, 2012, 11:25:46 PM »

Firstly, I use the Mac version of Starfarer v0.51a.

Secondly, I installed version 1.2a of DeathSG's Minimash multiple-mod compilation in order to spice up the game.

It's been flawless...with one exception, that is. And it's not strictly anything to do with the modded content directly, either; that's just a means to an end, as you'll see.

After playing the game with that set of mods for a while, the added awesome features in said mods often lead to the ability to win enough battles such that one can generate mountains of cash to buy an epic-sized warfleet. To make full use of such plunder, I tweaked my setup further to set the default battle size at 400 fleet points instead of 100. Also by my hand, system defense fleets ranging in strength up to 800FP - and more! - are now roaming the void, too; the resulting fights have been truly heroic. Many songs have been sung and much ale has been quaffed as the victors recounted their tales of pluck and derring-do. Hegemony forces celebrate by watching extra-special gladiator combat between terrified untrained file clerks from Human Resources pitted against sharks with lasers on their heads. Even those otherwise uptight Tri-Tachyon stiffs have been known to order their post-battle cup of tea with lemon (such expense!) AND an extra lump of sugar in it.  ;D

The game begins to get unstable once the overall amount of fighter wings in service, ship hulls in service, and items & money in inventory also become epic-sized. Darn. Eventually that instability crashes my gameplay session -- every time. I was surprised and confused that such apparently mundane accumulation of stuff would be a problem in an otherwise very pleasantly "finite but unbounded" game universe as this one.

Unfortunately, it is impossible for me to say what the precise trigger is which sets off the instability which eventually crashes Starfarer. I wish I could be more specific. The only reliable clue is that the game begins to lag; slowly at first, then more and more over the course of about 15-45 minutes. This surprises me because I'm running Starfarer on a Mac Pro tower with OS X 10.6.7, and the increasing amount of game lag gets so bad that it eventually smashes one entire CPU core at +90% utilization and holds it there. RAM usage doesn't escalate, but the game goes insane with CPU hogging. :-\

The inevitable end always comes when, after already having amassed a vast pile of loot, I'm randomly trying to purchase new fighters, ships or inventory items at any space station. I'll click the "Confirm Transaction" button...it lights up...but the game never acknowledges the mouse click. After anywhere from 10 seconds to 2 minutes of a frozen game screen, I'm greeted with an error message. Boom! Abend. It's always the same message every time:

"Fatal: GC overhead limit exceeded
Check starfarer.log for more info.
"

As soon as I click to dismiss the alertbox, the game crashes to desktop.

Fortunately I screencapped one recent instance of this game error--



The use of the "Confirm Transaction" button after already having a very large fleet inventory (starships as well as weapons, crew, money, etc.) is the straw which breaks the proverbial camel's back. But what is the trigger value of the too-small boundary that is being crossed, and where can it be found? And is there more than one error condition which is being met? That's what I can't figure out.

A save-game file which exhibited this same trouble previously can start freaking out even just a few minutes after rebooting the game and reloading that same save into a new gameplay session. I don't think that the save itself is being corrupted, because no matter how many times I delete it and begin a new campaign game from square one, Starfarer eventually runs into the same trouble. I've easily encountered this same bug during more than 10 consecutive gameplay sessions, within at least as many brand-new campaign games begun from square one.

These chronic freezes and crashes become even more mysterious as well as frustrating to me, precisely because there is no such file as starfarer.log in the Mac version of the game! ??? [-sigh-] Well, so much for checking the (nonexistent) debugging logs. Without that, I can't take any further useful action to help you pin down this aggravating error.

I didn't think that things such as fleet size, etc. had hardcoded limits bounding them. That IS true, isn't it??? But something within the game sure is mighty unhappy once you rack up a few more orders of magnitude. My highly informal guess is that some data register (or more than one?) within Starfarer's codebase doesn't hold enough digits to get the job done. As I have a serious penchant for very large battles plus accumulating the equally large in-game infrastructure to support them (and repair my wounds afterward, lol), I'd love it if this bug was squashed in the next version of the game.

Same thing for the grievous lack of any error-logging at all in the Mac version of this generally great game.

Any insight you can share about the exact cause and projected future bugfix for the GC overhead limit error would be deeply appreciated. Thanks!



[attachment deleted by admin]
Logged
We thought our last moment had come
when we got a message up the voice pipe
saying that 'A' Turret magazine was on fire.....

Wyvern

  • Admiral
  • *****
  • Posts: 3803
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #1 on: March 23, 2012, 11:37:53 PM »

Um.  See that red marker there that says you're at a fleet size of 2681 out of a max of 200?  That should be a clue that the game simply wasn't designed to handle quite that much stuff.  Or you can go read the latest blog, where Alex talks about his plans to actually implement the limits currently displayed in the game.

Now, if you really want to hack into things, you might have some luck by opening the package & editing the info.plist file to give java more heap space - specifically the -Xmx argument.  Of course, I can't actually guarantee that doing so will work; I accept no responsibility if such an edit, say, causes your computer to transform into a pumpkin at the stroke of midnight.  But that could be worth a try.
Logged
Wyvern is 100% correct about the math.

Archduke Astro

  • Captain
  • ****
  • Posts: 456
  • 99 AU from anywhere
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #2 on: March 23, 2012, 11:51:24 PM »

Um.  See that red marker there that says you're at a fleet size of 2681 out of a max of 200?  That should be a clue that the game simply wasn't designed to handle quite that much stuff.  Or you can go read the latest blog, where Alex talks about his plans to actually implement the limits currently displayed in the game.
Red marker, indeed. [-chuckle-] I'm not color-blind; It's self-evident that Starfarer was not designed for such player styles. ;) What I desire is to discover what can be done to gracefully allow such styles to be viable. They seem to be reliably maintained during gameplay by other modders. I've read more than one post on the Modding forum where folks are rampaging across the sector with battle fleets of similar dimension to that on my screencap, yet none of them seem to have posted that their game install suffered the same heartbreak which mine did. That led me to suspect it may be a Mac-specific bug in v0.51a. The lack of error-logging is a PITA, though.

Now, if you really want to hack into things, you might have some luck by opening the package & editing the info.plist file to give java more heap space - specifically the -Xmx argument.  Of course, I can't actually guarantee that doing so will work; I accept no responsibility if such an edit, say, causes your computer to transform into a pumpkin at the stroke of midnight.  But that could be worth a try.
Interesting info; thanks for the tip. For the time being, I'll keep that in reserve until Alex has a chance to reply to this thread.

And thank you for the very timely response!
Logged
We thought our last moment had come
when we got a message up the voice pipe
saying that 'A' Turret magazine was on fire.....

Wyvern

  • Admiral
  • *****
  • Posts: 3803
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #3 on: March 24, 2012, 12:17:15 AM »

Huh.  I could've sworn someone had bug reported this sort of thing before - but I can't find it now, so I certainly can't blame you for not finding it.  Oh, well.  My bet is that other people do run into similar problems if they push the game to too many ships, but, as I feel like my fleet is ungainly oversized at anything over about 100 fleet points (maybe 150 if I'm going low tech), I'm not really interested in trying to replicate your results myself.
Logged
Wyvern is 100% correct about the math.

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 24114
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #4 on: March 24, 2012, 09:19:54 AM »

What Wyvern said is spot on - it's a memory problem.

If you open up the package, and then open Contents/Info.plist with a text editor, then look for -Xmx256M and replace it with, say, -Xmx1024M, that should solve it.


Please note, though, that the game isn't built to accommodate this size of fleet. You might experience all sorts of other issues, from graphical glitches and low frame rates (depending on what your graphics card can handle) to crashes and a UI unsuited for managing a fleet of that size.

In the next version, your fleet will be constrained (by soft caps) to a more "reasonable" - from the game's point of view - size.
Logged

Archduke Astro

  • Captain
  • ****
  • Posts: 456
  • 99 AU from anywhere
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #5 on: March 25, 2012, 10:56:52 AM »

Thanks very much for the informative post, Alex. I bumped it up to 2048 for good measure and, save only for a modest amount of game lag - much, MUCH less than the killing amounts before! - Starfarer runs wonderfully. Thank you!

It's clearly understood that rampaging across the sector with a Giant Mega Death Armada of such dimensions - and fighting against others that are similarly huge - is not exactly what you had intended for the game. ;)

I read your latest blog post concerning Accidents in detail, and the planned soft-caps system is something I find intriguing. Since I've had little difficulty so far in crewing my vessels while also avoiding over-crowding the people aboard them, over-stuffing my hangar bays, over-cargoing my freight holds, or ever running my supplies down to zero, I see no cause of future difficulty here for my preferred style of gameplay. If I can continue to find ways to tweak the game's innards such that both friendly and enemy fleet sizes can still remain large (though perhaps not as immense as that in my screenshot, maybe), I'll be a happy customer.

Oh, and my video card may not be as robust as I'd prefer, but when operating such a big battlefleet there's nothing significantly affecting my visual enjoyment of the game.

Thanks again for your very helpful answer for my problem.
Logged
We thought our last moment had come
when we got a message up the voice pipe
saying that 'A' Turret magazine was on fire.....

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 24114
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #6 on: March 25, 2012, 11:36:50 AM »

Excellent!

I read your latest blog post concerning Accidents in detail, and the planned soft-caps system is something I find intriguing. Since I've had little difficulty so far in crewing my vessels while also avoiding over-crowding the people aboard them, over-stuffing my hangar bays, over-cargoing my freight holds, or ever running my supplies down to zero, I see no cause of future difficulty here for my preferred style of gameplay. If I can continue to find ways to tweak the game's innards such that both friendly and enemy fleet sizes can still remain large (though perhaps not as immense as that in my screenshot, maybe), I'll be a happy customer.

Just to give you a heads up - in the next version, you probably *won't* be able to tweak the game's innards to increase the fleet size - it'll be limited to 100 (+50% for a supply cost). However, once skills roll around (in particular ones that affect the number of fleet points), you should be able to tweak how those work, and the amount of fleet points you get to play with.


Although, I guess you could always turn down the fleet point costs on everything :)
Logged

Upgradecap

  • Admiral
  • *****
  • Posts: 5422
  • CEO of the TimCORP
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #7 on: March 25, 2012, 11:57:23 AM »

Wait, will you still be able to have that modded large battle size? ( more fleet points when in battle)
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 24114
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #8 on: March 25, 2012, 11:58:22 AM »

Wait, will you still be able to have that modded large battle size? ( more fleet points when in battle)

Yes, that's not affected.
Logged

Upgradecap

  • Admiral
  • *****
  • Posts: 5422
  • CEO of the TimCORP
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #9 on: March 25, 2012, 11:59:13 AM »

Wait, will you still be able to have that modded large battle size? ( more fleet points when in battle)

Yes, that's not affected.
Good to know :)
Logged

cp252

  • Admiral
  • *****
  • Posts: 586
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #10 on: March 25, 2012, 01:03:56 PM »

I hope he means fleet caps can be modded. I like deploying 8 Paragons. And 150 wings of Thunders.
We don't report it because we just sigh and restart. "Oh, my computer/the game can't cope with my ridiculous demands. Oh well."
Edit: We can't. Aww. Oh well. Time to add decimal points to all the FP costs.
« Last Edit: March 25, 2012, 01:09:49 PM by cp252 »
Logged

naufrago

  • Admiral
  • *****
  • Posts: 511
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #11 on: April 02, 2012, 08:10:42 PM »

I'd just like to add to this topic from my experience with the same issue on a Mac. I'm pretty sure that it's not just a lack of memory due to a large fleet size, I'm fairly certain there's a memory leak associated with ships (either the fleet UI or any time fleet data is looked at by the game, I'm not sure). I've run into the problem even with 'normal' sized fleets, it just takes longer; having a huge fleet only speeds up the underlying problem.

Just starting up the game, everything runs fine, but the longer I play the more CPU and memory it takes up and the more often framerate drops occur. That's pretty indicative of a memory leak.
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 24114
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #12 on: April 02, 2012, 08:38:24 PM »

Hmm. Thanks for the additional data point.

Does restarting the game and then loading the save clear it up? Also, how long are we talking about here?
Logged

naufrago

  • Admiral
  • *****
  • Posts: 511
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #13 on: April 02, 2012, 11:36:59 PM »

Exiting the save doesn't fix it, but quitting the game and re-opening seems to clear the issue right up.

Typically, I can run the game for about 30-60min with my large fleet before the stuttering gets too noticeable. I can't give an exact timeframe for a smaller fleet because it can take more than two hours, and I don't currently have that much contiguous time to bug test.

After further testing, I think it may have to do with cleaning up data either during or after a battle. To test if the fleet window was the cause, I opened the fleet window and jammed 'r' and 'f' a couple hundred times while having a fleet of over 1400FP, since those tabs seem like they'd be the most likely to reveal any memory leaks with fleet data management. The test was inconclusive. Then, I played the campaign normally, and after about 40mins, or 4-5 battles, I started noticing some stuttering. The game then froze when I went to Hidden Base's shipyard and hit esc almost immediately after clicking. I forgot to save the log, though. Derp. There is no log file for Macs apparently.

From a previous experience, I know opening the reinforcement window during battle can make the framerate problem worse, so that's another potential culprit. The reason I assumed accessing fleet data was the problem was due to the reinforcement window problem and the fact that the fleet window takes much longer to load when the problem gets bad... but, well, everything takes a lot longer to load at that point.

Actually, the reinforcement window itself can cause crashes when I right-click and drag to scroll through my ships, but I have no idea if those problems are related.

The next test would be to just let the game idle for an hour and see if the framerate stutters, but it's kind of late where I am.
« Last Edit: April 02, 2012, 11:40:17 PM by naufrago »
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 24114
    • View Profile
Re: 0.51a - Mac - "GC overhead limit exceeded" error
« Reply #14 on: April 03, 2012, 10:56:44 AM »

Thanks for the clarifications. I'll keep an eye out for this.
Logged
Pages: [1] 2