]> gcc.gnu.org Git - gcc.git/commitdiff
parser.c (synthesize_implicit_template_parm): Use grow_tree_vec.
authorJan Hubicka <hubicka@ucw.cz>
Fri, 7 Feb 2014 02:14:58 +0000 (03:14 +0100)
committerJan Hubicka <hubicka@gcc.gnu.org>
Fri, 7 Feb 2014 02:14:58 +0000 (02:14 +0000)
* parser.c (synthesize_implicit_template_parm): Use grow_tree_vec.
* ggc.h (ggc_internal_cleared_alloc): New macro.
* vec.h (vec_safe_copy): Handle memory stats.
* omp-low.c (simd_clone_struct_alloc): Use ggc_internal_cleared_alloc.
* target-globals.c (save_target_globals): Likewise.

From-SVN: r207588

gcc/ChangeLog
gcc/cp/ChangeLog
gcc/cp/parser.c
gcc/ggc.h
gcc/omp-low.c
gcc/target-globals.c
gcc/vec.h

index 3a389639d05fd829849bfc4543a35966991c586c..73a9bd7df50f4dc69a5338b40631d5ede0a8d438 100644 (file)
@@ -1,4 +1,11 @@
-2014-02-06  Jakub Jelinek  <jakub@redhat.com>
+2014-02-06  Jan Hubicka  <hubicka@ucw.cz>
+
+       * ggc.h (ggc_internal_cleared_alloc): New macro.
+       * vec.h (vec_safe_copy): Handle memory stats.
+       * omp-low.c (simd_clone_struct_alloc): Use ggc_internal_cleared_alloc.
+       * target-globals.c (save_target_globals): Likewise.
+
+2014-02-06  Jan Hubicka  <hubicka@ucw.cz>
 
        PR target/60077
        * expr.c (emit_move_resolve_push): Export; be bit more selective
index 60651c59f64615cde5e297757f39693ff6175929..6bb1115fad604fde4ce5f13d0cb00ec7f9cef64b 100644 (file)
@@ -1,3 +1,7 @@
+2014-02-05  Jan Hubicka  <hubicka@ucw.cz
+
+       * parser.c (synthesize_implicit_template_parm): Use grow_tree_vec.
+
 2014-02-05  Jakub Jelinek  <jakub@redhat.com>
 
        PR c++/58703
index 392acf277c56b5870f2fdb7e99a5275e35e96c72..f0722d6bf7bc031433b137d2943f7a45ca935053 100644 (file)
@@ -31957,7 +31957,7 @@ synthesize_implicit_template_parm  (cp_parser *parser)
     {
       tree& new_parms = INNERMOST_TEMPLATE_PARMS (current_template_parms);
       int new_parm_idx = TREE_VEC_LENGTH (new_parms);
-      new_parms = grow_tree_vec_stat (new_parms, new_parm_idx + 1);
+      new_parms = grow_tree_vec (new_parms, new_parm_idx + 1);
       TREE_VEC_ELT (new_parms, new_parm_idx) = parser->implicit_template_parms;
     }
 
index 49f0c37950d13237b074392875dc1272a4e61d13..55f3fe9b0bc5dd85c08fdf2290cbf121ac910335 100644 (file)
--- a/gcc/ggc.h
+++ b/gcc/ggc.h
@@ -146,6 +146,7 @@ extern size_t ggc_round_alloc_size (size_t requested_size);
 /* Allocates cleared memory.  */
 extern void *ggc_internal_cleared_alloc_stat (size_t MEM_STAT_DECL)
   ATTRIBUTE_MALLOC;
+#define ggc_internal_cleared_alloc(s) ggc_internal_cleared_alloc_stat (s MEM_STAT_INFO)
 
 /* Resize a block.  */
 extern void *ggc_realloc_stat (void *, size_t MEM_STAT_DECL);
