From: hubicka Date: Tue, 11 May 2010 16:27:31 +0000 (+0000) Subject: * lto.c (lto_fixup_decls): Remove global var decls freeing here. X-Git-Url: http://git.sourceforge.jp/view?p=pf3gnuchains%2Fgcc-fork.git;a=commitdiff_plain;h=5b7cd9a5b3895e38d03c8fe09dcb371be4e4a1f3 * lto.c (lto_fixup_decls): Remove global var decls freeing here. (materialize_cgraph): Add it here. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@159281 138bc75d-0d04-0410-961f-82ee72b054a4 --- diff --git a/gcc/lto/ChangeLog b/gcc/lto/ChangeLog index 6166a810083..c8d8f006a18 100644 --- a/gcc/lto/ChangeLog +++ b/gcc/lto/ChangeLog @@ -1,5 +1,10 @@ 2010-05-11 Jan Hubicka + * lto.c (lto_fixup_decls): Remove global var decls freeing here. + (materialize_cgraph): Add it here. + +2010-05-11 Jan Hubicka + * lto.c (lto_fixup_decls): Free no longer needed lto_global_var_decls vector. diff --git a/gcc/lto/lto.c b/gcc/lto/lto.c index 9f6ad400cd7..a2a2b68c9da 100644 --- a/gcc/lto/lto.c +++ b/gcc/lto/lto.c @@ -1454,8 +1454,6 @@ lto_fixup_decls (struct lto_file_decl_data **files) VEC_replace (tree, lto_global_var_decls, i, decl); } - VEC_free (tree, gc, lto_global_var_decls); - lto_global_var_decls = NULL; pointer_set_destroy (seen); } @@ -1710,6 +1708,9 @@ materialize_cgraph (void) for (i = 0; VEC_iterate (tree, lto_global_var_decls, i, decl); i++) rest_of_decl_compilation (decl, 1, 0); + VEC_free (tree, gc, lto_global_var_decls); + lto_global_var_decls = NULL; + if (!quiet_flag) fprintf (stderr, "\n");