Linux Tests

Linux Tests

Discuss everything related to running Spring on your chosen distribution of Linux.

Moderator: Moderators

Post Reply
CautionToTheWind
Posts: 272
Joined: 30 May 2006, 17:06

Linux Tests

Post 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.
User avatar
Relative
Posts: 1371
Joined: 15 Oct 2006, 13:17

Re: Linux Tests

Post 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.
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post 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)
User avatar
Relative
Posts: 1371
Joined: 15 Oct 2006, 13:17

Post 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.
CautionToTheWind
Posts: 272
Joined: 30 May 2006, 17:06

Post 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.
YokoZar
Posts: 883
Joined: 15 Jul 2007, 22:02

Re: Linux Tests

Post 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.
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post 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.
CautionToTheWind
Posts: 272
Joined: 30 May 2006, 17:06

Post 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.
YokoZar
Posts: 883
Joined: 15 Jul 2007, 22:02

Post 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.
CautionToTheWind
Posts: 272
Joined: 30 May 2006, 17:06

Post by CautionToTheWind »

Yokozar, can you point me to instructions to do what you suggest?
YokoZar
Posts: 883
Joined: 15 Jul 2007, 22:02

Post 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 :)
Scram80
Posts: 16
Joined: 02 Jun 2007, 22:17

Post 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...
CautionToTheWind
Posts: 272
Joined: 30 May 2006, 17:06

Post 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.
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

Is it actually reproducable with .cheat .crash?

I doubt it but if it is it would making fixing a lot easier.
CautionToTheWind
Posts: 272
Joined: 30 May 2006, 17:06

Post 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.
User avatar
LordMatt
Posts: 3393
Joined: 15 May 2005, 04:26

Post 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.
Kloot
Spring Developer
Posts: 1867
Joined: 08 Oct 2006, 16:58

Post by Kloot »

Stacktraces aren't generated on Linux
(due to binary identfication issues).
User avatar
LordMatt
Posts: 3393
Joined: 15 May 2005, 04:26

Post by LordMatt »

Well what is it supposed to do when it crashes?
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

Just close the window and output something like "Segmentation fault" on the console, if it was started from a console.
CautionToTheWind
Posts: 272
Joined: 30 May 2006, 17:06

Post by CautionToTheWind »

LordMatt wrote: Oo I thought it was well known that linux hangs = windows crashes.
It was not known to me.
Post Reply

Return to “Linux”