This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/31602] Overflow warning causes GDB -Werror build failure
- From: "ian at airs dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 18 Apr 2007 14:14:27 -0000
- Subject: [Bug tree-optimization/31602] Overflow warning causes GDB -Werror build failure
- References: <bug-31602-3264@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from ian at airs dot com 2007-04-18 15:14 -------
Yes, the warning is happening because gcc relies on undefined signed overflow
when assuming that it will execute the loop at least once. Of course when
using -fwrapv the loop should not be executed at all when num > INT_MAX - 10.
I'll try to figure out what to do about this.
--
ian at airs dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
CC|ian at gcc dot gnu dot org |ian at airs dot com
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2007-04-18 15:14:27
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31602