Summary: | [4.5 Regression] ice in fold_comparison, at fold-const.c:9579 | ||
---|---|---|---|
Product: | gcc | Reporter: | John Regehr <regehr> |
Component: | c | Assignee: | Richard Biener <rguenth> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | chenyang, gcc-bugs |
Priority: | P3 | ||
Version: | unknown | ||
Target Milestone: | 4.5.0 | ||
Host: | i686-pc-linux-gnu | Target: | i686-pc-linux-gnu |
Build: | i686-pc-linux-gnu | Known to work: | |
Known to fail: | Last reconfirmed: | 2010-04-06 09:10:53 |
Description
John Regehr
2010-04-06 03:21:08 UTC
Caused by r145254. Shorter testcase: int func (int x) { return 0 ? (unsigned short) (0 ? : 1 * (signed char) (x ^ x) >= 0) : 1; } These kind of asserts are really bogus ... Well. We have an unfolded tree. I have a fix for the ICE. Subject: Bug 43661 Author: rguenth Date: Tue Apr 6 10:36:57 2010 New Revision: 157984 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=157984 Log: 2010-04-06 Richard Guenther <rguenther@suse.de> PR middle-end/43661 * fold-const.c (fold_comparison): Handle X * 0 CMP 0. * gcc.c-torture/compile/pr43661.c: New testcase. Added: trunk/gcc/testsuite/gcc.c-torture/compile/pr43661.c Modified: trunk/gcc/ChangeLog trunk/gcc/fold-const.c trunk/gcc/testsuite/ChangeLog Fixed. |