I am surprised that it seems to happen only when minimizing the window. I can't see how or why would this be in any way relevant. Are you sure that it happens only and exclusively in the cases when you minimize it, Cody? Since it appears to be quite frequent on your system (I am trying to reproduce it here and haven't made it so far), would you be able to try some normal play and see if it happens anyway when docked?Cody wrote:No difference in strict mode - still occurring. <scratches head - again>Cody wrote:... time to try without OXPs, I suppose.
CTD trunk nightly 1.83.0.6610-150824-1274242
Moderators: winston, another_commander, Getafix
-
- Quite Grand Sub-Admiral
- Posts: 6776
- Joined: Wed Feb 28, 2007 7:54 am
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
I've been at it most of the night, and it is still as described. I can reproduce it reliably (maybe one in four/five) in trunk when docked, both paused and unpaused. I've been unable to reproduce again it in 1.82, so that was a one-off, it seems - the worst sort.
@cim: it would've been the nightly immediately before 1.83.0.6610-150824-1274242 - I update whenever there is a new nightly. I'd not seen it before. The players build.
@a_c: I play in fullscreen mode, not windowed, and it is this I minimise. I've not seen any app use over 8GB of RAM - it's crazy! I am playing normally, running cross-chart contracts - this only occurs when minimised (which in my normal play, is always docked). I've not seen it happen once when in normal fullscreen mode. If I re-maximise it just before Oolite freezes, the RAM usage drops back to normal very quickly.
I need coffee!
@cim: it would've been the nightly immediately before 1.83.0.6610-150824-1274242 - I update whenever there is a new nightly. I'd not seen it before. The players build.
@a_c: I play in fullscreen mode, not windowed, and it is this I minimise. I've not seen any app use over 8GB of RAM - it's crazy! I am playing normally, running cross-chart contracts - this only occurs when minimised (which in my normal play, is always docked). I've not seen it happen once when in normal fullscreen mode. If I re-maximise it just before Oolite freezes, the RAM usage drops back to normal very quickly.
<nods> Indeed!Diziet Sma wrote:The entire Sysinternals range of tools is very useful..
I need coffee!
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!
-
- Quite Grand Sub-Admiral
- Posts: 6776
- Joined: Wed Feb 28, 2007 7:54 am
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
Sorry, you lost me there: How exactly do you minimize full screen? And what do you mean by "normal full screen"? There is only one full-screen mode and that takes up the entire screen and does not have any kind of window control. Maybe you are using a hotkey like WinKey+Down Arrow? Can you clarify this bit please?
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
By normal, I meant my normal play mode - ignore. Start+m minimises any apps to the taskbar - been using it for years.
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!
-
- Quite Grand Sub-Admiral
- Posts: 6776
- Joined: Wed Feb 28, 2007 7:54 am
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
Aha! OK, with this additional information, I have successfully reproduced the problem. Thanks Cody, that last bit has actually been very helpful. I will guess that you have the rotating player ship set to show on the status screen?
Apparently there is a memory leak in the Commander Status screen, at least (and most likely, exclusively) on Windows. Observations:

Temporary work-around: Do not be on the F5 screen if you want to minimize the full screen window, so that when you do minimize it, the leak won't trigger.
Apparently there is a memory leak in the Commander Status screen, at least (and most likely, exclusively) on Windows. Observations:
- The leak triggers only if one is in full screen on the F5 gui screen and minimizes the game by use of a hotkey, like Cody's WinKey+M (all apps minimized) or my WinKey+DnArrow (active app minimized).
- Windowed mode is fine and does not leak.
- Other GUI screens seem to not leak. Haven't tested them all though.
- To experience the leak at maximum force, have your player ship set to show on the F5 screen - memory then goes away real quick.
- The leak stops immediately once the game regains focus. With the player ship showing on F5, there seems to be a pause for a few seconds, then the ship continues to rotate once memory has been freed.
- Pausing the game is irrelevant to this problem.
- The leak is present in 1.82 too and is reproduced in the very same way as with trunk. Basically, it's been with us all along.

Temporary work-around: Do not be on the F5 screen if you want to minimize the full screen window, so that when you do minimize it, the leak won't trigger.
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
Phew! I was beginning to doubt myself - thanks! Curious that I'd never noticed it before though - and yes, I have the rotating player ship on F5.
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
The interesting thing is that it's not from your descriptions actually a leak, which would be an irritating thing to deal with but usually at least possible to track down.another_commander wrote:Apparently there is a memory leak in the Commander Status screen, at least (and most likely, exclusively) on Windows.
Oolite is keeping track of all the memory and when the whatever-it-is stops, garbage collection releases it properly. It's as if being minimised on the F5 screen is somehow suspending garbage collection. (Messing with the autorelease pools, perhaps?)another_commander wrote:[*] The leak stops immediately once the game regains focus. With the player ship showing on F5, there seems to be a pause for a few seconds, then the ship continues to rotate once memory has been freed.
But why just on the F5 screen? If it were ship models I'd expect F3F3 and many mission screens to have the same issue, and maybe even F7 with its planet - not to mention "in flight"! If it was text density F8 is quite a bit worse.
-
- Quite Grand Sub-Admiral
- Posts: 6776
- Joined: Wed Feb 28, 2007 7:54 am
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
I have really no idea why just on the F5 screen and, even more so, no clue why windowed mode doesn't leak, when fullscreen does. Full screen on Windows is nothing more than a window sized to desktop dimensions, with borders and titlebar removed. It should behave exactly like any other normal window. I am really puzzled.cim wrote:But why just on the F5 screen? If it were ship models I'd expect F3F3 and many mission screens to have the same issue, and maybe even F7 with its planet - not to mention "in flight"! If it was text density F8 is quite a bit worse.
There is one solution, which is quite common practice in other games and for which I had already written code in the past, but never commited it: disabling of the Windows key when in full screen. This would probably also simplify a lot all the code that handles hotkey switching of the game window from one monitor to another, but I would prefer to find the actual root cause of the leak problem, rather than circumvent it and only disable the Windows key as a last, desperate solution..
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
<chortles> Gotta love foxing the Admiralty!
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
I suppose another thing about the F5 screen is that it does route planning. So does F6 do it if you have an ANA route plotted ... and does F5 do it if hyperspace and current systems are the same?
-
- Quite Grand Sub-Admiral
- Posts: 6776
- Joined: Wed Feb 28, 2007 7:54 am
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
Guys, I think I got it. Stand by for a tentative fix in trunk in a while...
Edit: Commit e12a9ab should hopefully deal with this. I still haven't got a full explanation of why it happens under the conditions it happens, but the fix is simple and straightforward. Can someone <glances at Cody> please confirm that it works and try to playtest for a while to ensure nothing else has been broken?
Edit: Commit e12a9ab should hopefully deal with this. I still haven't got a full explanation of why it happens under the conditions it happens, but the fix is simple and straightforward. Can someone <glances at Cody> please confirm that it works and try to playtest for a while to ensure nothing else has been broken?
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
I'll be about it when tonight's nightly hits (so tomorrow morning) - unless you've got a
.exe
handy?I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!
-
- Quite Grand Sub-Admiral
- Posts: 6776
- Joined: Wed Feb 28, 2007 7:54 am
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
Sweet! Muchas gracias, I'll get the coffee on!
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: CTD trunk nightly 1.83.0.6610-150824-1274242
All good so far - ticking over happily at 1.4GB as I type (docked, F5, minimised).
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!