GCC 4.4.1 static build

Discussion and help for Compilation problems and platform portability.

Moderators: Dade, coordinators

Re: GCC 4.4.1 static build

Postby SATtva » Fri Oct 16, 2009 12:02 pm

Okay guys, I have finally been able to produce fully static Lux build on GCC 4.4.1 (with libgcc and libstdc++ statically linked). Well, actually it was already completed yesterday when I asked about that "Illegal instruction" error. The problem was indeed in sse4{.1} instruction sets which are not supported on Athlon64 (I have no idea why the previous experiment was a success, maybe I removed -msse4 and 4.1 for that particular build, I can't remember). After removing these flags the build runs on both AMD and Intel machines, however on Q9300 performance has slightly dropped down (from 165k to 160k on fullcornell scene), but on Athlon64 I have a proportional improvement over GCC 4.3 build: 71k vs 68k.

If you can suggest me the most appropriate mtune/march specs and what instruction sets to include, I could produce weekly builds on GCC 4.4.
Linux builds packager
聞くのは一時の恥、聞かぬのは一生の恥
User avatar
SATtva
Developer
 
Posts: 7164
Joined: Tue Apr 07, 2009 12:19 pm
Location: from Siberia with love

Re: GCC 4.4.1 static build

Postby tomb » Fri Oct 16, 2009 12:40 pm

Sweet! That would be a great service to the community! :) Both x64 and ia32?
I usually use -mfpmath=sse -msse -msse2 -msse3 -mssse3 as extra flags and leave march alone. Maybe Jeanphi or Dade has some more input.

T
User avatar
tomb
Developer
 
Posts: 2677
Joined: Thu Oct 11, 2007 4:23 pm
Location: Oslo, Norway

Re: GCC 4.4.1 static build

Postby SATtva » Fri Oct 16, 2009 12:56 pm

Both x64 and ia32?

x64 for sure. As to 32 bits, I still have to figure out a cross-compiler (not a big problem on gentoo).

I usually use -mfpmath=sse -msse -msse2 -msse3 -mssse3 as extra flags and leave march alone.

Very interesting... On my last tests with cubo scene the Q9300 node produced ~238k spp. Since then I linked our problem GCC libs statically and removed mtune/march altogether, and performance has raised up to 246k spp. Is this okay? :)
Linux builds packager
聞くのは一時の恥、聞かぬのは一生の恥
User avatar
SATtva
Developer
 
Posts: 7164
Joined: Tue Apr 07, 2009 12:19 pm
Location: from Siberia with love

Re: GCC 4.4.1 static build

Postby tomb » Fri Oct 16, 2009 3:52 pm

You mean is it ok to take away march? If so, sure. Or else I'm in trouble already ;)
If that's not what you mean then please elaborate, it's friday after all ;)
User avatar
tomb
Developer
 
Posts: 2677
Joined: Thu Oct 11, 2007 4:23 pm
Location: Oslo, Norway

Re: GCC 4.4.1 static build

Postby SATtva » Fri Oct 16, 2009 4:16 pm

Looks like it's okay to remove it as long as you provide the correct list of instruction sets for the target architecture (at least the program works normally on both machines). But I won't bet it was the real reason behind the additional performance gain. :)

EDIT: By the way, there is an error in my previous post: I said that last test on cubo has shown 238k, but it was 243k -- with jeanphi's optimization flags. But still the current result is a little better.
Linux builds packager
聞くのは一時の恥、聞かぬのは一生の恥
User avatar
SATtva
Developer
 
Posts: 7164
Joined: Tue Apr 07, 2009 12:19 pm
Location: from Siberia with love

Re: GCC 4.4.1 static build

Postby SATtva » Sat Oct 17, 2009 5:25 am

I have an i686 compiler toolchain. I was able to build most of the required dependencies, but has stuck with wxGTK and its dependency on X libs and OpenGL, agrrrh!
Linux builds packager
聞くのは一時の恥、聞かぬのは一生の恥
User avatar
SATtva
Developer
 
Posts: 7164
Joined: Tue Apr 07, 2009 12:19 pm
Location: from Siberia with love

Re: GCC 4.4.1 static build

Postby SATtva » Sat Oct 17, 2009 10:46 am

I have to admit that trying to mix both toolchains in one system wasn't a good idea. Now I decided to choose a more easy route, and now creating another building environment alongside the first one solely for i686 compilation. It is 1.5x disk space (which is cheap), but 0.1x headaches (and nerves are expensive). :)
Linux builds packager
聞くのは一時の恥、聞かぬのは一生の恥
User avatar
SATtva
Developer
 
Posts: 7164
Joined: Tue Apr 07, 2009 12:19 pm
Location: from Siberia with love

Re: GCC 4.4.1 static build

Postby SATtva » Sat Oct 17, 2009 5:23 pm

Now I also have an ia32 Lux build. But problems are not over yet:

