[Bug tree-optimization/27039] Unable to determine # of iterations for a simple loop
rguenth at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Wed Apr 5 09:57:00 GMT 2006
------- Comment #1 from rguenth at gcc dot gnu dot org 2006-04-05 09:57 -------
Confirmed. That gives us a testcase at least.
Now, back to the folding problem of
PTR +- CST CMP PTR +- CST
where all of PTR / CST are of pointer type naturally and unsigned usually.
The problem was that the frontends/middle-end introduce pointer overflow via
presenting us with PTR + (unsigned)-CST. Now, we may argue that if (signed)CST
is positive, that this didn't happen, and we can do the comparison in either
signed or unsigned mode. Of course this won't help for p - 4 < p + 4, because
this is exactly where the above condition would trigger.
Does this sound reasonable? Can anyone punch a hole in this argument?
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2006-04-05 09:57:15
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27039
More information about the Gcc-bugs
mailing list