Page 1 of 1
Linux Tests
Posted: 18 Oct 2007, 14:50
by CautionToTheWind
I have been testing Spring in Kubuntu Feisty 32bit from the packages and self-compiled, and also under the 2.6.22 and 2.6.23 kernels. Some notes for those that might find it useful:
- The binary i compiled myself gained a noticeable increase in FPS. Maybe over 10%, which surprised me.
- The new kernel .23 and CFS scheduler make little difference since Spring is run alone without other big tasks and that situation is too simple to notice scheduler improvements.
- It still hangs (rarelly) in Linux. It does so in both kernels, compiled by me or not, and regardless of running Spring over my desktop or in a separate X session. When it hangs, the last drawn frame stays displayed, Spring stops using CPU and the rest of the system keeps working fine.
AMD 4600+ CPU, nv6 chipset, nvidia 7600GTS.
Re: Linux Tests
Posted: 18 Oct 2007, 17:02
by Relative
CautionToTheWind wrote:
- It still hangs (rarelly) in Linux. It does so in both kernels, compiled by me or not, and regardless of running Spring over my desktop or in a separate X session. When it hangs, the last drawn frame stays displayed, Spring stops using CPU and the rest of the system keeps working fine.
AMD 4600+ CPU, nv6 chipset, nvidia 7600GTS.
I too have had this problem since I started using spring on ubuntu. At first I thought it was just the ATi drivers crapping themselves so I never bothered to report it. Then after I built my current PC I noticed it still continued despite now having a Nvidia card. I think I have mentioned it a couple of times, but there is never any stacktrace or actions that explain it. It happens irregardless of whether I use a package or compile myself. It happens very very rarely rarely (1 out a 100).
Old Spec:
Intel Northwood @ 2.6Ghz, crappy generic dell motherboard that I can't remember, ATi 9800 pro
New:
E6750, intel P35, 8600 GTS
Kernels:All of them since about 6-7 months ago when I started using spring on ubuntu.
Posted: 18 Oct 2007, 17:27
by Tobi
Did anyone already try to attach a debugger (gdb) to Spring (compiled with debugging enabled of course

) when it hangs?
(would probably need another PC and ssh for that I guess, unless you can still switch to a console using e.g. ctrl+alt+F1)
Posted: 18 Oct 2007, 17:39
by Relative
Tobi wrote:Did anyone already try to attach a debugger (gdb) to Spring (compiled with debugging enabled of course

) when it hangs?
(would probably need another PC and ssh for that I guess, unless you can still switch to a console using e.g. ctrl+alt+F1)
How can you run spring gdb after it happens? Also its so unpredictable and rare it would require having a debugger on at all times, and you might not ever get it.
Posted: 18 Oct 2007, 20:47
by CautionToTheWind
I did that. Tobi told me how to do it and shared some scripts, and i replaced my install with a 100Mb debug binary running in gdb and saving the backtrace (using the windows lobby in wine, it was quite the monster my install). I sent you a few backtraces but unfortunately they were never useful.
Later on I had to stop playing Spring for some time and then did a clean install of the Linux and didn't set up the whole gdb stuff again.
Re: Linux Tests
Posted: 19 Oct 2007, 08:16
by YokoZar
CautionToTheWind wrote:I have been testing Spring in Kubuntu Feisty 32bit from the packages and self-compiled, and also under the 2.6.22 and 2.6.23 kernels. Some notes for those that might find it useful:
- The binary i compiled myself gained a noticeable increase in FPS. Maybe over 10%, which surprised me.
What kind of CPU and compile options are you using? The packages are built in pbuilder on my Athlon 64 box with defaultish options.
If you have something later (or an intel CPU), it wouldn't surprise me if you were getting a more optimized build.
Posted: 19 Oct 2007, 09:48
by Tobi
Well if it would automatically assume -march= options I doubt the difference would be that big... I tried some of those once and didn't measure a single % speed difference.
Posted: 19 Oct 2007, 12:26
by CautionToTheWind
I just didn't change any options whatsoever. I apt-get install the dependency packages and then run scons configure and scons. With an AMD cpu. And with whatever default options Kubuntu ships with.
Posted: 20 Oct 2007, 01:59
by YokoZar
CautionToTheWind wrote:I just didn't change any options whatsoever. I apt-get install the dependency packages and then run scons configure and scons. With an AMD cpu. And with whatever default options Kubuntu ships with.
Hmm...
The default options when compiling in a terminal might not be the same as the defaults in the package build rules.
If I could trouble you to make a test, build the
package from source. If you know how to do it from the files in the link I gave, do that.
Otherwise, just wait for me to get the repository working and then you can do apt-get --build source.
Posted: 20 Oct 2007, 23:11
by CautionToTheWind
Yokozar, can you point me to instructions to do what you suggest?
Posted: 22 Oct 2007, 08:16
by YokoZar
CautionToTheWind wrote:Yokozar, can you point me to instructions to do what you suggest?
http://spring.clan-sy.com/phpbb/viewtopic.php?t=12469
apt-get update
apt-get build-dep spring
apt-get --build source spring
Then you'll get your own deb to play with :)
Posted: 23 Oct 2007, 13:30
by Scram80
I did backtraces on a few of these 'black last frame' hangs, too.
I don't have them around anymore, but what i noticed in every:
it did hang in the SDL Sig11 handler
in most times the exception seemed to have been caused by malloc or free
so i assume there is heap memory corruption going on somewhere...
Posted: 26 Oct 2007, 13:50
by CautionToTheWind
I've had an interesting new development on the linux hangs. Yesterday i hanged, and when i closed it and cursed, i noticed someone else cursing in the lobby. Turns out he crashed at the same time i "hanged". I asked, and he is running Vista, not Linux.
Maybe it could be that the linux hangs are the same as the regular windows crashes (Spring has crashed dialog), but because of platform differences the failure mode is different?
That would still leave some crashes to fix, but imho much better than having a tricky platform specific bug that won't show its damm head.
Posted: 26 Oct 2007, 16:19
by Tobi
Is it actually reproducable with .cheat .crash?
I doubt it but if it is it would making fixing a lot easier.
Posted: 26 Oct 2007, 21:42
by CautionToTheWind
.cheat .crash behaves like a clean exit to me. It doesn't hang on the last frame. Instead it closes and the rest of my spring script runs as normal.
Posted: 27 Oct 2007, 00:00
by LordMatt
CautionToTheWind wrote:I've had an interesting new development on the linux hangs. Yesterday i hanged, and when i closed it and cursed, i noticed someone else cursing in the lobby. Turns out he crashed at the same time i "hanged". I asked, and he is running Vista, not Linux.
Maybe it could be that the linux hangs are the same as the regular windows crashes (Spring has crashed dialog), but because of platform differences the failure mode is different?
That would still leave some crashes to fix, but imho much better than having a tricky platform specific bug that won't show its damm head.
Oo I thought it was well known that linux hangs = windows crashes. This happens to me quite commonly, that when I hang someone else crashes. I have never had spring produce a proper crash in infolog.txt.
Posted: 27 Oct 2007, 00:13
by Kloot
Stacktraces aren't generated on Linux
(due to binary identfication issues).
Posted: 27 Oct 2007, 00:31
by LordMatt
Well what is it supposed to do when it crashes?
Posted: 27 Oct 2007, 11:32
by Tobi
Just close the window and output something like "Segmentation fault" on the console, if it was started from a console.
Posted: 27 Oct 2007, 12:31
by CautionToTheWind
LordMatt wrote:
Oo I thought it was well known that linux hangs = windows crashes.
It was not known to me.