This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/29788] [4.1/4.2/4.3 Regression] ICE in var_ann, at tree-flow-inline.h:130
- 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: 10 Nov 2006 10:40:04 -0000
- Subject: [Bug tree-optimization/29788] [4.1/4.2/4.3 Regression] ICE in var_ann, at tree-flow-inline.h:130
- References: <bug-29788-6318@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #7 from rguenth at gcc dot gnu dot org 2006-11-10 10:40 -------
4.0.3 works.
VN in set_value_handle sets a TREE_ANN_COMMON on the CONST_DECL of C.1346.
With
-fno-tree-pre -fno-tree-fre we get a different ICE:
Program received signal SIGSEGV, Segmentation fault.
0x0000000000ad5313 in var_to_partition (map=0x1050580, var=0x2b4416691d20)
at /space/rguenther/src/svn/trunk/gcc/tree-ssa-live.h:150
150 if (ann->out_of_ssa_tag)
because now we don't have an annotation for the CONST_DECL at all.
Somehow seeing CONST_DECLs seriously confuses us. The following patch fixes
it for me:
Index: tree-ssa-live.c
===================================================================
*** tree-ssa-live.c (revision 118621)
--- tree-ssa-live.c (working copy)
*************** build_tree_conflict_graph (tree_live_inf
*** 1455,1461 ****
else
p1 = NO_PARTITION;
! if (DECL_P (rhs) || TREE_CODE (rhs) == SSA_NAME)
p2 = var_to_partition (map, rhs);
else
p2 = NO_PARTITION;
--- 1455,1462 ----
else
p1 = NO_PARTITION;
! if ((DECL_P (rhs) || TREE_CODE (rhs) == SSA_NAME)
! && TREE_CODE (rhs) != CONST_DECL)
p2 = var_to_partition (map, rhs);
else
p2 = NO_PARTITION;
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |rguenth at gcc dot gnu dot
| |org, amacleod at redhat dot
| |com
Known to work| |4.0.3
Summary|[Optimization] ICE in |[4.1/4.2/4.3 Regression] ICE
|var_ann, at tree-flow- |in var_ann, at tree-flow-
|inline.h:130 |inline.h:130
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29788