diff options
author | rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-09-10 10:26:08 +0000 |
---|---|---|
committer | rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-09-10 10:26:08 +0000 |
commit | 869a4fb543e45452540b96d17c63909ec2050a69 (patch) | |
tree | 6d55c244219bf63844eb287b02c00ab6e3a421ed /gcc/tree-loop-distribution.c | |
parent | 01fb57c979b3246e641033efd790676d8bd17785 (diff) | |
download | gcc-869a4fb543e45452540b96d17c63909ec2050a69.tar.gz |
2013-09-10 Richard Biener <rguenther@suse.de>
* tree-data-ref.h (build_rdg): Drop all parameters but loop.
* tree-data-ref.c (create_rdg_vertices): Collect all data
references, signal failure to the caller, use data-ref API.
(build_rdg): Compute data references only once. Maintain
lifetime of data references and data dependences from within
RDG.
(free_rdg): Free dependence relations.
* tree-loop-distribution.c (rdg_flag_uses): Drop weird code
inventing extra dependences.
(distribute_loop): Update for RDG API changes.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@202431 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-loop-distribution.c')
-rw-r--r-- | gcc/tree-loop-distribution.c | 36 |
1 files changed, 1 insertions, 35 deletions
diff --git a/gcc/tree-loop-distribution.c b/gcc/tree-loop-distribution.c index 95c4d5f753a..707a4b28127 100644 --- a/gcc/tree-loop-distribution.c +++ b/gcc/tree-loop-distribution.c @@ -635,7 +635,6 @@ static void rdg_flag_uses (struct graph *rdg, int u, partition_t partition, bitmap loops, bitmap processed) { - use_operand_p use_p; struct vertex *x = &(rdg->vertices[u]); gimple stmt = RDGV_STMT (x); struct graph_edge *anti_dep = has_anti_or_output_dependence (x); @@ -652,26 +651,6 @@ rdg_flag_uses (struct graph *rdg, int u, partition_t partition, bitmap loops, processed); } - if (gimple_code (stmt) != GIMPLE_PHI) - { - if ((use_p = gimple_vuse_op (stmt)) != NULL_USE_OPERAND_P) - { - tree use = USE_FROM_PTR (use_p); - - if (TREE_CODE (use) == SSA_NAME - && !SSA_NAME_IS_DEFAULT_DEF (use)) - { - gimple def_stmt = SSA_NAME_DEF_STMT (use); - int v = rdg_vertex_for_stmt (rdg, def_stmt); - - if (v >= 0 - && !already_processed_vertex_p (processed, v)) - rdg_flag_vertex_and_dependent (rdg, v, partition, loops, - processed); - } - } - } - if (is_gimple_assign (stmt) && has_upstream_mem_writes (u)) { tree op0 = gimple_assign_lhs (stmt); @@ -1438,15 +1417,8 @@ distribute_loop (struct loop *loop, vec<gimple> stmts) gimple s; unsigned i; vec<int> vertices; - vec<ddr_p> dependence_relations; - vec<data_reference_p> datarefs; - vec<loop_p> loop_nest; - - datarefs.create (10); - dependence_relations.create (100); - loop_nest.create (3); - rdg = build_rdg (loop, &loop_nest, &dependence_relations, &datarefs); + rdg = build_rdg (loop); if (!rdg) { if (dump_file && (dump_flags & TDF_DETAILS)) @@ -1454,9 +1426,6 @@ distribute_loop (struct loop *loop, vec<gimple> stmts) "FIXME: Loop %d not distributed: failed to build the RDG.\n", loop->num); - free_dependence_relations (dependence_relations); - free_data_refs (datarefs); - loop_nest.release (); return res; } @@ -1482,9 +1451,6 @@ distribute_loop (struct loop *loop, vec<gimple> stmts) res = ldist_gen (loop, rdg, vertices); vertices.release (); free_rdg (rdg); - free_dependence_relations (dependence_relations); - free_data_refs (datarefs); - loop_nest.release (); return res; } |