aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJan Hubicka <jh@suse.cz>2008-09-11 14:48:53 +0200
committerJan Hubicka <hubicka@gcc.gnu.org>2008-09-11 12:48:53 +0000
commitcf9757477e367cf9ab4e8dae6489dcd09178033e (patch)
tree767df63c6acd529c10c6d6c64b416ac9a6eb7808 /gcc
parent936fc9bad2df490917cbb01f27c9eede43f9e153 (diff)
downloadgcc-cf9757477e367cf9ab4e8dae6489dcd09178033e.zip
gcc-cf9757477e367cf9ab4e8dae6489dcd09178033e.tar.gz
gcc-cf9757477e367cf9ab4e8dae6489dcd09178033e.tar.bz2
ggc-common.c (loc_array): Make static.
* ggc-common.c (loc_array): Make static. * dce.c (rest_of_handle_ud_dce): Free worklist. From-SVN: r140286
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/dce.c1
-rw-r--r--gcc/ggc-common.c2
3 files changed, 7 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 054cabc..67d1649 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,10 @@
2008-09-11 Jan Hubicka <jh@suse.cz>
+ * ggc-common.c (loc_array): Make static.
+ * dce.c (rest_of_handle_ud_dce): Free worklist.
+
+2008-09-11 Jan Hubicka <jh@suse.cz>
+
* cgraph.c (cgraph_release_function_body): Plug memory leak on
ipa_transforms_to_apply and CFG; ggc_free gimple df and struct function
so we are sure we do not dangle it forever.
diff --git a/gcc/dce.c b/gcc/dce.c
index 31a5f51..fc08751 100644
--- a/gcc/dce.c
+++ b/gcc/dce.c
@@ -424,6 +424,7 @@ rest_of_handle_ud_dce (void)
insn = VEC_pop (rtx, worklist);
mark_reg_dependencies (insn);
}
+ VEC_free (rtx, heap, worklist);
/* Before any insns are deleted, we must remove the chains since
they are not bidirectional. */
diff --git a/gcc/ggc-common.c b/gcc/ggc-common.c
index 8c0e459..747ec4c 100644
--- a/gcc/ggc-common.c
+++ b/gcc/ggc-common.c
@@ -947,7 +947,7 @@ cmp_statistic (const void *loc1, const void *loc2)
}
/* Collect array of the descriptors from hashtable. */
-struct loc_descriptor **loc_array;
+static struct loc_descriptor **loc_array;
static int
add_statistics (void **slot, void *b)
{