diff options
author | tbsaunde <tbsaunde@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-11-22 05:45:37 +0000 |
---|---|---|
committer | tbsaunde <tbsaunde@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-11-22 05:45:37 +0000 |
commit | c2078b806e007cf378451fcecda0d9f9a366fcc0 (patch) | |
tree | 15430a70b98350e546a27451e278ea2bc1aec992 /gcc/tree-predcom.c | |
parent | a7920b67d3445222ee084dc2f0552e385027833a (diff) | |
download | gcc-c2078b806e007cf378451fcecda0d9f9a366fcc0.tar.gz |
add auto_vec
2013-11-22 Trevor Saunders <tsaunders@mozilla.com>
gcc/
* vec.h (auto_vec): New class.
* cfganal.c, cfgloop.c, cgraphunit.c, config/i386/i386.c, dwarf2out.c,
function.c, genautomata.c, gimple.c, haifa-sched.c, ipa-inline.c,
ira-build.c, loop-unroll.c, omp-low.c, ree.c, trans-mem.c,
tree-call-cdce.c, tree-eh.c, tree-if-conv.c, tree-into-ssa.c,
tree-loop-distribution.c, tree-predcom.c, tree-sra.c,
tree-sssa-forwprop.c, tree-ssa-loop-manip.c, tree-ssa-pre.c,
tree-ssa-reassoc.c, tree-ssa-sccvn.c, tree-ssa-structalias.c,
tree-vect-loop.c, tree-vect-stmts.c: Use auto_vec and stack_vec as
appropriate instead of vec for local variables.
cp/
* parser.c, semantics.c: Change some local variables from vec to
auto_vec or stack_vec.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@205244 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-predcom.c')
-rw-r--r-- | gcc/tree-predcom.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/gcc/tree-predcom.c b/gcc/tree-predcom.c index 6d141842f1c..0d3c66cc877 100644 --- a/gcc/tree-predcom.c +++ b/gcc/tree-predcom.c @@ -1538,7 +1538,7 @@ initialize_root_vars_lm (struct loop *loop, dref root, bool written, static void execute_load_motion (struct loop *loop, chain_p chain, bitmap tmp_vars) { - vec<tree> vars; + auto_vec<tree> vars; dref a; unsigned n_writes = 0, ridx, i; tree var; @@ -1577,8 +1577,6 @@ execute_load_motion (struct loop *loop, chain_p chain, bitmap tmp_vars) replace_ref_with (a->stmt, vars[ridx], !is_read, !is_read); } - - vars.release (); } /* Returns the single statement in that NAME is used, excepting @@ -2272,7 +2270,7 @@ try_combine_chains (vec<chain_p> *chains) { unsigned i, j; chain_p ch1, ch2, cch; - vec<chain_p> worklist = vNULL; + auto_vec<chain_p> worklist; FOR_EACH_VEC_ELT (*chains, i, ch1) if (chain_can_be_combined_p (ch1)) @@ -2298,8 +2296,6 @@ try_combine_chains (vec<chain_p> *chains) } } } - - worklist.release (); } /* Prepare initializers for CHAIN in LOOP. Returns false if this is |