Summary: | [4.4 Regression] ice in simplify_subreg, at simplify-rtx.c:4957 | ||
---|---|---|---|
Product: | gcc | Reporter: | John Regehr <regehr> |
Component: | tree-optimization | Assignee: | Richard Biener <rguenth> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | gcc-bugs, pinskia |
Priority: | P1 | Keywords: | ice-on-valid-code |
Version: | 4.4.0 | ||
Target Milestone: | 4.4.0 | ||
Host: | i686-pc-linux-gnu | Target: | i686-pc-linux-gnu |
Build: | i686-pc-linux-gnu | Known to work: | |
Known to fail: | Last reconfirmed: | 2008-08-27 19:35:16 |
Description
John Regehr
2008-08-27 17:35:35 UTC
Confirmed. #1 0x0845d476 in simplify_subreg (outermode=SImode, op=0xb7d50d2c, innermode=DImode, byte=0) at /home/richard/src/trunk/gcc/simplify-rtx.c:4956 4956 gcc_assert (GET_MODE (op) == innermode #3 0x081feadf in operand_subword (op=0xb7d50d2c, offset=0, validate_address=1, mode=DImode) at /home/richard/src/trunk/gcc/emit-rtl.c:1399 1399 return simplify_gen_subreg (word_mode, op, mode, (offset * UNITS_PER_WORD)); (gdb) call debug_rtx (op) (subreg:SI (reg/v:DI 58 [ p_79.30 ]) 0) (gdb) print word_mode $2 = SImode (gdb) print mode $3 = DImode from expanding (int) p_79.30 & 1 with a wrong type on the BIT_AND_EXPR (long long, DImode). Sounds familiar somehow ... Generated by PRE D.2018_117 = (int) p_79_115; pretmp.18_43 = D.2018_117 & 1; pretmp.18_43 is long long, D.2018_117 is int. Probably a wrong typed constant in # p_79_115 = PHI <1(3), 0(9)> I will have a closer look. The problem is that int64_t p1; int p; p1 = PHI <1, 0> p = PHI <1, 0> are value-numbered the same. I have a patch. Subject: Bug 37258 Author: rguenth Date: Thu Sep 18 15:27:21 2008 New Revision: 140460 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140460 Log: 2008-09-18 Richard Guenther <rguenther@suse.de> PR tree-optimization/37258 * tree-ssa-sccvn.c (vn_phi_compute_hash): Include the precision and signedness for integral types. (vn_phi_eq): Require compatible types. * gcc.c-torture/compile/pr37258.c: New testcase. Added: trunk/gcc/testsuite/gcc.c-torture/compile/pr37258.c Modified: trunk/gcc/ChangeLog trunk/gcc/testsuite/ChangeLog trunk/gcc/tree-ssa-sccvn.c Fixed. |