tree-ssanames.c (release_dead_ssa_names): Remove invalidated cgraph edges too.
authorJan Hubicka <jh@suse.cz>
Tue, 16 Jan 2007 06:48:23 +0000 (07:48 +0100)
committerJan Hubicka <hubicka@gcc.gnu.org>
Tue, 16 Jan 2007 06:48:23 +0000 (06:48 +0000)
* tree-ssanames.c (release_dead_ssa_names): Remove invalidated
cgraph edges too.

From-SVN: r120823

gcc/ChangeLog
gcc/tree-ssanames.c

index e0fcfbf..7c3b628 100644 (file)
@@ -1,3 +1,8 @@
+2007-01-16  Jan Hubicka  <jh@suse.cz>
+
+       * tree-ssanames.c (release_dead_ssa_names): Remove invalidated
+       cgraph edges too.
+
 2007-01-15  Eric Christopher  <echristo@apple.com>
 
        * ifcvt.c: Include vec.h, vecprim.h.
index 9cbe352..d9ab940 100644 (file)
@@ -329,6 +329,11 @@ release_dead_ssa_names (void)
       n++;
     }
   FREE_SSANAMES (cfun) = NULL;
+
+  /* Cgraph edges has been invalidated and point to dead statement.  We need to
+     remove them now and will rebuild it before next IPA pass.  */
+  cgraph_node_remove_callees (cgraph_node (current_function_decl));
+
   if (dump_file)
     fprintf (dump_file, "Released %i names, %.2f%%\n", n, n * 100.0 / num_ssa_names);
   return 0;