This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH 23/65] Remove copy_renames.
- From: Sebastian Pop <sebpop at gmail dot com>
- To: gcc-patches at gcc dot gnu dot org
- Cc: Tobias Grosser <grosser at fim dot uni-passau dot de>, gcc-graphite <gcc-graphite at googlegroups dot com>
- Date: Mon, 2 Aug 2010 15:19:56 -0500
- Subject: [PATCH 23/65] Remove copy_renames.
- References: <1280780438-17543-1-git-send-email-sebpop@gmail.com>
From: spop <spop@138bc75d-0d04-0410-961f-82ee72b054a4>
2010-06-24 Sebastian Pop <sebastian.pop@amd.com>
* graphite-clast-to-gimple.c (copy_renames): Removed.
(translate_clast_for): Do not call copy_renames.
(translate_clast_guard): Same.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/graphite@161356 138bc75d-0d04-0410-961f-82ee72b054a4
---
gcc/ChangeLog | 6 ++++
gcc/ChangeLog.graphite | 6 ++++
gcc/graphite-clast-to-gimple.c | 63 ++++-----------------------------------
3 files changed, 19 insertions(+), 56 deletions(-)
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index f12de88..82b49e4 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,11 @@
2010-08-02 Sebastian Pop <sebastian.pop@amd.com>
+ * graphite-clast-to-gimple.c (copy_renames): Removed.
+ (translate_clast_for): Do not call copy_renames.
+ (translate_clast_guard): Same.
+
+2010-08-02 Sebastian Pop <sebastian.pop@amd.com>
+
* graphite-sese-to-poly.c (rewrite_reductions_out_of_ssa): Moved up.
(rewrite_cross_bb_phi_deps): Split out of rewrite_cross_bb_scalar_deps.
(rewrite_cross_bb_scalar_deps_out_of_ssa): Run rewrite_cross_bb_phi_deps
diff --git a/gcc/ChangeLog.graphite b/gcc/ChangeLog.graphite
index d736895..40777c0 100644
--- a/gcc/ChangeLog.graphite
+++ b/gcc/ChangeLog.graphite
@@ -1,3 +1,9 @@
+2010-06-24 Sebastian Pop <sebastian.pop@amd.com>
+
+ * graphite-clast-to-gimple.c (copy_renames): Removed.
+ (translate_clast_for): Do not call copy_renames.
+ (translate_clast_guard): Same.
+
2010-06-23 Sebastian Pop <sebastian.pop@amd.com>
* graphite-sese-to-poly.c (rewrite_reductions_out_of_ssa): Moved up.
diff --git a/gcc/graphite-clast-to-gimple.c b/gcc/graphite-clast-to-gimple.c
index 8b972b8..a610bc5 100644
--- a/gcc/graphite-clast-to-gimple.c
+++ b/gcc/graphite-clast-to-gimple.c
@@ -846,27 +846,6 @@ build_iv_mapping (htab_t map, sese region,
}
}
-/* Helper function for htab_traverse. */
-
-static int
-copy_renames (void **slot, void *s)
-{
- struct rename_map_elt_s *entry = (struct rename_map_elt_s *) *slot;
- htab_t res = (htab_t) s;
- tree old_name = entry->old_name;
- tree expr = entry->expr;
- struct rename_map_elt_s tmp;
- PTR *x;
-
- tmp.old_name = old_name;
- x = htab_find_slot (res, &tmp, INSERT);
-
- if (x && !*x)
- *x = new_rename_map_elt (old_name, expr);
-
- return 1;
-}
-
/* Construct bb_pbb_def with BB and PBB. */
static bb_pbb_def *
@@ -1095,26 +1074,12 @@ translate_clast_for (sese region, loop_p context_loop, struct clast_for *stmt,
{
edge last_e = graphite_create_new_loop_guard (region, next_e, stmt, *newivs,
newivs_index, params_index);
-
edge true_e = get_true_edge_from_guard_bb (next_e->dest);
- edge false_e = get_false_edge_from_guard_bb (next_e->dest);
- edge exit_true_e = single_succ_edge (true_e->dest);
- edge exit_false_e = single_succ_edge (false_e->dest);
-
- htab_t before_guard = htab_create (10, rename_map_elt_info,
- eq_rename_map_elts, free);
- htab_traverse (rename_map, copy_renames, before_guard);
-
- next_e = translate_clast_for_loop (region, context_loop, stmt, true_e,
- rename_map, newivs,
- newivs_index, bb_pbb_mapping, level,
- params_index);
-
- insert_guard_phis (last_e->src, exit_true_e, exit_false_e,
- before_guard, rename_map);
-
- htab_delete (before_guard);
+ translate_clast_for_loop (region, context_loop, stmt, true_e,
+ rename_map, newivs,
+ newivs_index, bb_pbb_mapping, level,
+ params_index);
return last_e;
}
@@ -1137,25 +1102,11 @@ translate_clast_guard (sese region, loop_p context_loop,
{
edge last_e = graphite_create_new_guard (region, next_e, stmt, *newivs,
newivs_index, params_index);
-
edge true_e = get_true_edge_from_guard_bb (next_e->dest);
- edge false_e = get_false_edge_from_guard_bb (next_e->dest);
- edge exit_true_e = single_succ_edge (true_e->dest);
- edge exit_false_e = single_succ_edge (false_e->dest);
-
- htab_t before_guard = htab_create (10, rename_map_elt_info,
- eq_rename_map_elts, free);
- htab_traverse (rename_map, copy_renames, before_guard);
-
- next_e = translate_clast (region, context_loop, stmt->then, true_e,
- rename_map, newivs, newivs_index, bb_pbb_mapping,
- level, params_index);
-
- insert_guard_phis (last_e->src, exit_true_e, exit_false_e,
- before_guard, rename_map);
-
- htab_delete (before_guard);
+ translate_clast (region, context_loop, stmt->then, true_e,
+ rename_map, newivs, newivs_index, bb_pbb_mapping,
+ level, params_index);
return last_e;
}
--
1.7.0.4