This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: -funsafe-loop-optimizations


On Sun, 02 Jan 2005 11:35:15 -0500, Robert Dewar <dewar@adacore.com> wrote:
> Richard Guenther wrote:
> 
> > Well, this is just the builtin_true() that will transform
> >
> >   if (!builtin_true(n == MAX_UNSIGNED))
> >      abort();
> >
> > to nothing in case 3, and of course VRP and other optimizations
> > take advantage about the fact.
> 
> Not really, since this does not establish an invariant for n (at least
> if I understand it), instead it is essentially an assertion at a
> particular point in time, so presumably you have to pepper the
> code with this construct at various points, even for a single
> variable ???

If you change it, yes.  So you cannot say simply n will not become
MAX_UNSIGNED anytime.  But for particular testcases you probably
will be able to construct something that will help.

Richard.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]