Code: Select all
$ readelf -d luxrender | grep NEEDED
 0x00000001 (NEEDED)                     Shared library: [libGL.so.1]
 0x00000001 (NEEDED)                     Shared library: [libGLU.so.1]
 0x00000001 (NEEDED)                     Shared library: [libgtk-x11-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libgdk-x11-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libatk-1.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libgio-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libpangoft2-1.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libgdk_pixbuf-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libpango-1.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libfreetype.so.6]
 0x00000001 (NEEDED)                     Shared library: [libfontconfig.so.1]
 0x00000001 (NEEDED)                     Shared library: [libgobject-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libgmodule-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libgthread-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [librt.so.1]
 0x00000001 (NEEDED)                     Shared library: [libglib-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libSM.so.6]
 0x00000001 (NEEDED)                     Shared library: [libpng12.so.0]
 0x00000001 (NEEDED)                     Shared library: [libz.so.1]
 0x00000001 (NEEDED)                     Shared library: [libdl.so.2]
 0x00000001 (NEEDED)                     Shared library: [libICE.so.6]
 0x00000001 (NEEDED)                     Shared library: [libX11.so.6]
 0x00000001 (NEEDED)                     Shared library: [libXext.so.6]
 0x00000001 (NEEDED)                     Shared library: [libm.so.6]
 0x00000001 (NEEDED)                     Shared library: [libpthread.so.0]
 0x00000001 (NEEDED)                     Shared library: [libc.so.6]
 0x00000001 (NEEDED)                     Shared library: [ld-linux.so.2]


Other tools are "clean" (they all have identical dynamic links, so I'll copy only from luxconsole):
Code: Select all
$ readelf -d luxconsole | grep NEEDED
 0x00000001 (NEEDED)                     Shared library: [libpthread.so.0]
 0x00000001 (NEEDED)                     Shared library: [libpng12.so.0]
 0x00000001 (NEEDED)                     Shared library: [libz.so.1]
 0x00000001 (NEEDED)                     Shared library: [libm.so.6]
 0x00000001 (NEEDED)                     Shared library: [libc.so.6]
 0x00000001 (NEEDED)                     Shared library: [ld-linux.so.2]


EDIT: Or maybe luxrender links are not a problem at all? I don't have a pure i686 system with X Window at hand, so can't test by myself. Somebody want to test?
Linux builds packager
聞くのは一時の恥、聞かぬのは一生の恥
User avatar
SATtva
Developer
 
Posts: 7164
Joined: Tue Apr 07, 2009 12:19 pm
Location: from Siberia with love

Re: GCC 4.4.1 static build

Postby tomb » Sat Oct 17, 2009 6:54 pm

The ia32 deps seems about right to me - similar to mine actually:

Code: Select all
 0x00000001 (NEEDED)                     Shared library: [libgtk-x11-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libgdk-x11-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libatk-1.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libpangoft2-1.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libgdk_pixbuf-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libgio-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libpango-1.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libfreetype.so.6]
 0x00000001 (NEEDED)                     Shared library: [libfontconfig.so.1]
 0x00000001 (NEEDED)                     Shared library: [libgobject-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libgmodule-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libgthread-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [librt.so.1]
 0x00000001 (NEEDED)                     Shared library: [libglib-2.0.so.0]
 0x00000001 (NEEDED)                     Shared library: [libXinerama.so.1]
 0x00000001 (NEEDED)                     Shared library: [libSM.so.6]
 0x00000001 (NEEDED)                     Shared library: [libdl.so.2]
 0x00000001 (NEEDED)                     Shared library: [libGLU.so.1]
 0x00000001 (NEEDED)                     Shared library: [libGL.so.1]
 0x00000001 (NEEDED)                     Shared library: [libICE.so.6]
 0x00000001 (NEEDED)                     Shared library: [libX11.so.6]
 0x00000001 (NEEDED)                     Shared library: [libXext.so.6]
 0x00000001 (NEEDED)                     Shared library: [libstdc++.so.6]
 0x00000001 (NEEDED)                     Shared library: [libm.so.6]
 0x00000001 (NEEDED)                     Shared library: [libgcc_s.so.1]
 0x00000001 (NEEDED)                     Shared library: [libpthread.so.0]
 0x00000001 (NEEDED)                     Shared library: [libc.so.6]
 0x00000001 (NEEDED)                     Shared library: [libexpat.so.1]


I can test it if you want to be sure. Or you could just post the builds in the weekly testing builds forum and have many test it :)
If you do start doing weekly builds, including a changelog would be nice so ppl can more easily see what they are testing.
Also a blurb stating that the HEAD (tip) is in flux and may or may not work at all is probably a good idea.
Especially now after 0.6 has gone gold, a lot of stuff will be committed in extremely varied stages of testedness (if there is such a word :))
The weekly builds are neither alpha nor beta or rc's - just devel snapshots to play with.

T
User avatar
tomb
Developer
 
Posts: 2677
Joined: Thu Oct 11, 2007 4:23 pm
Location: Oslo, Norway

Re: GCC 4.4.1 static build

Postby SATtva » Sun Oct 18, 2009 3:49 am

I'd be glad if you can test it: http://vladmiller.info/lux/lux-gcc44-ia ... 18.tar.bz2
It's better to have a one angry tester than a hundred of them. :D

And thank you for suggestions. I need to polish my building environment a little more to produce builds in a more automated fashion. And if there is no stoppers in ia32 binaries, I'll be ready for weekly builds.
Linux builds packager
聞くのは一時の恥、聞かぬのは一生の恥
User avatar
SATtva
Developer
 
Posts: 7164
Joined: Tue Apr 07, 2009 12:19 pm
Location: from Siberia with love

PreviousNext

Return to Compilation & Portability

Who is online

Users browsing this forum: No registered users and 2 guests