This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
So you end up with SSA_NAMEs which have been eliminated from the IL via optimization, and which this code for the non-optimized path assumes can never happen? I didn't write the non-optimized hunk, but it appears to make the assumption that all SSA_NAMEs are still in the IL. partition_to_var[] should be non-null for any SSA_NAME which is still in the IL, even at -O0. So unless honza has something else to add...This patch fixes an LTO ICE that occurs where pickled IL generated with -O1 is processed later on by lto1 without optimization (-O0).
The patch works by skipping SSA names for debugging if they do not map to a partition. This is the same check as made elsewhere in this module.
Index: gcc/tree-ssa-coalesce.c
===================================================================
--- gcc/tree-ssa-coalesce.c (revision 143457)
+++ gcc/tree-ssa-coalesce.c (working copy)
@@ -1355,7 +1355,8 @@ coalesce_ssa_name (void)
{
tree a = ssa_name (i);
- if (a && SSA_NAME_VAR (a) && !DECL_ARTIFICIAL (SSA_NAME_VAR (a)))
+ if (a && SSA_NAME_VAR (a) && !DECL_ARTIFICIAL (SSA_NAME_VAR (a))
+ && map->partition_to_var[i] != NULL)
{
tree *slot = (tree *) htab_find_slot (ssa_name_hash, a, INSERT);
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |