This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/33779] [4.3 Regression] folds unsigned multiplication == 0 to true
- From: "rguenth at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 15 Oct 2007 13:31:46 -0000
- Subject: [Bug middle-end/33779] [4.3 Regression] folds unsigned multiplication == 0 to true
- References: <bug-33779-10053@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from rguenth at gcc dot gnu dot org 2007-10-15 13:31 -------
whoops, make the testcase in comment #1
int foo(int i)
{
return ((int)((unsigned)(i + 1) * 4)) / 4;
}
extern void abort(void);
int main()
{
if (foo(0x3fffffff) != 0)
abort ();
return 0;
}
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33779