diff options
author | tbsaunde <tbsaunde@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-05-17 23:06:33 +0000 |
---|---|---|
committer | tbsaunde <tbsaunde@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-05-17 23:06:33 +0000 |
commit | 881f903ec5acda5da00fc504d859b72fa8005768 (patch) | |
tree | 8d1527effaee14026c419a32b174fb4c0a8ad57b /gcc/ggc-common.c | |
parent | 0345f05c314708ce008d73014e3415c2d5811a3a (diff) | |
download | gcc-881f903ec5acda5da00fc504d859b72fa8005768.tar.gz |
rm a bunch of _stat allocation functions
Now that we can use c++ default arguments there's no reason to use
functions and wrapper macros.
gcc/ChangeLog:
* dwarf2out.c (tree_add_const_value_attribute): Call
ggc_internal_cleared_alloc instead of ggc_alloc_cleared_atomic.
* gengtype.c (write_typed_alloc_def): Call ggc_internal_<x>alloc
instead of ggc_internal_<x>alloc_stat.
* ggc-common.c (ggc_internal_cleared_alloc): Drop _stat suffix.
(ggc_realloc): Likewise.
* ggc-none.c (ggc_internal_alloc): Likewise.
(ggc_internal_cleared_alloc): Likewise.
* ggc-page.c: Likewise.
* ggc.h (ggc_internal_alloc_stat): Likewise.
(ggc_internal_alloc): Remove macro.
(ggc_internal_cleared_alloc_stat): Drop _stat suffix.
(ggc_internal_cleared_alloc): Remove macro.
(GGC_RESIZEVEC): Adjust.
(ggc_resizevar): Remove macro.
(ggc_internal_vec_alloc_stat): Drop _stat suffix.
(ggc_internal_cleared_vec_alloc_stat): Likewise.
(ggc_internal_vec_cleared_alloc): Remove macro.
(ggc_alloc_atomic_stat): Drop _stat suffix.
(ggc_alloc_atomic): Remove macro.
(ggc_alloc_cleared_atomic): Remove macro.
(ggc_alloc_string_stat): Drop _stat suffix.
(ggc_alloc_string): Remove macro.
(ggc_alloc_rtx_def_stat): Adjust.
(ggc_alloc_tree_node_stat): Likewise.
(ggc_alloc_cleared_tree_node_stat): Likewise.
(ggc_alloc_cleared_gimple_statement_stat): Likewise.
(ggc_alloc_cleared_simd_clone_stat): Likewise.
* gimple.c (gimple_build_omp_for): Likewise.
(gimple_copy): Likewise.
* stringpool.c (ggc_alloc_string_stat): Drop _stat suffix.
* toplev.c (realloc_for_line_map): Adjust.
* tree-data-ref.h (lambda_vector_new): Likewise.
* tree-phinodes.c (allocate_phi_node): Likewise.
* tree.c (grow_tree_vec_stat): Likewise.
* vec.h (va_gc::reserve): Adjust.
gcc/java/ChangeLog:
* constants.c (set_constant_entry): Adjust.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@210565 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ggc-common.c')
-rw-r--r-- | gcc/ggc-common.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/gcc/ggc-common.c b/gcc/ggc-common.c index 97c9b87fc16..e1cc48e6e67 100644 --- a/gcc/ggc-common.c +++ b/gcc/ggc-common.c @@ -174,22 +174,22 @@ ggc_mark_roots (void) /* Allocate a block of memory, then clear it. */ void * -ggc_internal_cleared_alloc_stat (size_t size MEM_STAT_DECL) +ggc_internal_cleared_alloc (size_t size MEM_STAT_DECL) { - void *buf = ggc_internal_alloc_stat (size PASS_MEM_STAT); + void *buf = ggc_internal_alloc (size PASS_MEM_STAT); memset (buf, 0, size); return buf; } /* Resize a block of memory, possibly re-allocating it. */ void * -ggc_realloc_stat (void *x, size_t size MEM_STAT_DECL) +ggc_realloc (void *x, size_t size MEM_STAT_DECL) { void *r; size_t old_size; if (x == NULL) - return ggc_internal_alloc_stat (size PASS_MEM_STAT); + return ggc_internal_alloc (size PASS_MEM_STAT); old_size = ggc_get_size (x); @@ -211,7 +211,7 @@ ggc_realloc_stat (void *x, size_t size MEM_STAT_DECL) return x; } - r = ggc_internal_alloc_stat (size PASS_MEM_STAT); + r = ggc_internal_alloc (size PASS_MEM_STAT); /* Since ggc_get_size returns the size of the pool, not the size of the individually allocated object, we'd access parts of the old object |