summaryrefslogtreecommitdiff
path: root/gcc/ggc-page.c
diff options
context:
space:
mode:
authorsteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>2003-12-01 22:59:30 +0000
committersteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>2003-12-01 22:59:30 +0000
commit867d54fa17b07a131758adc8b0ce1e81d263fe86 (patch)
tree828e8c449db658913176f3c52668d0d0325b655d /gcc/ggc-page.c
parent72983aaaa3107d9c4d65eb1e00da7021ecc0a8c2 (diff)
downloadgcc-867d54fa17b07a131758adc8b0ce1e81d263fe86.tar.gz
* ggc.h (struct alloc_zone): Move forward declaration up.
(new_ggc_zone): New function prototype. (destroy_ggc_zone): Ditto. * ggc-simple.c (new_ggc_zone): New function, does nothing. (destroy_ggc_zone): Ditto. * ggc-page.c (new_ggc_zone): New function, does nothing. (destroy_ggc_zone): Ditto. * ggc-zone.c (struct page_entry): Fix comment. (ggc_alloc_typed): Use a switch statement instead of ifs. (new_ggc_zone): New function to set up a new GC zone. (destroy_ggc_zone): New function to remove a GC zone. init_ggc): Use new_ggc_zone to set up the default zones. (ggc_collect): Walk a list of zones, instead of just the default zones. Report statistics using the zone name. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@74132 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ggc-page.c')
-rw-r--r--gcc/ggc-page.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/gcc/ggc-page.c b/gcc/ggc-page.c
index 12b1f17b265..7e40d044535 100644
--- a/gcc/ggc-page.c
+++ b/gcc/ggc-page.c
@@ -1401,6 +1401,20 @@ init_ggc (void)
G.save_in_use = xmalloc (G.by_depth_max * sizeof (unsigned long *));
}
+/* Start a new GGC zone. */
+
+struct alloc_zone *
+new_ggc_zone (const char *name ATTRIBUTE_UNUSED)
+{
+ return NULL;
+}
+
+/* Destroy a GGC zone. */
+void
+destroy_ggc_zone (struct alloc_zone *zone ATTRIBUTE_UNUSED)
+{
+}
+
/* Increment the `GC context'. Objects allocated in an outer context
are never freed, eliminating the need to register their roots. */