This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: -funsafe-loop-optimizations
- From: David Edelsohn <dje at watson dot ibm dot com>
- To: Richard Henderson <rth at redhat dot com>, Daniel Berlin <dberlin at dberlin dot org>, Zdenek Dvorak <rakdver at atrey dot karlin dot mff dot cuni dot cz>, gcc at gcc dot gnu dot org
- Date: Sat, 01 Jan 2005 00:43:03 -0500
- Subject: Re: -funsafe-loop-optimizations
- References: <20041231211409.GA22814@atrey.karlin.mff.cuni.cz> <Pine.LNX.4.60.0412311649170.6844@dberlin.org> <20041231232501.GA16663@redhat.com>
>>>>> Richard Henderson writes:
Richard> On Fri, Dec 31, 2004 at 04:50:12PM -0500, Daniel Berlin wrote:
>> Almost all compilers i know of turn this on by default at -O2 or higher.
>> So if we do tihs, i believe we should do that same.
Richard> Um, no.
This is a change in behavior from GCC 3.4. GCC was ignoring the
language semantics. Of course we can make GCC more compliant with the
language standards, but this was not "fixed" because of any bug reports
from users.
While we discuss whether this should be the default or enabled at
any optimization level, can we agree that users should be able to assert
with a commandline option that they want less strict induction variable
semantics? I hope that we can move forward with an option to address
these performance regressions and allow users to request this optimzation
when they *do* want it, along the lines of the draft patch.
Happy New Year,
David