* [Bug c/53153] ice in tree_low_cst, at tree.c:6569
2012-04-28 8:14 [Bug c/53153] New: ice in tree_low_cst, at tree.c:6569 dcb314 at hotmail dot com
@ 2012-04-28 9:12 ` marc.glisse at normalesup dot org
2012-04-28 15:14 ` [Bug c/53153] [4.8 Regression] " hjl.tools at gmail dot com
` (5 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: marc.glisse at normalesup dot org @ 2012-04-28 9:12 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53153
Marc Glisse <marc.glisse at normalesup dot org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |marc.glisse at normalesup
| |dot org
--- Comment #1 from Marc Glisse <marc.glisse at normalesup dot org> 2012-04-28 09:11:45 UTC ---
Reduced:
void f (char *BufPtr) {
int Char = *BufPtr;
switch (Char) {
case 'a':
case 181:
case ~(0xff & (~180)):
PrintError();
}
}
$ gcc a.c -c -O2
a.c: In function 'f':
a.c:3:3: internal compiler error: in tree_low_cst, at tree.c:6569
switch (Char) {
^
The regression is recent.
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c/53153] [4.8 Regression] ice in tree_low_cst, at tree.c:6569
2012-04-28 8:14 [Bug c/53153] New: ice in tree_low_cst, at tree.c:6569 dcb314 at hotmail dot com
2012-04-28 9:12 ` [Bug c/53153] " marc.glisse at normalesup dot org
@ 2012-04-28 15:14 ` hjl.tools at gmail dot com
2012-04-30 9:59 ` steven at gcc dot gnu.org
` (4 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: hjl.tools at gmail dot com @ 2012-04-28 15:14 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53153
H.J. Lu <hjl.tools at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2012-04-28
Target Milestone|--- |4.8.0
Summary|ice in tree_low_cst, at |[4.8 Regression] ice in
|tree.c:6569 |tree_low_cst, at
| |tree.c:6569
Ever Confirmed|0 |1
Alias| |steven
--- Comment #2 from H.J. Lu <hjl.tools at gmail dot com> 2012-04-28 15:13:23 UTC ---
It is caused by revision 186579:
http://gcc.gnu.org/ml/gcc-cvs/2012-04/msg00530.html
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c/53153] [4.8 Regression] ice in tree_low_cst, at tree.c:6569
2012-04-28 8:14 [Bug c/53153] New: ice in tree_low_cst, at tree.c:6569 dcb314 at hotmail dot com
2012-04-28 9:12 ` [Bug c/53153] " marc.glisse at normalesup dot org
2012-04-28 15:14 ` [Bug c/53153] [4.8 Regression] " hjl.tools at gmail dot com
@ 2012-04-30 9:59 ` steven at gcc dot gnu.org
2012-04-30 17:11 ` steven at gcc dot gnu.org
` (3 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: steven at gcc dot gnu.org @ 2012-04-30 9:59 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53153
Steven Bosscher <steven at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
CC|steven at gcc dot gnu.org |
AssignedTo|unassigned at gcc dot |steven at gcc dot gnu.org
|gnu.org |
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c/53153] [4.8 Regression] ice in tree_low_cst, at tree.c:6569
2012-04-28 8:14 [Bug c/53153] New: ice in tree_low_cst, at tree.c:6569 dcb314 at hotmail dot com
` (2 preceding siblings ...)
2012-04-30 9:59 ` steven at gcc dot gnu.org
@ 2012-04-30 17:11 ` steven at gcc dot gnu.org
2012-04-30 21:43 ` steven at gcc dot gnu.org
` (2 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: steven at gcc dot gnu.org @ 2012-04-30 17:11 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53153
--- Comment #3 from Steven Bosscher <steven at gcc dot gnu.org> 2012-04-30 17:11:15 UTC ---
This is the early forwprop eliminating the promotion cast from char to int. I
don't think this is a valid transformation.
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c/53153] [4.8 Regression] ice in tree_low_cst, at tree.c:6569
2012-04-28 8:14 [Bug c/53153] New: ice in tree_low_cst, at tree.c:6569 dcb314 at hotmail dot com
` (3 preceding siblings ...)
2012-04-30 17:11 ` steven at gcc dot gnu.org
@ 2012-04-30 21:43 ` steven at gcc dot gnu.org
2012-05-02 12:58 ` [Bug middle-end/53153] " steven at gcc dot gnu.org
2012-05-02 13:00 ` steven at gcc dot gnu.org
6 siblings, 0 replies; 8+ messages in thread
From: steven at gcc dot gnu.org @ 2012-04-30 21:43 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53153
--- Comment #4 from Steven Bosscher <steven at gcc dot gnu.org> 2012-04-30 21:43:33 UTC ---
Created attachment 27272
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=27272
Eliminate unreachable case labels
This is basically what the code in stmt.c used to do, and the new code in
gimplify.c also does: GIMPLE passes that change the type of the index
expression must also update the case label vector.
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug middle-end/53153] [4.8 Regression] ice in tree_low_cst, at tree.c:6569
2012-04-28 8:14 [Bug c/53153] New: ice in tree_low_cst, at tree.c:6569 dcb314 at hotmail dot com
` (4 preceding siblings ...)
2012-04-30 21:43 ` steven at gcc dot gnu.org
@ 2012-05-02 12:58 ` steven at gcc dot gnu.org
2012-05-02 13:00 ` steven at gcc dot gnu.org
6 siblings, 0 replies; 8+ messages in thread
From: steven at gcc dot gnu.org @ 2012-05-02 12:58 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53153
--- Comment #5 from Steven Bosscher <steven at gcc dot gnu.org> 2012-05-02 12:57:17 UTC ---
Author: steven
Date: Wed May 2 12:57:10 2012
New Revision: 187048
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=187048
Log:
gcc/
PR middle-end/53153
* gimplify.c (preprocess_case_label_vec_for_gimple): New function,
split out from ...
(gimplify_switch_expr): ... here.
* gimple.h (preprocess_case_label_vec_for_gimple): Add prototype.
* tree-ssa-forwprop.c (simplify_gimple_switch_label_vec): New function
to clean up case labels with values outside the index type range.
(simplify_gimple_switch): Call it if something changed.
Remove strange and unnecessary assert.
testsuite/
PR middle-end/53153
* gcc.dg/pr53153.c: New test.
Added:
trunk/gcc/testsuite/gcc.dg/pr53153.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/gimple.h
trunk/gcc/gimplify.c
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-ssa-forwprop.c
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug middle-end/53153] [4.8 Regression] ice in tree_low_cst, at tree.c:6569
2012-04-28 8:14 [Bug c/53153] New: ice in tree_low_cst, at tree.c:6569 dcb314 at hotmail dot com
` (5 preceding siblings ...)
2012-05-02 12:58 ` [Bug middle-end/53153] " steven at gcc dot gnu.org
@ 2012-05-02 13:00 ` steven at gcc dot gnu.org
6 siblings, 0 replies; 8+ messages in thread
From: steven at gcc dot gnu.org @ 2012-05-02 13:00 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53153
Steven Bosscher <steven at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
--- Comment #6 from Steven Bosscher <steven at gcc dot gnu.org> 2012-05-02 12:59:18 UTC ---
.
^ permalink raw reply [flat|nested] 8+ messages in thread