From 07687835bea637072221fdcbeb11cf14c43986f7 Mon Sep 17 00:00:00 2001 From: Trevor Saunders Date: Fri, 1 Nov 2013 20:31:32 +0000 Subject: Replace some heap vectors with stack vectors. From http://gcc.gnu.org/ml/gcc-patches/2013-10/msg02735.html This patch is pretty dull, it just replaces a bunch of things of the form vec x; x.create (N); // N is a constant blah blah x.release (); by stack_vec x; blah blah 2013-11-01 Trevor Saunders gcc/ * function.c (reorder_blocks): Convert block_stack to a stack_vec. * gimplify.c (gimplify_compound_lval): Likewise. * graphite-clast-to-gimple.c (gloog): Likewise. * graphite-dependences.c (loop_is_parallel_p): Likewise. * graphite-scop-detection.c (scopdet_basic_block_info): Likewise. (limit_scop); Likewise. (build_scops): Likewise. (dot_scop): Likewise. * graphite-sese-to-poly.c (sese_dom_walker): Likewise. (build_scop_drs): Likewise. (insert_stmts): Likewise. (insert_out_of_ssa_copy): Likewise. (remove_phi): Likewise. (rewrite_commutative_reductions_out_of_ssa_close_phi): Likewise. * hw-doloop.c (discover_loop): Likewise. * tree-call-cdce.c (shrink_wrap_one_built_in_call): Likewise. * tree-dfa.c (dump_enumerated_decls): Likewise. * tree-if-conv.c (if_convertable_loop_p): Likewise. * tree-inline.c (tree_function_versioning): Likewise. * tree-loop-distribution.c (build_rdg): Likewise. (rdg_flag_vertex_and_dependent): Likewise. (distribute_loop): Likewise. * tree-parloops.c (loop_parallel_p): Likewise. (eliminate_local_variables): Likewise. (separate_decls_in_region): Likewise. * tree-predcom.c (tree_predictive_commoning_loop): Likewise. * tree-ssa-phiopt.c (cond_if_else_store_replacement): Likewise. * tree-ssa-uncprop.c (uncprop_dom_walker): Likewise. * tree-vect-loop.c (vect_analyze_scaler_cycles_1): Likewise. * tree-vect-patterns.c (vect_pattern_recog): Likewise. * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Likewise. (vectorizable_condition): Likewise. gcc/cp/ * semantics.c (build_anon_member_initialization): Convert fields to be a stack_vec. From-SVN: r204301 --- gcc/tree-ssa-uncprop.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'gcc/tree-ssa-uncprop.c') diff --git a/gcc/tree-ssa-uncprop.c b/gcc/tree-ssa-uncprop.c index 71c1f5d..5255d7fb 100644 --- a/gcc/tree-ssa-uncprop.c +++ b/gcc/tree-ssa-uncprop.c @@ -361,15 +361,7 @@ record_equiv (tree value, tree equivalence) class uncprop_dom_walker : public dom_walker { public: - uncprop_dom_walker (cdi_direction direction) - : dom_walker (direction) - { - m_equiv_stack.create (2); - } - ~uncprop_dom_walker () - { - m_equiv_stack.release (); - } + uncprop_dom_walker (cdi_direction direction) : dom_walker (direction) {} virtual void before_dom_children (basic_block); virtual void after_dom_children (basic_block); @@ -380,7 +372,7 @@ private: leading to this block. If no such edge equivalency exists, then we record NULL. These equivalences are live until we leave the dominator subtree rooted at the block where we record the equivalency. */ - vec m_equiv_stack; + stack_vec m_equiv_stack; }; /* Main driver for un-cprop. */ -- cgit v1.1