View previous topic :: View next topic |
Author |
Message |
rosinante n00b
Joined: 26 Dec 2003 Posts: 5
|
Posted: Mon Feb 09, 2004 2:33 pm Post subject: first installation: checklist |
|
|
Hi all,
I'm about to embark upon an installation from stage1, for a desktop...
* I have a pentium4 celeron, i intend to use the following compilation flags:
CHOSTS="i686-pc-linux-gnu"
CFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer"
CXXFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer"
The CFLAGS equals the CXXFLAGS setting? Why?
I have a small (128KB) L2 cache and 'slow' (celeron) processor, so it's useless to try -Os or -O3; correct?
Why is 'fomit-frame-pointer' always explicitely set? From the gcc-docs it seems that it is included in -O1 (which is included in -O2).
Would it be wise to include the following?
-fprefetch-loop-arrays
-ffast-math
-fforce-mem
-fforce-addr
-falign-functions=4
* I intend to use the following livecd,
/gentoo/experimental/x86/livecd/gentoo-2004.0-x86-20040204.iso ;
Which kernel will I get by default? 2.6? 2.6.2?
Thanks for any pointers! |
|
Back to top |
|
|
plasmagunman l33t
Joined: 07 Jun 2002 Posts: 604 Location: berlin
|
Posted: Mon Feb 09, 2004 3:36 pm Post subject: Re: first installation: checklist |
|
|
rosinante wrote: | CHOSTS="i686-pc-linux-gnu"
CFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer"
CXXFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer" |
you can make it easier to read by setting "CXXFLAGS="${CFLAGS}"", since they are the same anyway. but that's just cosmetic, it really doesn't matter.
Quote: | The CFLAGS equals the CXXFLAGS setting? Why? |
why not? CFLAGS is used by the c-compiler, CXXFLAGS by the c++-compiler. if i want my system compiled with O2 i want all applications, the c and the c++ ones, to be compiled with it. if you think c++ needs more different optimizations you can set it to a different value. actually i never saw anyone doing that, but it's possible.
Quote: | I have a small (128KB) L2 cache and 'slow' (celeron) processor, so it's useless to try -Os or -O3; correct? |
that's a dangerous question, since there are kinda wars about these O2, O3 and Os...
Quote: | Why is 'fomit-frame-pointer' always explicitely set? From the gcc-docs it seems that it is included in -O1 (which is included in -O2). |
these O? optimizations depend on your architecture. if gentoo-developers want to recommend these flag so it's better, to set it explicitely. if your architecture includes it in O1 you can remove it from your CFLAGS without problems.
btw, there is a big thread about comppiler-flags: https://forums.gentoo.org/viewtopic.php?t=5717 _________________ please, feel free to correct my english. - por favor, corrige mi español. |
|
Back to top |
|
|
plasmagunman l33t
Joined: 07 Jun 2002 Posts: 604 Location: berlin
|
Posted: Mon Feb 09, 2004 3:39 pm Post subject: Re: first installation: checklist |
|
|
rosinante wrote: | Which kernel will I get by default? 2.6? 2.6.2? |
the stable gentoo kernel is still 2.4, i think. but there is no default kernel, you can choose. _________________ please, feel free to correct my english. - por favor, corrige mi español. |
|
Back to top |
|
|
Otto[FIN] n00b
Joined: 25 Aug 2003 Posts: 22 Location: Espoo/Finland
|
Posted: Mon Feb 09, 2004 4:17 pm Post subject: Re: first installation: checklist |
|
|
rosinante wrote: |
Why is 'fomit-frame-pointer' always explicitely set? From the gcc-docs it seems that it is included in -O1 (which is included in -O2).
|
It is included in O1 if the architecture can debug if it is set. x86 architecture can not debug when -fomit-frame-pointer is set, so it is not enabled automagically by Ox, so you have to explicitely set it to get it.
At least I have understood it that way.
Otto |
|
Back to top |
|
|
rosinante n00b
Joined: 26 Dec 2003 Posts: 5
|
Posted: Mon Feb 09, 2004 6:46 pm Post subject: |
|
|
Ok, thanks all... I just read some 26 pages of 'CFLAGS Central', the freehackers website and the gcc documentation - and I still don't have a headache... so..
I'm going to compile with:
CHOST="i686-pc-linux-gnu"
CFLAGS="-march=pentium4 -O3 -pipe -fomit-frame-pointer -mmmx -msse -msse2 -mfpmath=sse,387"
CXXFLAGS="-march=pentium4 -O3 -pipe -fomit-frame-pointer -mmmx -msse -msse2 -mfpmath=sse,387"
The -mfpmath=sse,387 might break things I guess, but we'll see.. |
|
Back to top |
|
|
Otto[FIN] n00b
Joined: 25 Aug 2003 Posts: 22 Location: Espoo/Finland
|
Posted: Mon Feb 09, 2004 8:19 pm Post subject: |
|
|
rosinante wrote: |
I'm going to compile with:
CHOST="i686-pc-linux-gnu"
CFLAGS="-march=pentium4 -O3 -pipe -fomit-frame-pointer -mmmx -msse -msse2 -mfpmath=sse,387"
CXXFLAGS="-march=pentium4 -O3 -pipe -fomit-frame-pointer -mmmx -msse -msse2 -mfpmath=sse,387"
|
I think the mmmx, msse and msse2 will be turned on by default by pentium4, but I'm not sure. They will at least not hurt there if they are turned on by default.
http://www.freehackers.org/gentoo/gccflags/faq.html
Otto |
|
Back to top |
|
|
rosinante n00b
Joined: 26 Dec 2003 Posts: 5
|
Posted: Mon Feb 09, 2004 8:26 pm Post subject: |
|
|
Otto[FIN] wrote: |
I think the mmmx, msse and msse2 will be turned on by default by pentium4, but I'm not sure. They will at least not hurt there if they are turned on by default.
Otto |
Yes, true.. but the long reading of 'cflags central' made me think twice... I'm unsure about it, but I guess including them wouldn't hurt either?
Anyway, I'm going to ask around in 'cflags central' before I compile :) |
|
Back to top |
|
|
|