diff options
author | Mikhail Maltsev <maltsevm@gmail.com> | 2015-09-16 00:56:54 +0000 |
---|---|---|
committer | Mikhail Maltsev <miyuki@gcc.gnu.org> | 2015-09-16 00:56:54 +0000 |
commit | fcb87c50b00e203aa3ef586915edd305429d3868 (patch) | |
tree | e915c259d85e8eae9618ae3fa48e6250374ddb3e /gcc/var-tracking.c | |
parent | 5e4e62af0c226f3ec57bd8cc71b64bd5af4e37aa (diff) | |
download | gcc-fcb87c50b00e203aa3ef586915edd305429d3868.zip gcc-fcb87c50b00e203aa3ef586915edd305429d3868.tar.gz gcc-fcb87c50b00e203aa3ef586915edd305429d3868.tar.bz2 |
Share memory blocks between pool allocators
gcc/
* Makefile.in: Add memory-block.cc
(pool_allocator::initialize): Use fixed block size.
(pool_allocator::release): Use memory_block_pool.
(pool_allocator::allocate): Likewise.
* asan.c (asan_mem_ref_pool): Adjust to use common block size in all
object pools.
* cfg.c (initialize_original_copy_tables): Likewise.
* cselib.c (elt_list_pool, elt_loc_list_pool,
cselib_val_pool): Likewise.
* df-problems.c (df_chain_alloc): Likewise.
* df-scan.c (df_scan_alloc): Likewise.
* dse.c (cse_store_info_pool, rtx_store_info_pool,
read_info_type_pool, insn_info_type_pool, bb_info_pool,
group_info_pool, deferred_change_pool): Likewise.
* et-forest.c (et_nodes, et_occurrences): Likewise.
* ipa-cp.c (ipcp_cst_values_pool, ipcp_sources_pool,
ipcp_agg_lattice_pool): Likewise.
* ipa-inline-analysis.c (edge_predicate_pool): Likewise.
* ipa-profile.c (histogram_pool): Likewise.
* ipa-prop.c (ipa_refdesc_pool): Likewise.
* ira-build.c (live_range_pool, allocno_pool, object_pool,
initiate_cost_vectors, pref_pool, copy_pool): Likewise.
* ira-color.c (update_cost_record_pool): Likewise.
* lra-lives.c (lra_live_range_pool): Likewise.
* lra.c (lra_insn_reg_pool, lra_copy_pool): Likewise.
* memory-block.cc: New file.
* memory-block.h: New file.
* regcprop.c (queued_debug_insn_change_pool): Use common block size.
* sched-deps.c (sched_deps_init): Likewise.
* sel-sched-ir.c (sched_lists_pool): Likewise.
* stmt.c (expand_case, expand_sjlj_dispatch_table): Likewise.
* tree-sra.c (access_pool): Likewise.
* tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
* tree-ssa-pre.c (pre_expr_pool, bitmap_set_pool): Likewise.
* tree-ssa-reassoc.c (operand_entry_pool): Likewise.
* tree-ssa-sccvn.c (allocate_vn_table): Likewise.
* tree-ssa-strlen.c (strinfo_pool): Likewise.
* tree-ssa-structalias.c (variable_info_pool): Likewise.
* var-tracking.c (attrs_def_pool, var_pool, valvar_pool,
location_chain_pool, shared_hash_pool, loc_exp_dep_pool): Likewise.
gcc/c-family/
* c-format.c (check_format_arg): Adjust to use common block size in all
object pools.
From-SVN: r227817
Diffstat (limited to 'gcc/var-tracking.c')
-rw-r--r-- | gcc/var-tracking.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/gcc/var-tracking.c b/gcc/var-tracking.c index 126feee..e3542d3 100644 --- a/gcc/var-tracking.c +++ b/gcc/var-tracking.c @@ -576,28 +576,27 @@ typedef struct variable_tracking_info_def } *variable_tracking_info; /* Alloc pool for struct attrs_def. */ -object_allocator<attrs_def> attrs_def_pool ("attrs_def pool", 1024); +object_allocator<attrs_def> attrs_def_pool ("attrs_def pool"); /* Alloc pool for struct variable_def with MAX_VAR_PARTS entries. */ static pool_allocator var_pool - ("variable_def pool", 64, sizeof (variable_def) + + ("variable_def pool", sizeof (variable_def) + (MAX_VAR_PARTS - 1) * sizeof (((variable)NULL)->var_part[0])); /* Alloc pool for struct variable_def with a single var_part entry. */ static pool_allocator valvar_pool - ("small variable_def pool", 256, sizeof (variable_def)); + ("small variable_def pool", sizeof (variable_def)); -/* Alloc pool for struct location_chain_def. */ +/* Alloc pool for struct location_chain. */ static object_allocator<location_chain> location_chain_pool - ("location_chain pool", 1024); + ("location_chain pool"); -/* Alloc pool for struct shared_hash_def. */ -static object_allocator<shared_hash> shared_hash_pool - ("shared_hash pool", 256); +/* Alloc pool for struct shared_hash. */ +static object_allocator<shared_hash> shared_hash_pool ("shared_hash pool"); /* Alloc pool for struct loc_exp_dep_s for NOT_ONEPART variables. */ -object_allocator<loc_exp_dep> loc_exp_dep_pool ("loc_exp_dep pool", 64); +object_allocator<loc_exp_dep> loc_exp_dep_pool ("loc_exp_dep pool"); /* Changed variables, notes will be emitted for them. */ static variable_table_type *changed_variables; |