* decl.c (finish_function): Clean out pointers we no longer need.
authorJan Hubicka <jh@suse.cz>
Fri, 3 Sep 2004 20:37:03 +0000 (22:37 +0200)
committerJan Hubicka <hubicka@gcc.gnu.org>
Fri, 3 Sep 2004 20:37:03 +0000 (20:37 +0000)
From-SVN: r87055

gcc/cp/ChangeLog
gcc/cp/decl.c

index 4dafed925b7f39233388725dfa025f07ff6f47b7..4e25f69c98db155167f83640c567469a481a6835 100644 (file)
@@ -1,3 +1,7 @@
+2004-09-03  Jan Hubicka  <jh@suse.cz>
+
+       * decl.c (finish_function): Clean out pointers we no longer need.
+
 2004-09-03  Jan Beulich  <jbeulich@novell.com>
 
        * g++spec.c (MATH_LIBRARY_PROFILE): Default to MATH_LIBRARY rather
index 55db551001b9f65f93ec665cdaab37e6464c9e3c..1aed934a3e5ad319bb86b273af342e0c09e7fd8f 100644 (file)
@@ -10451,11 +10451,23 @@ finish_function (int flags)
   /* Genericize before inlining.  */
   if (!processing_template_decl)
     {
+      struct language_function *f = DECL_SAVED_FUNCTION_DATA (fndecl);
       cp_genericize (fndecl);
+      /* Clear out the bits we don't need.  */
+      f->x_current_class_ptr = NULL;
+      f->x_current_class_ref = NULL;
+      f->x_eh_spec_block = NULL;
+      f->x_in_charge_parm = NULL;
+      f->x_vtt_parm = NULL;
+      f->x_return_value = NULL;
+      f->bindings = NULL;
 
       /* Handle attribute((warn_unused_result)).  Relies on gimple input.  */
       c_warn_unused_result (&DECL_SAVED_TREE (fndecl));
     }
+  /* Clear out the bits we don't need.  */
+  local_names = NULL;
+  named_label_uses = NULL;
 
   /* We're leaving the context of this function, so zap cfun.  It's still in
      DECL_STRUCT_FUNCTION, and we'll restore it in tree_rest_of_compilation.  */