Hi David,
Just a quick review of the gimple-ssa-strength-reduction.c changes. I
have one stylistic comment:
On Mon, 2014-04-21 at 12:57 -0400, David Malcolm wrote:
> diff --git a/gcc/gimple-ssa-strength-reduction.c
> b/gcc/gimple-ssa-strength-reduction.c
> index 9320b51..35e15e0 100644
> --- a/gcc/gimple-ssa-strength-reduction.c
> +++ b/gcc/gimple-ssa-strength-reduction.c
> @@ -2058,7 +2058,7 @@ replace_mult_candidate (slsr_cand_t c, tree basis_name,
> double_int bump)
> if (bump.is_zero ())
> {
> tree lhs = gimple_assign_lhs (c->cand_stmt);
> - gimple copy_stmt = gimple_build_assign (lhs, basis_name);
> + gimple_assign copy_stmt = gimple_build_assign (lhs, basis_name);
> gimple_stmt_iterator gsi = gsi_for_stmt (c->cand_stmt);
> gimple_set_location (copy_stmt, gimple_location (c->cand_stmt));
> gsi_replace (&gsi, copy_stmt, false);
> @@ -2159,7 +2159,7 @@ create_add_on_incoming_edge (slsr_cand_t c, tree
> basis_name,
> basic_block insert_bb;
> gimple_stmt_iterator gsi;
> tree lhs, basis_type;
> - gimple new_stmt;
> + gimple_assign new_stmt;
>
> /* If the add candidate along this incoming edge has the same
> index as C's hidden basis, the hidden basis represents this
> @@ -3118,7 +3118,7 @@ insert_initializers (slsr_cand_t c)
> {
> basic_block bb;
> slsr_cand_t where = NULL;
> - gimple init_stmt;
> + gimple_assign init_stmt;
> tree stride_type, new_name, incr_tree;
> double_int incr = incr_vec[i].incr;
>
> @@ -3256,7 +3256,7 @@ static tree
> introduce_cast_before_cand (slsr_cand_t c, tree to_type, tree from_expr)
> {
> tree cast_lhs;
> - gimple cast_stmt;
> + gimple_assign cast_stmt;
> gimple_stmt_iterator gsi = gsi_for_stmt (c->cand_stmt);
>
> cast_lhs = make_temp_ssa_name (to_type, NULL, "slsr");
> @@ -3418,7 +3418,7 @@ replace_one_candidate (slsr_cand_t c, unsigned i, tree
> basis_name)
>
> if (types_compatible_p (lhs_type, basis_type))
> {
> - gimple copy_stmt = gimple_build_assign (lhs, basis_name);
> + gimple_assign copy_stmt = gimple_build_assign (lhs, basis_name);
> gimple_stmt_iterator gsi = gsi_for_stmt (c->cand_stmt);
> gimple_set_location (copy_stmt, gimple_location (c->cand_stmt));
> gsi_replace (&gsi, copy_stmt, false);
> @@ -3430,9 +3430,10 @@ replace_one_candidate (slsr_cand_t c, unsigned i, tree
> basis_name)
> else
> {
> gimple_stmt_iterator gsi = gsi_for_stmt (c->cand_stmt);
> - gimple cast_stmt = gimple_build_assign_with_ops (NOP_EXPR, lhs,
> - basis_name,
> - NULL_TREE);
> + gimple_assign cast_stmt =
> + gimple_build_assign_with_ops (NOP_EXPR, lhs,
> + basis_name,
> + NULL_TREE);
Please collapse the last three lines onto one line, now that it will
fit.
Thanks,
Bill
> gimple_set_location (cast_stmt, gimple_location (c->cand_stmt));
> gsi_replace (&gsi, cast_stmt, false);
> c->cand_stmt = cast_stmt;