bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: changing "configure" to default to "gcc -g -O2 -fwrapv ..."


From: Andrew Pinski
Subject: Re: changing "configure" to default to "gcc -g -O2 -fwrapv ..."
Date: Sat, 30 Dec 2006 19:42:05 -0500 (EST)

> 
> Andrew Pinski wrote:
> 
> >> -fwrapv-in-all-cases-except-loop-bounds
> > 
> > 
> > Again, please don't this the default for Fortran as integer
> > overflow has been undefined since at least 1977 so I don't think
> > it is a good idea for GCC in general anyways as evidence of Fortran.
> > 
> > -- Pinski
> 
> Well the question is whether the optimization buys anything
> in practice for other than the loop bound case, I am guessing
> it does not, and if that is the case there is an argument
> for uniformity.

It does buy you something for code like:

if (a - 10 < 20)

that might show up in a hot loop.  So we are able to remove one extra 
instruction.

In fact I think this code does show up in GCC and most likely other places.

Oh and it is a very simple optimization that I added and I don't want it 
removed for C
or Fortran or C++ for that matter.


Thanks,
Andrew Pinski





reply via email to

[Prev in Thread] Current Thread [Next in Thread]