index 3750ceb5e8d85323c2838ccc29cef780d53996a7..2c35751a957aded84c7e0ee597728e5f5335feec 100644 (file)
@@ -10649,7 +10649,7 @@ simd_clone_struct_alloc (int nargs)
   size_t len = (sizeof (struct cgraph_simd_clone)
                + nargs * sizeof (struct cgraph_simd_clone_arg));
   clone_info = (struct cgraph_simd_clone *)
-              ggc_internal_cleared_alloc_stat (len PASS_MEM_STAT);
+              ggc_internal_cleared_alloc (len);
   return clone_info;
 }
 
index 8d3eaa89041e5479c020c0e18cb2eedb36069110..7cf95aeeddfe98037ba8631e2d0b3142980b7755 100644 (file)
@@ -79,29 +79,21 @@ save_target_globals (void)
     struct target_lower_subreg lower_subreg;
   } *p;
   p = (struct target_globals_extra *)
-      ggc_internal_cleared_alloc_stat (sizeof (struct target_globals_extra)
-                                      PASS_MEM_STAT);
+      ggc_internal_cleared_alloc (sizeof (struct target_globals_extra));
   g = (struct target_globals *) p;
   g->flag_state = &p->flag_state;
-  g->regs = ggc_internal_cleared_alloc_stat (sizeof (struct target_regs)
-                                            PASS_MEM_STAT);
+  g->regs = ggc_internal_cleared_alloc (sizeof (struct target_regs));
   g->rtl = ggc_alloc_cleared_target_rtl ();
   g->hard_regs
-    = ggc_internal_cleared_alloc_stat (sizeof (struct target_hard_regs)
-                                      PASS_MEM_STAT);
-  g->reload = ggc_internal_cleared_alloc_stat (sizeof (struct target_reload)
-                                              PASS_MEM_STAT);
-  g->expmed =  ggc_internal_cleared_alloc_stat (sizeof (struct target_expmed)
-                                               PASS_MEM_STAT);
+    = ggc_internal_cleared_alloc (sizeof (struct target_hard_regs));
+  g->reload = ggc_internal_cleared_alloc (sizeof (struct target_reload));
+  g->expmed =  ggc_internal_cleared_alloc (sizeof (struct target_expmed));
   g->optabs = &p->optabs;
   g->libfuncs = ggc_alloc_cleared_target_libfuncs ();
   g->cfgloop = &p->cfgloop;
-  g->ira = ggc_internal_cleared_alloc_stat (sizeof (struct target_ira)
-                                           PASS_MEM_STAT);
-  g->ira_int = ggc_internal_cleared_alloc_stat (sizeof (struct target_ira_int)
-                                               PASS_MEM_STAT);
-  g->lra_int = ggc_internal_cleared_alloc_stat (sizeof (struct target_lra_int)
-                                               PASS_MEM_STAT);
+  g->ira = ggc_internal_cleared_alloc (sizeof (struct target_ira));
+  g->ira_int = ggc_internal_cleared_alloc (sizeof (struct target_ira_int));
+  g->lra_int = ggc_internal_cleared_alloc (sizeof (struct target_lra_int));
   g->builtins = &p->builtins;
   g->gcse = &p->gcse;
   g->bb_reorder = &p->bb_reorder;
index 4e8e3b877d47e7884fe1789abd12b719466f9ab2..cb4ba632869c3f4b4c6569209afbcd36be6eac01 100644 (file)
--- a/gcc/vec.h
+++ b/gcc/vec.h
@@ -679,9 +679,9 @@ vec_safe_truncate (vec<T, A, vl_embed> *v, unsigned size)
 /* If SRC is not NULL, return a pointer to a copy of it.  */
 template<typename T, typename A>
 inline vec<T, A, vl_embed> *
-vec_safe_copy (vec<T, A, vl_embed> *src)
+vec_safe_copy (vec<T, A, vl_embed> *src CXX_MEM_STAT_INFO)
 {
-  return src ? src->copy () : NULL;
+  return src ? src->copy (ALONE_PASS_MEM_STAT) : NULL;
 }
 
 /* Copy the elements from SRC to the end of DST as if by memcpy.
This page took 0.109965 seconds and 5 git commands to generate.