* graphite-sese-to-poly.c (insert_copyin): Use gsi_insert_seq_on_edge.
(rewrite_commutative_reductions_out_of_ssa): Call gsi_commit_edge_inserts,
and check the SSA representation.
* gfortran.dg/graphite/id-18.f90: New, reduced from PR41193.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@154590
138bc75d-0d04-0410-961f-
82ee72b054a4
2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
+ * graphite-sese-to-poly.c (insert_copyin): Use gsi_insert_seq_on_edge.
+ (rewrite_commutative_reductions_out_of_ssa): Call gsi_commit_edge_inserts,
+ and check the SSA representation.
+
+ * gfortran.dg/graphite/id-18.f90: New, reduced from PR41193.
+
+2009-10-15 Sebastian Pop <sebastian.pop@amd.com>
+
* gcc.dg/graphite/pr40157.c: Use -floop-block as reported in the PR.
2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
* gcc.dg/graphite/pr40157.c: Use -floop-block as reported in the PR.
2009-10-14 Sebastian Pop <sebastian.pop@amd.com>
{
gimple_seq stmts;
tree init = initial_value_for_loop_phi (loop_phi);
{
gimple_seq stmts;
tree init = initial_value_for_loop_phi (loop_phi);
- edge e = edge_initial_value_for_loop_phi (loop_phi);
- basic_block bb = e->src;
- gimple_stmt_iterator insert_gsi = gsi_last_bb (bb);
tree expr = build2 (MODIFY_EXPR, TREE_TYPE (init), red, init);
force_gimple_operand (expr, &stmts, true, NULL);
tree expr = build2 (MODIFY_EXPR, TREE_TYPE (init), red, init);
force_gimple_operand (expr, &stmts, true, NULL);
- gsi_insert_seq_before (&insert_gsi, stmts, GSI_SAME_STMT);
+ gsi_insert_seq_on_edge (edge_initial_value_for_loop_phi (loop_phi), stmts);
}
/* Rewrite out of SSA the reduction described by the loop phi nodes
}
/* Rewrite out of SSA the reduction described by the loop phi nodes
FOR_EACH_LOOP (li, loop, 0)
if (loop_in_sese_p (loop, region))
rewrite_commutative_reductions_out_of_ssa_loop (loop, reductions);
FOR_EACH_LOOP (li, loop, 0)
if (loop_in_sese_p (loop, region))
rewrite_commutative_reductions_out_of_ssa_loop (loop, reductions);
+
+ gsi_commit_edge_inserts ();
+ update_ssa (TODO_update_ssa);
+#ifdef ENABLE_CHECKING
+ verify_ssa (false);
+ verify_loop_closed_ssa ();
+#endif
}
/* Builds the polyhedral representation for a SESE region. */
}
/* Builds the polyhedral representation for a SESE region. */