This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH 47/89] omp-low.c: Use more concrete types of gimple statement for various locals
- From: David Malcolm <dmalcolm at redhat dot com>
- To: gcc-patches at gcc dot gnu dot org
- Cc: David Malcolm <dmalcolm at redhat dot com>
- Date: Mon, 21 Apr 2014 12:57:18 -0400
- Subject: [PATCH 47/89] omp-low.c: Use more concrete types of gimple statement for various locals
- Authentication-results: sourceware.org; auth=none
- References: <1398099480-49147-1-git-send-email-dmalcolm at redhat dot com>
gcc/
* omp-low.c (finalize_task_copyfn): Strengthen local "bind" from
plain gimple to gimple_bind.
(lower_rec_input_clauses): Strengthen local "g" from
plain gimple to gimple_assign.
(lower_lastprivate_clauses): Likewise for "stmt" to gimple_cond
and "g" to gimple_call.
(expand_omp_for_init_vars): Likewise, for two decls of "stmt" to
gimple_assign.
(expand_omp_atomic_pipeline): Likewise for one decl of "stmt".
(expand_omp_atomic_mutex): Likewise.
(lower_omp_master): Likewise for "x" to gimple_call.
(lower_omp_ordered): Likewise.
---
gcc/omp-low.c | 22 ++++++++++++----------
1 file changed, 12 insertions(+), 10 deletions(-)
diff --git a/gcc/omp-low.c b/gcc/omp-low.c
index 6d24927..d3fcba0 100644
--- a/gcc/omp-low.c
+++ b/gcc/omp-low.c
@@ -1373,7 +1373,7 @@ finalize_task_copyfn (gimple_omp_task task_stmt)
struct function *child_cfun;
tree child_fn;
gimple_seq seq = NULL, new_seq;
- gimple bind;
+ gimple_bind bind;
child_fn = gimple_omp_task_copy_fn (task_stmt);
if (child_fn == NULL_TREE)
@@ -3402,7 +3402,7 @@ lower_rec_input_clauses (tree clauses, gimple_seq *ilist, gimple_seq *dlist,
gimplify_and_add (x, ilist);
gimple_stmt_iterator gsi
= gsi_start_1 (gimple_omp_body_ptr (ctx->stmt));
- gimple g
+ gimple_assign g
= gimple_build_assign (unshare_expr (lvar), iv);
gsi_insert_before_without_update (&gsi, g,
GSI_SAME_STMT);
@@ -3740,7 +3740,7 @@ lower_lastprivate_clauses (tree clauses, tree predicate, gimple_seq *stmt_list,
if (predicate)
{
- gimple stmt;
+ gimple_cond stmt;
tree label_true, arm1, arm2;
label = create_artificial_label (UNKNOWN_LOCATION);
@@ -3787,7 +3787,7 @@ lower_lastprivate_clauses (tree clauses, tree predicate, gimple_seq *stmt_list,
if (lastlane == NULL)
{
lastlane = create_tmp_var (unsigned_type_node, NULL);
- gimple g
+ gimple_call g
= gimple_build_call_internal (IFN_GOMP_SIMD_LAST_LANE,
2, simduid,
TREE_OPERAND (val, 1));
@@ -5108,7 +5108,7 @@ expand_omp_for_init_vars (struct omp_for_data *fd, gimple_stmt_iterator *gsi,
tree t = fold_convert (TREE_TYPE (tem), counts[i]);
t = force_gimple_operand_gsi (gsi, t, false, NULL_TREE,
false, GSI_CONTINUE_LINKING);
- gimple stmt = gimple_build_assign (tem, t);
+ gimple_assign stmt = gimple_build_assign (tem, t);
gsi_insert_after (gsi, stmt, GSI_CONTINUE_LINKING);
}
}
@@ -5117,7 +5117,7 @@ expand_omp_for_init_vars (struct omp_for_data *fd, gimple_stmt_iterator *gsi,
tree type = TREE_TYPE (fd->loop.v);
tree tem = create_tmp_reg (type, ".tem");
- gimple stmt = gimple_build_assign (tem, startvar);
+ gimple_assign stmt = gimple_build_assign (tem, startvar);
gsi_insert_after (gsi, stmt, GSI_CONTINUE_LINKING);
for (i = fd->collapse - 1; i >= 0; i--)
@@ -7589,7 +7589,7 @@ expand_omp_atomic_pipeline (basic_block load_bb, basic_block store_bb,
gsi2 = gsi_start_bb (loop_header);
if (gimple_in_ssa_p (cfun))
{
- gimple stmt;
+ gimple_assign stmt;
x = force_gimple_operand_gsi (&gsi2, x, true, NULL_TREE,
true, GSI_SAME_STMT);
stmt = gimple_build_assign (loaded_val, x);
@@ -7702,7 +7702,7 @@ expand_omp_atomic_mutex (basic_block load_bb, basic_block store_bb,
tree addr, tree loaded_val, tree stored_val)
{
gimple_stmt_iterator si;
- gimple stmt;
+ gimple_assign stmt;
tree t;
si = gsi_last_bb (load_bb);
@@ -8738,7 +8738,8 @@ lower_omp_master (gimple_stmt_iterator *gsi_p, omp_context *ctx)
static void
lower_omp_taskgroup (gimple_stmt_iterator *gsi_p, omp_context *ctx)
{
- gimple stmt = gsi_stmt (*gsi_p), x;
+ gimple stmt = gsi_stmt (*gsi_p);
+ gimple_call x;
gimple_bind bind;
tree block = make_node (BLOCK);
@@ -8767,7 +8768,8 @@ static void
lower_omp_ordered (gimple_stmt_iterator *gsi_p, omp_context *ctx)
{
tree block;
- gimple stmt = gsi_stmt (*gsi_p), x;
+ gimple stmt = gsi_stmt (*gsi_p);
+ gimple_call x;
gimple_bind bind;
push_gimplify_context ();
--
1.8.5.3