From: "Andrey Gerasimenko" <gak@kaluga.ru>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] CFLAGS "...-O3 -pipe" vs "...O2 <no pipe>"
Date: Mon, 09 Apr 2007 09:47:20 +0400 [thread overview]
Message-ID: <op.tqh406zzv2ynd8@pavillion> (raw)
In-Reply-To: <739325.15429.qm@web31706.mail.mud.yahoo.com>
On Mon, 09 Apr 2007 05:48:07 +0400, maxim wexler <blissfix@yahoo.com>
wrote:
> Hi group,
>
> I note two schools of thought on the best CFLAGS for
> the Pentium III processor.
>
> One suggests using -O3 -pipe, the other, -O2 without
> the pipe.
>
> How much difference does this make? Is the extra level
> of optimization with pipe the equivalent of the lower
> level without?
>
Man gcc. -pipe allows to use pipes (memory) instead of temporary files
(disk). -O controls the resulting binary sometimes making it fast, large,
and unreliable. I have seen ebuilds that enforce -O2 even when -O3 is
specified. This can create a faulty impression that -O3 always works fine.
-O and -pipe interact through the size of temporary files. Theoretically,
-pipes may slow down compiles if there is not enough memory. Another
factor that should be taken into account is the number of threads for
make. For a PIII machine the generally recommended number is 2, but when
the RAM is limited, say 384 megs, 1 thread with pipes works better.
Ideally you should measure compile times for large projects like Open
Office and find out what works best on your system. I would start with 1
thread -O2 and -pipe.
--
Andrei Gerasimenko
--
gentoo-user@gentoo.org mailing list
next prev parent reply other threads:[~2007-04-09 5:52 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-09 1:48 [gentoo-user] CFLAGS "...-O3 -pipe" vs "...O2 <no pipe>" maxim wexler
2007-04-09 1:57 ` Sascha Hlusiak
2007-04-09 5:47 ` Andrey Gerasimenko [this message]
2007-04-09 8:28 ` Neil Bothwick
2007-04-09 12:40 ` [gentoo-user] " Alexander Skwar
2007-04-09 13:43 ` Francisco Rivas
2007-04-10 14:29 ` maxim wexler
2007-04-10 14:58 ` Uwe Thiem
2007-04-10 15:17 ` Bo Ørsted Andresen
2007-04-10 15:29 ` Francisco Rivas
2007-04-10 15:55 ` Tony Stohne
2007-04-10 16:40 ` Andrey Vul
2007-04-10 18:48 ` maxim wexler
2007-04-10 19:01 ` Francisco Rivas
2007-04-10 19:10 ` Davi
2007-04-10 19:45 ` Uwe Thiem
2007-04-10 19:50 ` Bo Ørsted Andresen
2007-04-10 19:56 ` Jesús Guerrero
2007-04-10 20:08 ` Davi
2007-04-10 20:15 ` Jesús Guerrero
2007-04-10 20:24 ` Davi
2007-04-10 22:03 ` Ryan Sims
2007-04-11 0:34 ` Davi
2007-04-11 10:02 ` [gentoo-user] " Alexander Skwar
2007-04-10 21:22 ` [gentoo-user] " Uwe Thiem
2007-04-10 21:08 ` Dan Farrell
2007-04-10 19:52 ` Renat Golubchyk
2007-04-10 19:39 ` Uwe Thiem
2007-04-11 9:39 ` Daniel Iliev
2007-04-11 10:08 ` Bo Ørsted Andresen
2007-04-11 10:56 ` Daniel Iliev
2007-04-11 11:05 ` Davi
2007-04-11 11:44 ` Bo Ørsted Andresen
2007-04-11 12:37 ` Francisco Rivas
2007-04-11 12:45 ` Daniel Iliev
2007-04-10 15:29 ` Jesús Guerrero
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=op.tqh406zzv2ynd8@pavillion \
--to=gak@kaluga.ru \
--cc=gentoo-user@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox