aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-vect-patterns.c
diff options
context:
space:
mode:
authorTrevor Saunders <tbsaunde@tbsaunde.org>2015-09-20 00:52:59 +0000
committerTrevor Saunders <tbsaunde@gcc.gnu.org>2015-09-20 00:52:59 +0000
commit355fe0884b8097c32e859f0df57c83bde0c6bd26 (patch)
treeaadb7908b4b80ecaf7e744ca1ae42a59a12b07ea /gcc/tree-vect-patterns.c
parente4f2a3e4588bbc3691b452d8a2c520e8196b0ef3 (diff)
downloadgcc-355fe0884b8097c32e859f0df57c83bde0c6bd26.zip
gcc-355fe0884b8097c32e859f0df57c83bde0c6bd26.tar.gz
gcc-355fe0884b8097c32e859f0df57c83bde0c6bd26.tar.bz2
switch from gimple to gimple*
This renames the gimple_statement_base struct to gimple removes the typedef of gimple_statement_base * to gimple, and then adjusts all of the places that use the type. gcc/ChangeLog: 2015-09-19 Trevor Saunders <tbsaunde@tbsaunde.org> * coretypes.h (gimple): Change typedef to be a forward declaration. * gimple.h (gimple_statement_base): rename to gimple. * (all functions and types using gimple): Adjust. * *.[ch]: Likewise. gcc/cp/ChangeLog: 2015-09-19 Trevor Saunders <tbsaunde@tbsaunde.org> * cp-gimplify.c (gimplify_must_not_throw_expr): Adjust. From-SVN: r227941
Diffstat (limited to 'gcc/tree-vect-patterns.c')
-rw-r--r--gcc/tree-vect-patterns.c225
1 files changed, 113 insertions, 112 deletions
diff --git a/gcc/tree-vect-patterns.c b/gcc/tree-vect-patterns.c
index b0aae4f..830801a 100644
--- a/gcc/tree-vect-patterns.c
+++ b/gcc/tree-vect-patterns.c
@@ -51,31 +51,31 @@ along with GCC; see the file COPYING3. If not see
#include "builtins.h"
/* Pattern recognition functions */
-static gimple vect_recog_widen_sum_pattern (vec<gimple> *, tree *,
+static gimple *vect_recog_widen_sum_pattern (vec<gimple *> *, tree *,
tree *);
-static gimple vect_recog_widen_mult_pattern (vec<gimple> *, tree *,
+static gimple *vect_recog_widen_mult_pattern (vec<gimple *> *, tree *,
tree *);
-static gimple vect_recog_dot_prod_pattern (vec<gimple> *, tree *,
+static gimple *vect_recog_dot_prod_pattern (vec<gimple *> *, tree *,
tree *);
-static gimple vect_recog_sad_pattern (vec<gimple> *, tree *,
+static gimple *vect_recog_sad_pattern (vec<gimple *> *, tree *,
tree *);
-static gimple vect_recog_pow_pattern (vec<gimple> *, tree *, tree *);
-static gimple vect_recog_over_widening_pattern (vec<gimple> *, tree *,
+static gimple *vect_recog_pow_pattern (vec<gimple *> *, tree *, tree *);
+static gimple *vect_recog_over_widening_pattern (vec<gimple *> *, tree *,
tree *);
-static gimple vect_recog_widen_shift_pattern (vec<gimple> *,
+static gimple *vect_recog_widen_shift_pattern (vec<gimple *> *,
tree *, tree *);
-static gimple vect_recog_rotate_pattern (vec<gimple> *, tree *, tree *);
-static gimple vect_recog_vector_vector_shift_pattern (vec<gimple> *,
+static gimple *vect_recog_rotate_pattern (vec<gimple *> *, tree *, tree *);
+static gimple *vect_recog_vector_vector_shift_pattern (vec<gimple *> *,
tree *, tree *);
-static gimple vect_recog_divmod_pattern (vec<gimple> *,
+static gimple *vect_recog_divmod_pattern (vec<gimple *> *,
tree *, tree *);
-static gimple vect_recog_mult_pattern (vec<gimple> *,
+static gimple *vect_recog_mult_pattern (vec<gimple *> *,
tree *, tree *);
-static gimple vect_recog_mixed_size_cond_pattern (vec<gimple> *,
+static gimple *vect_recog_mixed_size_cond_pattern (vec<gimple *> *,
tree *, tree *);
-static gimple vect_recog_bool_pattern (vec<gimple> *, tree *, tree *);
+static gimple *vect_recog_bool_pattern (vec<gimple *> *, tree *, tree *);
static vect_recog_func_ptr vect_vect_recog_func_ptrs[NUM_PATTERNS] = {
vect_recog_widen_mult_pattern,
vect_recog_widen_sum_pattern,
@@ -92,14 +92,14 @@ static vect_recog_func_ptr vect_vect_recog_func_ptrs[NUM_PATTERNS] = {
vect_recog_bool_pattern};
static inline void
-append_pattern_def_seq (stmt_vec_info stmt_info, gimple stmt)
+append_pattern_def_seq (stmt_vec_info stmt_info, gimple *stmt)
{
gimple_seq_add_stmt_without_update (&STMT_VINFO_PATTERN_DEF_SEQ (stmt_info),
stmt);
}
static inline void
-new_pattern_def_seq (stmt_vec_info stmt_info, gimple stmt)
+new_pattern_def_seq (stmt_vec_info stmt_info, gimple *stmt)
{
STMT_VINFO_PATTERN_DEF_SEQ (stmt_info) = NULL;
append_pattern_def_seq (stmt_info, stmt);
@@ -114,7 +114,7 @@ new_pattern_def_seq (stmt_vec_info stmt_info, gimple stmt)
to be defined as well. */
static bool
-vect_same_loop_or_bb_p (gimple stmt1, gimple stmt2)
+vect_same_loop_or_bb_p (gimple *stmt1, gimple *stmt2)
{
stmt_vec_info stmt_vinfo = vinfo_for_stmt (stmt1);
loop_vec_info loop_vinfo = STMT_VINFO_LOOP_VINFO (stmt_vinfo);
@@ -143,12 +143,12 @@ vect_same_loop_or_bb_p (gimple stmt1, gimple stmt2)
/* If the LHS of DEF_STMT has a single use, and that statement is
in the same loop or basic block, return it. */
-static gimple
-vect_single_imm_use (gimple def_stmt)
+static gimple *
+vect_single_imm_use (gimple *def_stmt)
{
tree lhs = gimple_assign_lhs (def_stmt);
use_operand_p use_p;
- gimple use_stmt;
+ gimple *use_stmt;
if (!single_imm_use (lhs, &use_p, &use_stmt))
return NULL;
@@ -166,11 +166,11 @@ vect_single_imm_use (gimple def_stmt)
unsigned. */
static bool
-type_conversion_p (tree name, gimple use_stmt, bool check_sign,
- tree *orig_type, gimple *def_stmt, bool *promotion)
+type_conversion_p (tree name, gimple *use_stmt, bool check_sign,
+ tree *orig_type, gimple **def_stmt, bool *promotion)
{
tree dummy;
- gimple dummy_gimple;
+ gimple *dummy_gimple;
loop_vec_info loop_vinfo;
stmt_vec_info stmt_vinfo;
tree type = TREE_TYPE (name);
@@ -222,7 +222,7 @@ type_conversion_p (tree name, gimple use_stmt, bool check_sign,
is NULL, the caller must set SSA_NAME_DEF_STMT for the returned SSA var. */
static tree
-vect_recog_temp_ssa_var (tree type, gimple stmt)
+vect_recog_temp_ssa_var (tree type, gimple *stmt)
{
return make_temp_ssa_name (type, stmt, "patt");
}
@@ -272,16 +272,16 @@ vect_recog_temp_ssa_var (tree type, gimple stmt)
the correct order (as is the case when this computation is in an
inner-loop nested in an outer-loop that us being vectorized). */
-static gimple
-vect_recog_dot_prod_pattern (vec<gimple> *stmts, tree *type_in,
+static gimple *
+vect_recog_dot_prod_pattern (vec<gimple *> *stmts, tree *type_in,
tree *type_out)
{
- gimple stmt, last_stmt = (*stmts)[0];
+ gimple *stmt, *last_stmt = (*stmts)[0];
tree oprnd0, oprnd1;
tree oprnd00, oprnd01;
stmt_vec_info stmt_vinfo = vinfo_for_stmt (last_stmt);
tree type, half_type;
- gimple pattern_stmt;
+ gimple *pattern_stmt;
tree prod_type;
loop_vec_info loop_info = STMT_VINFO_LOOP_VINFO (stmt_vinfo);
struct loop *loop;
@@ -344,7 +344,7 @@ vect_recog_dot_prod_pattern (vec<gimple> *stmts, tree *type_in,
}
else
{
- gimple def_stmt;
+ gimple *def_stmt;
oprnd0 = gimple_assign_rhs1 (last_stmt);
oprnd1 = gimple_assign_rhs2 (last_stmt);
@@ -406,7 +406,7 @@ vect_recog_dot_prod_pattern (vec<gimple> *stmts, tree *type_in,
else
{
tree half_type0, half_type1;
- gimple def_stmt;
+ gimple *def_stmt;
tree oprnd0, oprnd1;
oprnd0 = gimple_assign_rhs1 (stmt);
@@ -490,11 +490,11 @@ vect_recog_dot_prod_pattern (vec<gimple> *stmts, tree *type_in,
SAD_EXPR <x_t, y_t, sum_0>
*/
-static gimple
-vect_recog_sad_pattern (vec<gimple> *stmts, tree *type_in,
+static gimple *
+vect_recog_sad_pattern (vec<gimple *> *stmts, tree *type_in,
tree *type_out)
{
- gimple last_stmt = (*stmts)[0];
+ gimple *last_stmt = (*stmts)[0];
tree sad_oprnd0, sad_oprnd1;
stmt_vec_info stmt_vinfo = vinfo_for_stmt (last_stmt);
tree half_type;
@@ -553,7 +553,7 @@ vect_recog_sad_pattern (vec<gimple> *stmts, tree *type_in,
{
/* Has been detected as widening-summation? */
- gimple stmt = STMT_VINFO_RELATED_STMT (stmt_vinfo);
+ gimple *stmt = STMT_VINFO_RELATED_STMT (stmt_vinfo);
sum_type = gimple_expr_type (stmt);
if (gimple_assign_rhs_code (stmt) != WIDEN_SUM_EXPR)
return NULL;
@@ -563,7 +563,7 @@ vect_recog_sad_pattern (vec<gimple> *stmts, tree *type_in,
}
else
{
- gimple def_stmt;
+ gimple *def_stmt;
plus_oprnd0 = gimple_assign_rhs1 (last_stmt);
plus_oprnd1 = gimple_assign_rhs2 (last_stmt);
@@ -589,7 +589,7 @@ vect_recog_sad_pattern (vec<gimple> *stmts, tree *type_in,
return NULL;
tree abs_type = half_type;
- gimple abs_stmt = SSA_NAME_DEF_STMT (plus_oprnd0);
+ gimple *abs_stmt = SSA_NAME_DEF_STMT (plus_oprnd0);
/* It could not be the sad pattern if the abs_stmt is outside the loop. */
if (!gimple_bb (abs_stmt) || !flow_bb_inside_loop_p (loop, gimple_bb (abs_stmt)))
@@ -618,7 +618,7 @@ vect_recog_sad_pattern (vec<gimple> *stmts, tree *type_in,
if (TREE_CODE (abs_oprnd) != SSA_NAME)
return NULL;
- gimple diff_stmt = SSA_NAME_DEF_STMT (abs_oprnd);
+ gimple *diff_stmt = SSA_NAME_DEF_STMT (abs_oprnd);
/* It could not be the sad pattern if the diff_stmt is outside the loop. */
if (!gimple_bb (diff_stmt)
@@ -638,7 +638,7 @@ vect_recog_sad_pattern (vec<gimple> *stmts, tree *type_in,
return NULL;
tree half_type0, half_type1;
- gimple def_stmt;
+ gimple *def_stmt;
tree minus_oprnd0 = gimple_assign_rhs1 (diff_stmt);
tree minus_oprnd1 = gimple_assign_rhs2 (diff_stmt);
@@ -669,8 +669,8 @@ vect_recog_sad_pattern (vec<gimple> *stmts, tree *type_in,
/* Pattern detected. Create a stmt to be used to replace the pattern: */
tree var = vect_recog_temp_ssa_var (sum_type, NULL);
- gimple pattern_stmt = gimple_build_assign (var, SAD_EXPR, sad_oprnd0,
- sad_oprnd1, plus_oprnd1);
+ gimple *pattern_stmt = gimple_build_assign (var, SAD_EXPR, sad_oprnd0,
+ sad_oprnd1, plus_oprnd1);
if (dump_enabled_p ())
{
@@ -697,10 +697,10 @@ vect_recog_sad_pattern (vec<gimple> *stmts, tree *type_in,
with a_it = (interm_type) a_t; Store such operation in *WSTMT. */
static bool
-vect_handle_widen_op_by_const (gimple stmt, enum tree_code code,
+vect_handle_widen_op_by_const (gimple *stmt, enum tree_code code,
tree const_oprnd, tree *oprnd,
- gimple *wstmt, tree type,
- tree *half_type, gimple def_stmt)
+ gimple **wstmt, tree type,
+ tree *half_type, gimple *def_stmt)
{
tree new_type, new_oprnd;
@@ -821,15 +821,15 @@ vect_handle_widen_op_by_const (gimple stmt, enum tree_code code,
returned stmt will be this type conversion stmt.
*/
-static gimple
-vect_recog_widen_mult_pattern (vec<gimple> *stmts,
+static gimple *
+vect_recog_widen_mult_pattern (vec<gimple *> *stmts,
tree *type_in, tree *type_out)
{
- gimple last_stmt = stmts->pop ();
- gimple def_stmt0, def_stmt1;
+ gimple *last_stmt = stmts->pop ();
+ gimple *def_stmt0, *def_stmt1;
tree oprnd0, oprnd1;
tree type, half_type0, half_type1;
- gimple new_stmt = NULL, pattern_stmt = NULL;
+ gimple *new_stmt = NULL, *pattern_stmt = NULL;
tree vectype, vecitype;
tree var;
enum tree_code dummy_code;
@@ -893,7 +893,7 @@ vect_recog_widen_mult_pattern (vec<gimple> *stmts,
return NULL;
tree* oprnd = NULL;
- gimple def_stmt = NULL;
+ gimple *def_stmt = NULL;
if (TYPE_PRECISION (half_type0) < TYPE_PRECISION (half_type1))
{
@@ -919,7 +919,7 @@ vect_recog_widen_mult_pattern (vec<gimple> *stmts,
Use unsigned TYPE as the type for WIDEN_MULT_EXPR. */
if (TYPE_UNSIGNED (type) != TYPE_UNSIGNED (half_type0))
{
- gimple use_stmt;
+ gimple *use_stmt;
tree use_lhs;
tree use_type;
@@ -1042,13 +1042,13 @@ vect_recog_widen_mult_pattern (vec<gimple> *stmts,
x = sqrt (x)
*/
-static gimple
-vect_recog_pow_pattern (vec<gimple> *stmts, tree *type_in,
+static gimple *
+vect_recog_pow_pattern (vec<gimple *> *stmts, tree *type_in,
tree *type_out)
{
- gimple last_stmt = (*stmts)[0];
+ gimple *last_stmt = (*stmts)[0];
tree fn, base, exp = NULL;
- gimple stmt;
+ gimple *stmt;
tree var;
if (!is_gimple_call (last_stmt) || gimple_call_lhs (last_stmt) == NULL)
@@ -1155,15 +1155,15 @@ vect_recog_pow_pattern (vec<gimple> *stmts, tree *type_in,
the correct order (as is the case when this computation is in an
inner-loop nested in an outer-loop that us being vectorized). */
-static gimple
-vect_recog_widen_sum_pattern (vec<gimple> *stmts, tree *type_in,
+static gimple *
+vect_recog_widen_sum_pattern (vec<gimple *> *stmts, tree *type_in,
tree *type_out)
{
- gimple stmt, last_stmt = (*stmts)[0];
+ gimple *stmt, *last_stmt = (*stmts)[0];
tree oprnd0, oprnd1;
stmt_vec_info stmt_vinfo = vinfo_for_stmt (last_stmt);
tree type, half_type;
- gimple pattern_stmt;
+ gimple *pattern_stmt;
loop_vec_info loop_info = STMT_VINFO_LOOP_VINFO (stmt_vinfo);
struct loop *loop;
tree var;
@@ -1263,14 +1263,14 @@ vect_recog_widen_sum_pattern (vec<gimple> *stmts, tree *type_in,
the second pattern statement. */
static bool
-vect_operation_fits_smaller_type (gimple stmt, tree def, tree *new_type,
- tree *op0, tree *op1, gimple *new_def_stmt,
- vec<gimple> *stmts)
+vect_operation_fits_smaller_type (gimple *stmt, tree def, tree *new_type,
+ tree *op0, tree *op1, gimple **new_def_stmt,
+ vec<gimple *> *stmts)
{
enum tree_code code;
tree const_oprnd, oprnd;
tree interm_type = NULL_TREE, half_type, new_oprnd, type;
- gimple def_stmt, new_stmt;
+ gimple *def_stmt, *new_stmt;
bool first = false;
bool promotion;
@@ -1467,12 +1467,13 @@ vect_operation_fits_smaller_type (gimple stmt, tree def, tree *new_type,
be 'type' or some intermediate type. For now, we expect S5 to be a type
demotion operation. We also check that S3 and S4 have only one use. */
-static gimple
-vect_recog_over_widening_pattern (vec<gimple> *stmts,
+static gimple *
+vect_recog_over_widening_pattern (vec<gimple *> *stmts,
tree *type_in, tree *type_out)
{
- gimple stmt = stmts->pop ();
- gimple pattern_stmt = NULL, new_def_stmt, prev_stmt = NULL, use_stmt = NULL;
+ gimple *stmt = stmts->pop ();
+ gimple *pattern_stmt = NULL, *new_def_stmt, *prev_stmt = NULL,
+ *use_stmt = NULL;
tree op0, op1, vectype = NULL_TREE, use_lhs, use_type;
tree var = NULL_TREE, new_type = NULL_TREE, new_oprnd;
bool first;
@@ -1657,21 +1658,21 @@ vect_recog_over_widening_pattern (vec<gimple> *stmts,
stmts that constitute the pattern. In this case it will be:
WIDEN_LSHIFT_EXPR <a_t, CONST>. */
-static gimple
-vect_recog_widen_shift_pattern (vec<gimple> *stmts,
+static gimple *
+vect_recog_widen_shift_pattern (vec<gimple *> *stmts,
tree *type_in, tree *type_out)
{
- gimple last_stmt = stmts->pop ();
- gimple def_stmt0;
+ gimple *last_stmt = stmts->pop ();
+ gimple *def_stmt0;
tree oprnd0, oprnd1;
tree type, half_type0;
- gimple pattern_stmt;
+ gimple *pattern_stmt;
tree vectype, vectype_out = NULL_TREE;
tree var;
enum tree_code dummy_code;
int dummy_int;
vec<tree> dummy_vec;
- gimple use_stmt;
+ gimple *use_stmt;
bool promotion;
if (!is_gimple_assign (last_stmt) || !vinfo_for_stmt (last_stmt))
@@ -1720,7 +1721,7 @@ vect_recog_widen_shift_pattern (vec<gimple> *stmts,
}
/* Check if this a widening operation. */
- gimple wstmt = NULL;
+ gimple *wstmt = NULL;
if (!vect_handle_widen_op_by_const (last_stmt, LSHIFT_EXPR, oprnd1,
&oprnd0, &wstmt,
type, &half_type0, def_stmt0))
@@ -1798,12 +1799,12 @@ vect_recog_widen_shift_pattern (vec<gimple> *stmts,
* Return value: A new stmt that will be used to replace the rotate
S0 stmt. */
-static gimple
-vect_recog_rotate_pattern (vec<gimple> *stmts, tree *type_in, tree *type_out)
+static gimple *
+vect_recog_rotate_pattern (vec<gimple *> *stmts, tree *type_in, tree *type_out)
{
- gimple last_stmt = stmts->pop ();
+ gimple *last_stmt = stmts->pop ();
tree oprnd0, oprnd1, lhs, var, var1, var2, vectype, type, stype, def, def2;
- gimple pattern_stmt, def_stmt;
+ gimple *pattern_stmt, *def_stmt;
enum tree_code rhs_code;
stmt_vec_info stmt_vinfo = vinfo_for_stmt (last_stmt);
loop_vec_info loop_vinfo = STMT_VINFO_LOOP_VINFO (stmt_vinfo);
@@ -2056,13 +2057,13 @@ vect_recog_rotate_pattern (vec<gimple> *stmts, tree *type_in, tree *type_out)
* Return value: A new stmt that will be used to replace the shift/rotate
S3 stmt. */
-static gimple
-vect_recog_vector_vector_shift_pattern (vec<gimple> *stmts,
+static gimple *
+vect_recog_vector_vector_shift_pattern (vec<gimple *> *stmts,
tree *type_in, tree *type_out)
{
- gimple last_stmt = stmts->pop ();
+ gimple *last_stmt = stmts->pop ();
tree oprnd0, oprnd1, lhs, var;
- gimple pattern_stmt, def_stmt;
+ gimple *pattern_stmt, *def_stmt;
enum tree_code rhs_code;
stmt_vec_info stmt_vinfo = vinfo_for_stmt (last_stmt);
loop_vec_info loop_vinfo = STMT_VINFO_LOOP_VINFO (stmt_vinfo);
@@ -2181,13 +2182,13 @@ vect_recog_vector_vector_shift_pattern (vec<gimple> *stmts,
* Return value: A new stmt that will be used to replace the multiplication
S1 or S2 stmt. */
-static gimple
-vect_recog_mult_pattern (vec<gimple> *stmts,
+static gimple *
+vect_recog_mult_pattern (vec<gimple *> *stmts,
tree *type_in, tree *type_out)
{
- gimple last_stmt = stmts->pop ();
+ gimple *last_stmt = stmts->pop ();
tree oprnd0, oprnd1, vectype, itype;
- gimple pattern_stmt, def_stmt;
+ gimple *pattern_stmt, *def_stmt;
optab optab;
stmt_vec_info stmt_vinfo = vinfo_for_stmt (last_stmt);
int power2_val, power2_neg_val;
@@ -2319,13 +2320,13 @@ vect_recog_mult_pattern (vec<gimple> *stmts,
* Return value: A new stmt that will be used to replace the division
S1 or modulo S4 stmt. */
-static gimple
-vect_recog_divmod_pattern (vec<gimple> *stmts,
+static gimple *
+vect_recog_divmod_pattern (vec<gimple *> *stmts,
tree *type_in, tree *type_out)
{
- gimple last_stmt = stmts->pop ();
+ gimple *last_stmt = stmts->pop ();
tree oprnd0, oprnd1, vectype, itype, cond;
- gimple pattern_stmt, def_stmt;
+ gimple *pattern_stmt, *def_stmt;
enum tree_code rhs_code;
stmt_vec_info stmt_vinfo = vinfo_for_stmt (last_stmt);
loop_vec_info loop_vinfo = STMT_VINFO_LOOP_VINFO (stmt_vinfo);
@@ -2769,19 +2770,19 @@ vect_recog_divmod_pattern (vec<gimple> *stmts,
a_it = x_t CMP y_t ? b_it : c_it;
a_T = (TYPE) a_it; */
-static gimple
-vect_recog_mixed_size_cond_pattern (vec<gimple> *stmts, tree *type_in,
+static gimple *
+vect_recog_mixed_size_cond_pattern (vec<gimple *> *stmts, tree *type_in,
tree *type_out)
{
- gimple last_stmt = (*stmts)[0];
+ gimple *last_stmt = (*stmts)[0];
tree cond_expr, then_clause, else_clause;
stmt_vec_info stmt_vinfo = vinfo_for_stmt (last_stmt), def_stmt_info;
tree type, vectype, comp_vectype, itype = NULL_TREE, vecitype;
- gimple pattern_stmt, def_stmt;
+ gimple *pattern_stmt, *def_stmt;
loop_vec_info loop_vinfo = STMT_VINFO_LOOP_VINFO (stmt_vinfo);
bb_vec_info bb_vinfo = STMT_VINFO_BB_VINFO (stmt_vinfo);
tree orig_type0 = NULL_TREE, orig_type1 = NULL_TREE;
- gimple def_stmt0 = NULL, def_stmt1 = NULL;
+ gimple *def_stmt0 = NULL, *def_stmt1 = NULL;
bool promotion;
tree comp_scalar_type;
@@ -2904,7 +2905,7 @@ vect_recog_mixed_size_cond_pattern (vec<gimple> *stmts, tree *type_in,
static bool
check_bool_pattern (tree var, loop_vec_info loop_vinfo, bb_vec_info bb_vinfo)
{
- gimple def_stmt;
+ gimple *def_stmt;
enum vect_def_type dt;
tree def, rhs1;
enum tree_code rhs_code;
@@ -2987,7 +2988,7 @@ static tree
adjust_bool_pattern_cast (tree type, tree var)
{
stmt_vec_info stmt_vinfo = vinfo_for_stmt (SSA_NAME_DEF_STMT (var));
- gimple cast_stmt, pattern_stmt;
+ gimple *cast_stmt, *pattern_stmt;
gcc_assert (!STMT_VINFO_PATTERN_DEF_SEQ (stmt_vinfo));
pattern_stmt = STMT_VINFO_RELATED_STMT (stmt_vinfo);
@@ -3009,13 +3010,13 @@ adjust_bool_pattern_cast (tree type, tree var)
static tree
adjust_bool_pattern (tree var, tree out_type, tree trueval,
- vec<gimple> *stmts)
+ vec<gimple *> *stmts)
{
- gimple stmt = SSA_NAME_DEF_STMT (var);
+ gimple *stmt = SSA_NAME_DEF_STMT (var);
enum tree_code rhs_code, def_rhs_code;
tree itype, cond_expr, rhs1, rhs2, irhs1, irhs2;
location_t loc;
- gimple pattern_stmt, def_stmt;
+ gimple *pattern_stmt, *def_stmt;
rhs1 = gimple_assign_rhs1 (stmt);
rhs2 = gimple_assign_rhs2 (stmt);
@@ -3083,7 +3084,7 @@ adjust_bool_pattern (tree var, tree out_type, tree trueval,
if (TYPE_PRECISION (TREE_TYPE (irhs1))
== GET_MODE_BITSIZE (TYPE_MODE (TREE_TYPE (def_rhs1))))
{
- gimple tstmt;
+ gimple *tstmt;
stmt_vec_info stmt_def_vinfo = vinfo_for_stmt (def_stmt);
irhs2 = adjust_bool_pattern (rhs2, out_type, irhs1, stmts);
tstmt = stmts->pop ();
@@ -3108,7 +3109,7 @@ adjust_bool_pattern (tree var, tree out_type, tree trueval,
if (TYPE_PRECISION (TREE_TYPE (irhs2))
== GET_MODE_BITSIZE (TYPE_MODE (TREE_TYPE (def_rhs1))))
{
- gimple tstmt;
+ gimple *tstmt;
stmt_vec_info stmt_def_vinfo = vinfo_for_stmt (def_stmt);
irhs1 = adjust_bool_pattern (rhs1, out_type, irhs2, stmts);
tstmt = stmts->pop ();
@@ -3234,17 +3235,17 @@ adjust_bool_pattern (tree var, tree out_type, tree trueval,
S3' c_T = a_T | b_T;
but the above is more efficient. */
-static gimple
-vect_recog_bool_pattern (vec<gimple> *stmts, tree *type_in,
+static gimple *
+vect_recog_bool_pattern (vec<gimple *> *stmts, tree *type_in,
tree *type_out)
{
- gimple last_stmt = stmts->pop ();
+ gimple *last_stmt = stmts->pop ();
enum tree_code rhs_code;
tree var, lhs, rhs, vectype;
stmt_vec_info stmt_vinfo = vinfo_for_stmt (last_stmt);
loop_vec_info loop_vinfo = STMT_VINFO_LOOP_VINFO (stmt_vinfo);
bb_vec_info bb_vinfo = STMT_VINFO_BB_VINFO (stmt_vinfo);
- gimple pattern_stmt;
+ gimple *pattern_stmt;
if (!is_gimple_assign (last_stmt))
return NULL;
@@ -3341,7 +3342,7 @@ vect_recog_bool_pattern (vec<gimple> *stmts, tree *type_in,
if (!useless_type_conversion_p (TREE_TYPE (lhs), TREE_TYPE (rhs)))
{
tree rhs2 = vect_recog_temp_ssa_var (TREE_TYPE (lhs), NULL);
- gimple cast_stmt = gimple_build_assign (rhs2, NOP_EXPR, rhs);
+ gimple *cast_stmt = gimple_build_assign (rhs2, NOP_EXPR, rhs);
new_pattern_def_seq (stmt_vinfo, cast_stmt);
rhs = rhs2;
}
@@ -3376,14 +3377,14 @@ vect_recog_bool_pattern (vec<gimple> *stmts, tree *type_in,
/* Mark statements that are involved in a pattern. */
static inline void
-vect_mark_pattern_stmts (gimple orig_stmt, gimple pattern_stmt,
+vect_mark_pattern_stmts (gimple *orig_stmt, gimple *pattern_stmt,
tree pattern_vectype)
{
stmt_vec_info pattern_stmt_info, def_stmt_info;
stmt_vec_info orig_stmt_info = vinfo_for_stmt (orig_stmt);
loop_vec_info loop_vinfo = STMT_VINFO_LOOP_VINFO (orig_stmt_info);
bb_vec_info bb_vinfo = STMT_VINFO_BB_VINFO (orig_stmt_info);
- gimple def_stmt;
+ gimple *def_stmt;
pattern_stmt_info = vinfo_for_stmt (pattern_stmt);
if (pattern_stmt_info == NULL)
@@ -3450,16 +3451,16 @@ vect_mark_pattern_stmts (gimple orig_stmt, gimple pattern_stmt,
static void
vect_pattern_recog_1 (vect_recog_func_ptr vect_recog_func,
gimple_stmt_iterator si,
- vec<gimple> *stmts_to_replace)
+ vec<gimple *> *stmts_to_replace)
{
- gimple stmt = gsi_stmt (si), pattern_stmt;
+ gimple *stmt = gsi_stmt (si), *pattern_stmt;
stmt_vec_info stmt_info;
loop_vec_info loop_vinfo;
tree pattern_vectype;
tree type_in, type_out;
enum tree_code code;
int i;
- gimple next;
+ gimple *next;
stmts_to_replace->truncate (0);
stmts_to_replace->quick_push (stmt);
@@ -3636,8 +3637,8 @@ vect_pattern_recog (loop_vec_info loop_vinfo, bb_vec_info bb_vinfo)
gimple_stmt_iterator si;
unsigned int i, j;
vect_recog_func_ptr vect_recog_func;
- auto_vec<gimple, 1> stmts_to_replace;
- gimple stmt;
+ auto_vec<gimple *, 1> stmts_to_replace;
+ gimple *stmt;
if (dump_enabled_p ())
dump_printf_loc (MSG_NOTE, vect_location,