diff options
author | tbsaunde <tbsaunde@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-06-24 13:21:35 +0000 |
---|---|---|
committer | tbsaunde <tbsaunde@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-06-24 13:21:35 +0000 |
commit | c1f445d2fbea31314327e0ce37f86184a6ae3de7 (patch) | |
tree | b8d7f5b21a14b16949ddbc5dcaeb5f2b2654d63a /gcc/store-motion.c | |
parent | d0285fb08b709575f6b35bf46efbae5e1cb3a40a (diff) | |
download | gcc-c1f445d2fbea31314327e0ce37f86184a6ae3de7.tar.gz |
Remove a layer of indirection from hash_table
gcc/
* hash-table.h: Remove a layer of indirection from hash_table so that
it contains the hash table's data instead of a pointer to the data.
* alloc-pool.c, asan.c, attribs.c, bitmap.c, cfg.c,
config/arm/arm.c, config/i386/winnt.c, config/ia64/ia64.c,
config/mips/mips.c, config/sol2.c, coverage.c, cselib.c,
data-streamer-out.c, dse.c, dwarf2cfi.c, dwarf2out.c, except.c,
fold-const.c, gcse.c, ggc-common.c,
gimple-ssa-strength-reduction.c, gimplify.c,
graphite-clast-to-gimple.c, graphite-dependences.c,
graphite-htab.h, graphite.c, haifa-sched.c, ipa-devirt.c,
ipa-profile.c, ira-color.c, ira-costs.c, loop-invariant.c,
loop-iv.c, loop-unroll.c, lto-streamer-in.c, lto-streamer-out.c,
lto-streamer.c, lto-streamer.h, passes.c, plugin.c,
postreload-gcse.c, sese.c, statistics.c, store-motion.c,
trans-mem.c, tree-browser.c, tree-cfg.c, tree-complex.c,
tree-eh.c, tree-into-ssa.c, tree-parloops.c, tree-sra.c,
tree-ssa-ccp.c, tree-ssa-coalesce.c, tree-ssa-dom.c,
tree-ssa-live.c, tree-ssa-loop-im.c,
tree-ssa-loop-ivopts.c, tree-ssa-phiopt.c, tree-ssa-pre.c,
tree-ssa-reassoc.c, tree-ssa-sccvn.c, tree-ssa-strlen.c,
tree-ssa-structalias.c, tree-ssa-tail-merge.c,
tree-ssa-threadupdate.c, tree-ssa-uncprop.c,
tree-vect-data-refs.c, tree-vect-loop.c, tree-vectorizer.c,
tree-vectorizer.h, valtrack.c, valtrack.h, var-tracking.c,
vtable-verify.c, vtable-verify.h: Adjust.
gcc/c/
* c-decl.c: Adjust.
gcc/cp/
* class.c, semantics.c, tree.c, vtable-class-hierarchy.c:
Adjust.
gcc/java/
* jcf-io.c: Adjust.
gcc/lto/
* lto.c: Adjust.
gcc/objc/
* objc-act.c: Adjust.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@211936 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/store-motion.c')
-rw-r--r-- | gcc/store-motion.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/gcc/store-motion.c b/gcc/store-motion.c index 18ba518eb9a..3023c0c44bb 100644 --- a/gcc/store-motion.c +++ b/gcc/store-motion.c @@ -129,7 +129,7 @@ st_expr_hasher::equal (const value_type *ptr1, const compare_type *ptr2) } /* Hashtable for the load/store memory refs. */ -static hash_table <st_expr_hasher> store_motion_mems_table; +static hash_table<st_expr_hasher> *store_motion_mems_table; /* This will search the st_expr list for a matching expression. If it doesn't find one, we create one and initialize it. */ @@ -147,7 +147,7 @@ st_expr_entry (rtx x) NULL, /*have_reg_qty=*/false); e.pattern = x; - slot = store_motion_mems_table.find_slot_with_hash (&e, hash, INSERT); + slot = store_motion_mems_table->find_slot_with_hash (&e, hash, INSERT); if (*slot) return *slot; @@ -183,8 +183,8 @@ free_st_expr_entry (struct st_expr * ptr) static void free_store_motion_mems (void) { - if (store_motion_mems_table.is_created ()) - store_motion_mems_table.dispose (); + delete store_motion_mems_table; + store_motion_mems_table = NULL; while (store_motion_mems) { @@ -651,7 +651,7 @@ compute_store_table (void) unsigned int max_gcse_regno = max_reg_num (); store_motion_mems = NULL; - store_motion_mems_table.create (13); + store_motion_mems_table = new hash_table<st_expr_hasher> (13); last_set_in = XCNEWVEC (int, max_gcse_regno); already_set = XNEWVEC (int, max_gcse_regno); @@ -713,7 +713,7 @@ compute_store_table (void) if (! ptr->avail_stores) { *prev_next_ptr_ptr = ptr->next; - store_motion_mems_table.remove_elt_with_hash (ptr, ptr->hash_index); + store_motion_mems_table->remove_elt_with_hash (ptr, ptr->hash_index); free_st_expr_entry (ptr); } else @@ -1152,7 +1152,8 @@ one_store_motion_pass (void) num_stores = compute_store_table (); if (num_stores == 0) { - store_motion_mems_table.dispose (); + delete store_motion_mems_table; + store_motion_mems_table = NULL; end_alias_analysis (); return 0; } |