This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: -funsafe-loop-optimizations
- From: Florian Weimer <fw at deneb dot enyo dot de>
- To: Zdenek Dvorak <rakdver at atrey dot karlin dot mff dot cuni dot cz>
- Cc: gcc at gcc dot gnu dot org, dje at gcc dot gnu dot org
- Date: Sat, 01 Jan 2005 01:02:44 +0100
- Subject: Re: -funsafe-loop-optimizations
- References: <20041231211409.GA22814@atrey.karlin.mff.cuni.cz>
* Zdenek Dvorak:
> several times some people sounded opinion that in addition to improving
> analyses in loop optimizer, we might also add a flag that would enable
> the compiler to assume that the compiled code does not contain loops
> behaving in "weird" way (loops whose control induction variables
> overflows, infinite loops with nontrivial exit conditions).
Are these optimizations permitted by the C standard, the Ada standard
etc.?
If not, the documentation should mention this fact, and it should
provide proper documentation. With the current documentation, I have
no idea whether it's safe to use this option for my code or not. (The
situation is a bit different from the floating point case, IMHO.)