* [gentoo-dev] [RFC] CFLAGS paragraph for the GWN
@ 2006-09-30 20:35 Lionel Bouton
2006-09-30 20:58 ` Dominique Michel
` (3 more replies)
0 siblings, 4 replies; 16+ messages in thread
From: Lionel Bouton @ 2006-09-30 20:35 UTC (permalink / raw
To: gentoo-dev
Hi, I just had an unpleasant experience with -ffast-math and GCC 4.1.1
(it borked my LDAP authentication on several systems which worked with
the same CFLAGS as long as GCC 3.4.6 was used).
There is a lot of material out there about CFLAGS and Gentoo (google
returns 387000 pages) but what's working for someone might not for
another. There are flags that work for a GCC version and most ebuilds
and don't work with another GCC version (my unfortunate experience) or
some ebuilds. Flag combination/architecture/LDFLAGS might be an issue too.
There are already good resources (http://gentoo-wiki.com/CFLAGS_matrix
was mentioned to me by robbat2) but they may not be advertised enough.
I'd like to propose a paragraph to the GWN editor which presents some
gotchas and good references on the subject.
Here's a draft for review. You're welcomed to expand on the subject.
--- Draft BEGIN ---
<section>
<title>CFLAGS</title>
<body>
<p>
Being able to tune the CFLAGS is part of one of the core principles of
Gentoo: let the user be in control. Being in control brings both
benefits and problems and CFLAGS tuning is not an exception.
</p>
<p>
The recent upgrade to gcc-4.1.1 for x86 and amd64 users changed the
landscape. Users that spent some time tuning their CFLAGS with gcc-3.4.6
might find out that an upgrade to gcc-4.1.1 leaves them with an unstable
system. Example of this are :
<ul>
<li>nss_ldap stopped working with -ffast-math</li>
<li>...</li>
</ul>
</p>
<p>
Users with unsupported CFLAGS (see the <uri
link='http://gentoo-wiki.com/CFLAGS_matrix'>CFLAGS matrix</uri> for
example) might want to return to safe CFLAGS (see <uri
link='http://gentoo-wiki.com/Safe_Cflags'>Safe CFLAGS</uri>) if recent
updates caused them stability problems. On the other hand, more
adventurous users might want to experiment with CFLAGS that didn't work
properly with gcc-3.4.6... As always, the user is in control.
</p>
</body>
</section>
--- Draft END ---
If possible, I'd like to expand the list of 3.4.6 -> 4.1.1 upgrade
problems which are linked to experimental CFLAGS. If you want to expand
the subject to cover other tuning/stability gotchas that recent updates
might have brought into the light, please feel free to do so. As English
is not my native tongue, feel free to spell check too.
Cheers,
Lionel.
--
gentoo-dev@gentoo.org mailing list
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [gentoo-dev] [RFC] CFLAGS paragraph for the GWN
2006-09-30 20:35 [gentoo-dev] [RFC] CFLAGS paragraph for the GWN Lionel Bouton
@ 2006-09-30 20:58 ` Dominique Michel
2006-09-30 21:48 ` Mike Frysinger
` (2 subsequent siblings)
3 siblings, 0 replies; 16+ messages in thread
From: Dominique Michel @ 2006-09-30 20:58 UTC (permalink / raw
To: gentoo-dev
Le Sat, 30 Sep 2006 22:35:58 +0200,
Lionel Bouton <lionel-dev@bouton.name> a écrit :
> Hi, I just had an unpleasant experience with -ffast-math and GCC 4.1.1
> (it borked my LDAP authentication on several systems which worked with
> the same CFLAGS as long as GCC 3.4.6 was used).
>
> There is a lot of material out there about CFLAGS and Gentoo (google
> returns 387000 pages) but what's working for someone might not for
> another. There are flags that work for a GCC version and most ebuilds
> and don't work with another GCC version (my unfortunate experience) or
> some ebuilds. Flag combination/architecture/LDFLAGS might be an issue too.
>
> There are already good resources (http://gentoo-wiki.com/CFLAGS_matrix
> was mentioned to me by robbat2) but they may not be advertised enough.
> I'd like to propose a paragraph to the GWN editor which presents some
> gotchas and good references on the subject.
>
> Here's a draft for review. You're welcomed to expand on the subject.
>
> --- Draft BEGIN ---
> <section>
> <title>CFLAGS</title>
> <body>
>
> <p>
> Being able to tune the CFLAGS is part of one of the core principles of
> Gentoo: let the user be in control. Being in control brings both
> benefits and problems and CFLAGS tuning is not an exception.
> </p>
> <p>
> The recent upgrade to gcc-4.1.1 for x86 and amd64 users changed the
> landscape. Users that spent some time tuning their CFLAGS with gcc-3.4.6
> might find out that an upgrade to gcc-4.1.1 leaves them with an unstable
> system. Example of this are :
> <ul>
> <li>nss_ldap stopped working with -ffast-math</li>
> <li>...</li>
> </ul>
> </p>
> <p>
> Users with unsupported CFLAGS (see the <uri
> link='http://gentoo-wiki.com/CFLAGS_matrix'>CFLAGS matrix</uri> for
> example) might want to return to safe CFLAGS (see <uri
> link='http://gentoo-wiki.com/Safe_Cflags'>Safe CFLAGS</uri>) if recent
> updates caused them stability problems. On the other hand, more
> adventurous users might want to experiment with CFLAGS that didn't work
> properly with gcc-3.4.6... As always, the user is in control.
> </p>
> </body>
> </section>
> --- Draft END ---
>
> If possible, I'd like to expand the list of 3.4.6 -> 4.1.1 upgrade
> problems which are linked to experimental CFLAGS. If you want to expand
> the subject to cover other tuning/stability gotchas that recent updates
> might have brought into the light, please feel free to do so. As English
> is not my native tongue, feel free to spell check too.
>
> Cheers,
>
> Lionel.
My personal experience with other CFLAGS as the ones in the handbook is at
gcc-4.1.1 have a better optimisation with the default gentoo CFLAGS. Even
with -O2, the result is a faster system, and -O3 seam to be safer with math
related applications as with gcc-3.4.*.
But in the other hand, other flags seam to be more problematic as with
gcc-3.4.*. And the new optimisations flags as the vectorisation flags are not
easy to use, because the result depend on the code of the program. They can or
not brake the code, and when the program run well, they can make it faster
or slower. All depend of the size and complexity of the loops. And I think also
of the arch.
So my conclusion is:
For system flags, just keep the default, and if you want to experiment, do
profiling for each single program you want to optimize.
Cheers,
Dominique
--
Dominique Michel
--
gentoo-dev@gentoo.org mailing list
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [gentoo-dev] [RFC] CFLAGS paragraph for the GWN
2006-09-30 20:35 [gentoo-dev] [RFC] CFLAGS paragraph for the GWN Lionel Bouton
2006-09-30 20:58 ` Dominique Michel
@ 2006-09-30 21:48 ` Mike Frysinger
2006-09-30 22:42 ` Lionel Bouton
2006-09-30 21:48 ` Ryan Hill
2006-10-01 0:37 ` [gentoo-dev] " George Prowse
3 siblings, 1 reply; 16+ messages in thread
From: Mike Frysinger @ 2006-09-30 21:48 UTC (permalink / raw
To: gentoo-dev
[-- Attachment #1: Type: text/plain, Size: 864 bytes --]
On Saturday 30 September 2006 16:35, Lionel Bouton wrote:
> There is a lot of material out there about CFLAGS
`man gcc` always seemed fine to me
in fact, lets read the -ffast-math section:
-ffast-math
This option should never be turned on by any -O option since it can
result in incorrect output for programs which depend on an exact
implementation of IEEE or ISO rules/specifications for math func-
tions.
this flag is never safe to use in CFLAGS
> link='http://gentoo-wiki.com/CFLAGS_matrix'
no way will our documentation link to gentoo-wiki.com
> If possible, I'd like to expand the list of 3.4.6 -> 4.1.1 upgrade
> problems which are linked to experimental CFLAGS
i find maintaining a list of "safe" CFLAGS on a per-gcc basis to be a waste of
time ... but that's just me
-mike
[-- Attachment #2: Type: application/pgp-signature, Size: 827 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* [gentoo-dev] Re: [RFC] CFLAGS paragraph for the GWN
2006-09-30 20:35 [gentoo-dev] [RFC] CFLAGS paragraph for the GWN Lionel Bouton
2006-09-30 20:58 ` Dominique Michel
2006-09-30 21:48 ` Mike Frysinger
@ 2006-09-30 21:48 ` Ryan Hill
2006-09-30 21:52 ` Robin H. Johnson
2006-10-01 0:37 ` [gentoo-dev] " George Prowse
3 siblings, 1 reply; 16+ messages in thread
From: Ryan Hill @ 2006-09-30 21:48 UTC (permalink / raw
To: gentoo-dev
[-- Attachment #1: Type: text/plain, Size: 807 bytes --]
Lionel Bouton wrote:
> There are already good resources (http://gentoo-wiki.com/CFLAGS_matrix
> was mentioned to me by robbat2) but they may not be advertised enough.
Most of the info on that page is wrong.
> I'd like to propose a paragraph to the GWN editor which presents some
> gotchas and good references on the subject.
Honestly, the only good reference is the Safe CFLAGS page.
> If possible, I'd like to expand the list of 3.4.6 -> 4.1.1 upgrade
> problems which are linked to experimental CFLAGS. If you want to expand
> the subject to cover other tuning/stability gotchas that recent updates
> might have brought into the light, please feel free to do so. As English
> is not my native tongue, feel free to spell check too.
The english and speeling seem fine.
--de.
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [gentoo-dev] Re: [RFC] CFLAGS paragraph for the GWN
2006-09-30 21:48 ` Ryan Hill
@ 2006-09-30 21:52 ` Robin H. Johnson
2006-09-30 22:37 ` Ryan Hill
0 siblings, 1 reply; 16+ messages in thread
From: Robin H. Johnson @ 2006-09-30 21:52 UTC (permalink / raw
To: gentoo-dev
[-- Attachment #1: Type: text/plain, Size: 958 bytes --]
On Sat, Sep 30, 2006 at 03:48:53PM -0600, Ryan Hill wrote:
> Lionel Bouton wrote:
> > There are already good resources (http://gentoo-wiki.com/CFLAGS_matrix
> > was mentioned to me by robbat2) but they may not be advertised enough.
> Most of the info on that page is wrong.
The items on there that note breakages are reasonably correct.
-fvisibility=hidden and -ffast-math DO cause breakages.
-ftree-loop-linear likewise is broken on GCC4.1 last I checked.
> > I'd like to propose a paragraph to the GWN editor which presents some
> > gotchas and good references on the subject.
> Honestly, the only good reference is the Safe CFLAGS page.
The objective here was mainly to point out some things that users are
doing that are causing breakages, leading to bugs that are ultimately
marked INVALID after much tracing.
--
Robin Hugh Johnson
E-Mail : robbat2@gentoo.org
GnuPG FP : 11AC BA4F 4778 E3F6 E4ED F38E B27B 944E 3488 4E85
[-- Attachment #2: Type: application/pgp-signature, Size: 232 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* [gentoo-dev] Re: [RFC] CFLAGS paragraph for the GWN
2006-09-30 21:52 ` Robin H. Johnson
@ 2006-09-30 22:37 ` Ryan Hill
2006-10-01 0:38 ` Robin H. Johnson
2006-10-01 11:23 ` Duncan
0 siblings, 2 replies; 16+ messages in thread
From: Ryan Hill @ 2006-09-30 22:37 UTC (permalink / raw
To: gentoo-dev
[-- Attachment #1: Type: text/plain, Size: 1305 bytes --]
Robin H. Johnson wrote:
> On Sat, Sep 30, 2006 at 03:48:53PM -0600, Ryan Hill wrote:
>> Lionel Bouton wrote:
>>> There are already good resources (http://gentoo-wiki.com/CFLAGS_matrix
>>> was mentioned to me by robbat2) but they may not be advertised enough.
>> Most of the info on that page is wrong.
> The items on there that note breakages are reasonably correct.
> -fvisibility=hidden and -ffast-math DO cause breakages.
>
> -ftree-loop-linear likewise is broken on GCC4.1 last I checked.
I thought he wanted flags that broke upgrading between GCC 3.4 and 4.1.
tree-loop-linear wasn't in 3.4. If you want flags that just break
stuff with 4.1 you can include -ftree-vectorize.
>>> I'd like to propose a paragraph to the GWN editor which presents some
>>> gotchas and good references on the subject.
>> Honestly, the only good reference is the Safe CFLAGS page.
> The objective here was mainly to point out some things that users are
> doing that are causing breakages, leading to bugs that are ultimately
> marked INVALID after much tracing.
Like using CFLAGS not on the Safe CFLAGS page? ;)
Monsieur Spanky wrote:
> no way will our documentation link to gentoo-wiki.com
It's not documentation, it's the GWN, which has linked to gentoo-wiki
before.
--de.
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [gentoo-dev] [RFC] CFLAGS paragraph for the GWN
2006-09-30 21:48 ` Mike Frysinger
@ 2006-09-30 22:42 ` Lionel Bouton
2006-09-30 23:27 ` [gentoo-dev] " Ryan Hill
0 siblings, 1 reply; 16+ messages in thread
From: Lionel Bouton @ 2006-09-30 22:42 UTC (permalink / raw
To: gentoo-dev
Mike Frysinger wrote the following on 30.09.2006 23:48 :
> [...]
> `man gcc` always seemed fine to me
>
> in fact, lets read the -ffast-math section:
> -ffast-math
> This option should never be turned on by any -O option since it can
> result in incorrect output for programs which depend on an exact
> implementation of IEEE or ISO rules/specifications for math func-
> tions.
>
> this flag is never safe to use in CFLAGS
>
>
Indeed, I'll add a reminder to adventurous users to check `man gcc` (I
believe I added fast-math following an example somewhere on the web
instead of checking the man page).
>> link='http://gentoo-wiki.com/CFLAGS_matrix'
>>
>
> no way will our documentation link to gentoo-wiki.com
>
>
The GWN paragraph is mainly a 'heads-up' kind of thing, no more. Don't
confuse the GuideXML extract with an official documentation extract, GWN
uses GuideXML too :-)
>> If possible, I'd like to expand the list of 3.4.6 -> 4.1.1 upgrade
>> problems which are linked to experimental CFLAGS
>>
>
> i find maintaining a list of "safe" CFLAGS on a per-gcc basis to be a waste of
> time ... but that's just me
>
That's not the idea. The main idea is to remind people that playing with
CFLAGS is allowed, as long as you remember to revert to safe CFLAGS
before reporting bugs.
As I wasted one dev time by forgetting to check my CFLAGS, I merely
thought that maybe this wasn't a common reflex for other users too
(fast-math was the only unsafe flag I used, I'm pretty conservative and
simply was mistaken because roughly 2 years ago I didn't check the
proper source of information: the man page). Maybe very few bug reports
are caused by inadequate CFLAGS. If my problem is an uncommon exception
I won't press the matter further, there would be no point to do so.
I'll wait and see if other devs are aware of common CFLAGS gotchas
plaguing bugzilla.
Lionel.
--
gentoo-dev@gentoo.org mailing list
^ permalink raw reply [flat|nested] 16+ messages in thread
* [gentoo-dev] Re: [RFC] CFLAGS paragraph for the GWN
2006-09-30 22:42 ` Lionel Bouton
@ 2006-09-30 23:27 ` Ryan Hill
0 siblings, 0 replies; 16+ messages in thread
From: Ryan Hill @ 2006-09-30 23:27 UTC (permalink / raw
To: gentoo-dev
[-- Attachment #1: Type: text/plain, Size: 441 bytes --]
Lionel Bouton wrote:
> I'll wait and see if other devs are aware of common CFLAGS gotchas
> plaguing bugzilla.
Flags such as -fforce-addr and -fweb that change the way registers are
handled can often cause errors when compiling hand-optimised ASM on
architectures with a very limited number of registers (ie. x86). This
turns up a lot in video libraries or graphic processing apps like
ffmpeg, xine-lib, or avidemux.
--de.
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [gentoo-dev] [RFC] CFLAGS paragraph for the GWN
2006-09-30 20:35 [gentoo-dev] [RFC] CFLAGS paragraph for the GWN Lionel Bouton
` (2 preceding siblings ...)
2006-09-30 21:48 ` Ryan Hill
@ 2006-10-01 0:37 ` George Prowse
3 siblings, 0 replies; 16+ messages in thread
From: George Prowse @ 2006-10-01 0:37 UTC (permalink / raw
To: gentoo-dev
Lionel Bouton wrote:
> Hi, I just had an unpleasant experience with -ffast-math and GCC 4.1.1
> (it borked my LDAP authentication on several systems which worked with
> the same CFLAGS as long as GCC 3.4.6 was used).
>
> There is a lot of material out there about CFLAGS and Gentoo (google
> returns 387000 pages) but what's working for someone might not for
> another. There are flags that work for a GCC version and most ebuilds
> and don't work with another GCC version (my unfortunate experience) or
> some ebuilds. Flag combination/architecture/LDFLAGS might be an issue too.
>
> There are already good resources (http://gentoo-wiki.com/CFLAGS_matrix
> was mentioned to me by robbat2) but they may not be advertised enough.
> I'd like to propose a paragraph to the GWN editor which presents some
> gotchas and good references on the subject.
>
> Here's a draft for review. You're welcomed to expand on the subject.
>
> --- Draft BEGIN ---
> <section>
> <title>CFLAGS</title>
> <body>
>
> <p>
> Being able to tune the CFLAGS is part of one of the core principles of
> Gentoo: let the user be in control. Being in control brings both
> benefits and problems and CFLAGS tuning is not an exception.
> </p>
> <p>
> The recent upgrade to gcc-4.1.1 for x86 and amd64 users changed the
> landscape. Users that spent some time tuning their CFLAGS with gcc-3.4.6
> might find out that an upgrade to gcc-4.1.1 leaves them with an unstable
> system. Example of this are :
> <ul>
> <li>nss_ldap stopped working with -ffast-math</li>
> <li>...</li>
> </ul>
> </p>
> <p>
> Users with unsupported CFLAGS (see the <uri
> link='http://gentoo-wiki.com/CFLAGS_matrix'>CFLAGS matrix</uri> for
> example) might want to return to safe CFLAGS (see <uri
> link='http://gentoo-wiki.com/Safe_Cflags'>Safe CFLAGS</uri>) if recent
> updates caused them stability problems. On the other hand, more
> adventurous users might want to experiment with CFLAGS that didn't work
> properly with gcc-3.4.6... As always, the user is in control.
> </p>
> </body>
> </section>
> --- Draft END ---
>
> If possible, I'd like to expand the list of 3.4.6 -> 4.1.1 upgrade
> problems which are linked to experimental CFLAGS. If you want to expand
> the subject to cover other tuning/stability gotchas that recent updates
> might have brought into the light, please feel free to do so. As English
> is not my native tongue, feel free to spell check too.
>
> Cheers,
>
> Lionel.
>
I agree in principle because it would stop people using stupid CFLAGS.
It should have an information section and a "use this CFLAG and dont ask
us for help" section:
<p>
Good Compiler Flag
</p>
<p>
-floop-optimize
Enables safe loop optimisation and is enabled in most -O$
</p>
<p>
Bad Compiler flag
</p>
<p>
Sets |-fno-math-errno|, |-funsafe-math-optimizations|,
|-fno-trapping-math|, |-ffinite-math-only|, |-fno-rounding-math| and
|-fno-signaling-nans|
Used to speed up math functions but causes major b0rkage because it can
result in incorrect output for programs which depend on an exact
implementation of IEEE or ISO rules/specifications for math functions.
Use this and dont bother asking for help.
</p>
--
gentoo-dev@gentoo.org mailing list
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [gentoo-dev] Re: [RFC] CFLAGS paragraph for the GWN
2006-09-30 22:37 ` Ryan Hill
@ 2006-10-01 0:38 ` Robin H. Johnson
2006-10-01 11:23 ` Duncan
1 sibling, 0 replies; 16+ messages in thread
From: Robin H. Johnson @ 2006-10-01 0:38 UTC (permalink / raw
To: gentoo-dev
[-- Attachment #1: Type: text/plain, Size: 1186 bytes --]
On Sat, Sep 30, 2006 at 04:37:05PM -0600, Ryan Hill wrote:
> I thought he wanted flags that broke upgrading between GCC 3.4 and 4.1.
> tree-loop-linear wasn't in 3.4. If you want flags that just break
> stuff with 4.1 you can include -ftree-vectorize.
Thanks.
> > The objective here was mainly to point out some things that users are
> > doing that are causing breakages, leading to bugs that are ultimately
> > marked INVALID after much tracing.
> Like using CFLAGS not on the Safe CFLAGS page? ;)
Not really.
One needs to use some common sense as a developer in evaluating user
CFLAGS - because there are plenty of flags that are safe, but aren't
listed on that page.
Several years ago, I wrote a package that was the forerunner of the
'Safe CFLAGS' page - genflags. It was close to unmaintable at the time
however, so it's suffered a lot of bit-rot. With the advent of
libcpuinfo, and x86info being written, it stands a much better chance of
giving useful output, but that still does not supersede the common sense
statement above.
--
Robin Hugh Johnson
E-Mail : robbat2@gentoo.org
GnuPG FP : 11AC BA4F 4778 E3F6 E4ED F38E B27B 944E 3488 4E85
[-- Attachment #2: Type: application/pgp-signature, Size: 232 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* [gentoo-dev] Re: [RFC] CFLAGS paragraph for the GWN
2006-09-30 22:37 ` Ryan Hill
2006-10-01 0:38 ` Robin H. Johnson
@ 2006-10-01 11:23 ` Duncan
2006-10-01 16:49 ` Donnie Berkholz
` (2 more replies)
1 sibling, 3 replies; 16+ messages in thread
From: Duncan @ 2006-10-01 11:23 UTC (permalink / raw
To: gentoo-dev
Ryan Hill <dirtyepic.sk@gmail.com> posted efmrae$jff$1@sea.gmane.org,
excerpted below, on Sat, 30 Sep 2006 16:37:05 -0600:
> If you want flags that just break
> stuff with 4.1 you can include -ftree-vectorize.
Could you point me at some info on this one (-ftree-vectorize)? It came
up on the amd64 list a week or so ago, when someone asked what I thought
of it and why I didn't have it in my cflags (which I had just explained).
I said I didn't know enough about it to make a case either way, and as
such, didn't choose to use it. However, after a bit of discussion, I
decided to add it to my cflags on a very experimental basis. I haven't
experienced any issues with it, but then I haven't done any major
compiling since then either, only the routine updates.
If I had rather more info on it, therefore, particularly on why it might
break stuff, I'd be able to pass it on, telling the list and in particular
the guy that asked, why it's NOT a good thing to use. Thus, point me at
it, if you got it. Even something as simple as a list of bugs traced to
it would be useful as something I could point at, if that's what you are
basing your remark on.
Or does the problem not necessarily apply to amd64? Even knowing that
would be useful. I simply don't know anything much at all about it, beyond
a generally vague idea that it means using mmx/sse/whatever vector
instructions to parallelize loops.
TIA.
--
Duncan - List replies preferred. No HTML msgs.
"Every nonfree program has a lord, a master --
and if you use the program, he is your master." Richard Stallman
--
gentoo-dev@gentoo.org mailing list
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [gentoo-dev] Re: [RFC] CFLAGS paragraph for the GWN
2006-10-01 11:23 ` Duncan
@ 2006-10-01 16:49 ` Donnie Berkholz
2006-10-01 17:02 ` Diego 'Flameeyes' Pettenò
2006-10-01 18:00 ` Ryan Hill
2006-10-01 21:01 ` Jeroen Roovers
2 siblings, 1 reply; 16+ messages in thread
From: Donnie Berkholz @ 2006-10-01 16:49 UTC (permalink / raw
To: gentoo-dev
Duncan wrote:
> Could you point me at some info on this one (-ftree-vectorize)? It came
> up on the amd64 list a week or so ago, when someone asked what I thought
> of it and why I didn't have it in my cflags (which I had just explained).
> I said I didn't know enough about it to make a case either way, and as
> such, didn't choose to use it. However, after a bit of discussion, I
> decided to add it to my cflags on a very experimental basis. I haven't
> experienced any issues with it, but then I haven't done any major
> compiling since then either, only the routine updates.
>
> If I had rather more info on it, therefore, particularly on why it might
> break stuff, I'd be able to pass it on, telling the list and in particular
> the guy that asked, why it's NOT a good thing to use. Thus, point me at
> it, if you got it. Even something as simple as a list of bugs traced to
> it would be useful as something I could point at, if that's what you are
> basing your remark on.
I can't give you reasons, but I can tell you it totally broke my x86
system a while back.
Thanks,
Donnie
--
gentoo-dev@gentoo.org mailing list
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [gentoo-dev] Re: [RFC] CFLAGS paragraph for the GWN
2006-10-01 16:49 ` Donnie Berkholz
@ 2006-10-01 17:02 ` Diego 'Flameeyes' Pettenò
0 siblings, 0 replies; 16+ messages in thread
From: Diego 'Flameeyes' Pettenò @ 2006-10-01 17:02 UTC (permalink / raw
To: gentoo-dev
[-- Attachment #1: Type: text/plain, Size: 736 bytes --]
On Sunday 01 October 2006 18:49, Donnie Berkholz wrote:
> I can't give you reasons, but I can tell you it totally broke my x86
> system a while back.
-ftree-vectorize on x86 and PowerPC is known to create broken executables
(when it comes to actually create the executable).
I'm using it on AMD64 fine since 4.0 pre-releases though (suggested for the
daredevils by Halcy0n iirc), and never had problems with it.
Most likely this is due either to the usual limitations of x86 (registers,
PIC, 387 fpmath), or to not be able to ensure the availability of extra
instructions on x86.
--
Diego "Flameeyes" Pettenò - http://farragut.flameeyes.is-a-geek.org/
Gentoo/Alt lead, Gentoo/FreeBSD, Video, AMD64, Sound, PAM, KDE
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* [gentoo-dev] Re: [RFC] CFLAGS paragraph for the GWN
2006-10-01 11:23 ` Duncan
2006-10-01 16:49 ` Donnie Berkholz
@ 2006-10-01 18:00 ` Ryan Hill
2006-10-02 10:40 ` Duncan
2006-10-01 21:01 ` Jeroen Roovers
2 siblings, 1 reply; 16+ messages in thread
From: Ryan Hill @ 2006-10-01 18:00 UTC (permalink / raw
To: gentoo-dev
[-- Attachment #1: Type: text/plain, Size: 1466 bytes --]
Duncan wrote:
> Could you point me at some info on this one (-ftree-vectorize)? It came
> up on the amd64 list a week or so ago, when someone asked what I thought
> of it and why I didn't have it in my cflags (which I had just explained).
> I said I didn't know enough about it to make a case either way, and as
> such, didn't choose to use it. However, after a bit of discussion, I
> decided to add it to my cflags on a very experimental basis. I haven't
> experienced any issues with it, but then I haven't done any major
> compiling since then either, only the routine updates.
http://tinyurl.com/l75we
They've fixed quite a few of the ICE's since last I looked, though
there's more than a couple that went in after 4.1.1. 4.2 is a little
better, but I'm having enough trouble getting it to build things
properly _without_ using any fancy flags right now. ;p
See http://tinyurl.com/rt3aa for some real-world examples.
> Or does the problem not necessarily apply to amd64? Even knowing that
> would be useful. I simply don't know anything much at all about it, beyond
> a generally vague idea that it means using mmx/sse/whatever vector
> instructions to parallelize loops.
I'd say that there's more ICE's on i686-pc-linux-gnu than
x86_64-*-linux-gnu, but there's still enough. Luckily Halcy0n was
really good for reducing testcases and pushing them upstream, so a lot
of these issues got fixed at the source.
--de.
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [gentoo-dev] Re: [RFC] CFLAGS paragraph for the GWN
2006-10-01 11:23 ` Duncan
2006-10-01 16:49 ` Donnie Berkholz
2006-10-01 18:00 ` Ryan Hill
@ 2006-10-01 21:01 ` Jeroen Roovers
2 siblings, 0 replies; 16+ messages in thread
From: Jeroen Roovers @ 2006-10-01 21:01 UTC (permalink / raw
To: gentoo-dev
On Sun, 1 Oct 2006 11:23:37 +0000 (UTC)
"Duncan" <1i5t5.duncan@cox.net> wrote:
> Ryan Hill <dirtyepic.sk@gmail.com> posted efmrae$jff$1@sea.gmane.org,
> excerpted below, on Sat, 30 Sep 2006 16:37:05 -0600:
>
> > If you want flags that just break
> > stuff with 4.1 you can include -ftree-vectorize.
>
> Could you point me at some info on this one (-ftree-vectorize)?
> SNIP!!!!1one <
-ftree-vectorize replaces the already deprecated -fentmoot, which is of course a Really Old option for GCC where all code is blown up in memory and then parsed and spit out in as many different ways as possible to ultimately come to the best most very optimised way to say the simplest things. It is wise to also use -Woverly-longwinded in this case, so all the optimisation steps are written verbosely to stderr interspersed with funny anecdotal evidence of extraneously confablucious witticisms (to stdout, naturally).[1]
Kind regards,
JeR
[1] -fentmoot got the chop from one of the Wizards of Yore who is known by many as Saruman the Black and White Water-Loving Bird, and the rest is History.
--
gentoo-dev@gentoo.org mailing list
^ permalink raw reply [flat|nested] 16+ messages in thread
* [gentoo-dev] Re: [RFC] CFLAGS paragraph for the GWN
2006-10-01 18:00 ` Ryan Hill
@ 2006-10-02 10:40 ` Duncan
0 siblings, 0 replies; 16+ messages in thread
From: Duncan @ 2006-10-02 10:40 UTC (permalink / raw
To: gentoo-dev
Ryan Hill <dirtyepic.sk@gmail.com> posted efovnn$sm8$1@sea.gmane.org,
excerpted below, on Sun, 01 Oct 2006 12:00:10 -0600:
> Duncan wrote:
>
>> Could you point me at some info on this one (-ftree-vectorize)?
>
> http://tinyurl.com/l75we
>
> They've fixed quite a few [...]
>
> See http://tinyurl.com/rt3aa for some real-world examples.
>
>> Or does the problem not necessarily apply to amd64?
>
> I'd say that there's more ICE's on i686-pc-linux-gnu than
> x86_64-*-linux-gnu, but there's still enough. Luckily Halcy0n was
> really good [...]
Thanks! Saving and forwarding the gist to the amd64 list, where I'm sure
others will find it useful as well.
--
Duncan - List replies preferred. No HTML msgs.
"Every nonfree program has a lord, a master --
and if you use the program, he is your master." Richard Stallman
--
gentoo-dev@gentoo.org mailing list
^ permalink raw reply [flat|nested] 16+ messages in thread
end of thread, other threads:[~2006-10-02 10:43 UTC | newest]
Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-09-30 20:35 [gentoo-dev] [RFC] CFLAGS paragraph for the GWN Lionel Bouton
2006-09-30 20:58 ` Dominique Michel
2006-09-30 21:48 ` Mike Frysinger
2006-09-30 22:42 ` Lionel Bouton
2006-09-30 23:27 ` [gentoo-dev] " Ryan Hill
2006-09-30 21:48 ` Ryan Hill
2006-09-30 21:52 ` Robin H. Johnson
2006-09-30 22:37 ` Ryan Hill
2006-10-01 0:38 ` Robin H. Johnson
2006-10-01 11:23 ` Duncan
2006-10-01 16:49 ` Donnie Berkholz
2006-10-01 17:02 ` Diego 'Flameeyes' Pettenò
2006-10-01 18:00 ` Ryan Hill
2006-10-02 10:40 ` Duncan
2006-10-01 21:01 ` Jeroen Roovers
2006-10-01 0:37 ` [gentoo-dev] " George Prowse
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox