Clean up supportable_widening_operation.
* tree-vect-stmts.c (supportable_widening_operation): Remove decl parameters. (vectorizable_conversion): Update supportable_widening_operation call. * tree-vect-patterns.c (vect_recog_widen_mult_pattern): Likewise. (vect_recog_widen_shift_pattern): Likewise. * tree-vectorizer.h: Update decl. From-SVN: r189574
This commit is contained in:
parent
24cb156d23
commit
a86ec59783
|
@ -1,3 +1,12 @@
|
||||||
|
2012-07-17 Richard Henderson <rth@redhat.com>
|
||||||
|
|
||||||
|
* tree-vect-stmts.c (supportable_widening_operation): Remove decl
|
||||||
|
parameters.
|
||||||
|
(vectorizable_conversion): Update supportable_widening_operation call.
|
||||||
|
* tree-vect-patterns.c (vect_recog_widen_mult_pattern): Likewise.
|
||||||
|
(vect_recog_widen_shift_pattern): Likewise.
|
||||||
|
* tree-vectorizer.h: Update decl.
|
||||||
|
|
||||||
2012-07-17 Ramana Radhakrishnan <ramana.radhakrishnan@linaro.org>
|
2012-07-17 Ramana Radhakrishnan <ramana.radhakrishnan@linaro.org>
|
||||||
Ulrich Weigand <ulrich.weigand@linaro.org>
|
Ulrich Weigand <ulrich.weigand@linaro.org>
|
||||||
|
|
||||||
|
|
|
@ -599,7 +599,6 @@ vect_recog_widen_mult_pattern (VEC (gimple, heap) **stmts,
|
||||||
tree type, half_type0, half_type1;
|
tree type, half_type0, half_type1;
|
||||||
gimple pattern_stmt;
|
gimple pattern_stmt;
|
||||||
tree vectype, vectype_out = NULL_TREE;
|
tree vectype, vectype_out = NULL_TREE;
|
||||||
tree dummy;
|
|
||||||
tree var;
|
tree var;
|
||||||
enum tree_code dummy_code;
|
enum tree_code dummy_code;
|
||||||
int dummy_int;
|
int dummy_int;
|
||||||
|
@ -692,8 +691,8 @@ vect_recog_widen_mult_pattern (VEC (gimple, heap) **stmts,
|
||||||
|| !vectype_out
|
|| !vectype_out
|
||||||
|| !supportable_widening_operation (WIDEN_MULT_EXPR, last_stmt,
|
|| !supportable_widening_operation (WIDEN_MULT_EXPR, last_stmt,
|
||||||
vectype_out, vectype,
|
vectype_out, vectype,
|
||||||
&dummy, &dummy, &dummy_code,
|
&dummy_code, &dummy_code,
|
||||||
&dummy_code, &dummy_int, &dummy_vec))
|
&dummy_int, &dummy_vec))
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
*type_in = vectype;
|
*type_in = vectype;
|
||||||
|
@ -1370,7 +1369,6 @@ vect_recog_widen_shift_pattern (VEC (gimple, heap) **stmts,
|
||||||
tree type, half_type0;
|
tree type, half_type0;
|
||||||
gimple pattern_stmt;
|
gimple pattern_stmt;
|
||||||
tree vectype, vectype_out = NULL_TREE;
|
tree vectype, vectype_out = NULL_TREE;
|
||||||
tree dummy;
|
|
||||||
tree var;
|
tree var;
|
||||||
enum tree_code dummy_code;
|
enum tree_code dummy_code;
|
||||||
int dummy_int;
|
int dummy_int;
|
||||||
|
@ -1441,9 +1439,8 @@ vect_recog_widen_shift_pattern (VEC (gimple, heap) **stmts,
|
||||||
|| !vectype_out
|
|| !vectype_out
|
||||||
|| !supportable_widening_operation (WIDEN_LSHIFT_EXPR, last_stmt,
|
|| !supportable_widening_operation (WIDEN_LSHIFT_EXPR, last_stmt,
|
||||||
vectype_out, vectype,
|
vectype_out, vectype,
|
||||||
&dummy, &dummy, &dummy_code,
|
&dummy_code, &dummy_code,
|
||||||
&dummy_code, &dummy_int,
|
&dummy_int, &dummy_vec))
|
||||||
&dummy_vec))
|
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
*type_in = vectype;
|
*type_in = vectype;
|
||||||
|
|
|
@ -2410,8 +2410,8 @@ vectorizable_conversion (gimple stmt, gimple_stmt_iterator *gsi,
|
||||||
|
|
||||||
case WIDEN:
|
case WIDEN:
|
||||||
if (supportable_widening_operation (code, stmt, vectype_out, vectype_in,
|
if (supportable_widening_operation (code, stmt, vectype_out, vectype_in,
|
||||||
&decl1, &decl2, &code1, &code2,
|
&code1, &code2, &multi_step_cvt,
|
||||||
&multi_step_cvt, &interm_types))
|
&interm_types))
|
||||||
{
|
{
|
||||||
/* Binary widening operation can only be supported directly by the
|
/* Binary widening operation can only be supported directly by the
|
||||||
architecture. */
|
architecture. */
|
||||||
|
@ -2443,18 +2443,16 @@ vectorizable_conversion (gimple stmt, gimple_stmt_iterator *gsi,
|
||||||
goto unsupported;
|
goto unsupported;
|
||||||
}
|
}
|
||||||
else if (!supportable_widening_operation (code, stmt, vectype_out,
|
else if (!supportable_widening_operation (code, stmt, vectype_out,
|
||||||
cvt_type, &decl1, &decl2,
|
cvt_type, &codecvt1,
|
||||||
&codecvt1, &codecvt2,
|
&codecvt2, &multi_step_cvt,
|
||||||
&multi_step_cvt,
|
|
||||||
&interm_types))
|
&interm_types))
|
||||||
continue;
|
continue;
|
||||||
else
|
else
|
||||||
gcc_assert (multi_step_cvt == 0);
|
gcc_assert (multi_step_cvt == 0);
|
||||||
|
|
||||||
if (supportable_widening_operation (NOP_EXPR, stmt, cvt_type,
|
if (supportable_widening_operation (NOP_EXPR, stmt, cvt_type,
|
||||||
vectype_in, NULL, NULL, &code1,
|
vectype_in, &code1, &code2,
|
||||||
&code2, &multi_step_cvt,
|
&multi_step_cvt, &interm_types))
|
||||||
&interm_types))
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -6262,9 +6260,6 @@ vect_is_simple_use_1 (tree operand, gimple stmt, loop_vec_info loop_vinfo,
|
||||||
Output:
|
Output:
|
||||||
- CODE1 and CODE2 are codes of vector operations to be used when
|
- CODE1 and CODE2 are codes of vector operations to be used when
|
||||||
vectorizing the operation, if available.
|
vectorizing the operation, if available.
|
||||||
- DECL1 and DECL2 are decls of target builtin functions to be used
|
|
||||||
when vectorizing the operation, if available. In this case,
|
|
||||||
CODE1 and CODE2 are CALL_EXPR.
|
|
||||||
- MULTI_STEP_CVT determines the number of required intermediate steps in
|
- MULTI_STEP_CVT determines the number of required intermediate steps in
|
||||||
case of multi-step conversion (like char->short->int - in that case
|
case of multi-step conversion (like char->short->int - in that case
|
||||||
MULTI_STEP_CVT will be 1).
|
MULTI_STEP_CVT will be 1).
|
||||||
|
@ -6274,8 +6269,6 @@ vect_is_simple_use_1 (tree operand, gimple stmt, loop_vec_info loop_vinfo,
|
||||||
bool
|
bool
|
||||||
supportable_widening_operation (enum tree_code code, gimple stmt,
|
supportable_widening_operation (enum tree_code code, gimple stmt,
|
||||||
tree vectype_out, tree vectype_in,
|
tree vectype_out, tree vectype_in,
|
||||||
tree *decl1 ATTRIBUTE_UNUSED,
|
|
||||||
tree *decl2 ATTRIBUTE_UNUSED,
|
|
||||||
enum tree_code *code1, enum tree_code *code2,
|
enum tree_code *code1, enum tree_code *code2,
|
||||||
int *multi_step_cvt,
|
int *multi_step_cvt,
|
||||||
VEC (tree, heap) **interm_types)
|
VEC (tree, heap) **interm_types)
|
||||||
|
@ -6339,8 +6332,8 @@ supportable_widening_operation (enum tree_code code, gimple stmt,
|
||||||
&& !nested_in_vect_loop_p (vect_loop, stmt)
|
&& !nested_in_vect_loop_p (vect_loop, stmt)
|
||||||
&& supportable_widening_operation (VEC_WIDEN_MULT_EVEN_EXPR,
|
&& supportable_widening_operation (VEC_WIDEN_MULT_EVEN_EXPR,
|
||||||
stmt, vectype_out, vectype_in,
|
stmt, vectype_out, vectype_in,
|
||||||
NULL, NULL, code1, code2,
|
code1, code2, multi_step_cvt,
|
||||||
multi_step_cvt, interm_types))
|
interm_types))
|
||||||
return true;
|
return true;
|
||||||
c1 = VEC_WIDEN_MULT_LO_EXPR;
|
c1 = VEC_WIDEN_MULT_LO_EXPR;
|
||||||
c2 = VEC_WIDEN_MULT_HI_EXPR;
|
c2 = VEC_WIDEN_MULT_HI_EXPR;
|
||||||
|
|
|
@ -895,9 +895,8 @@ extern bool vect_is_simple_use_1 (tree, gimple, loop_vec_info,
|
||||||
bb_vec_info, gimple *,
|
bb_vec_info, gimple *,
|
||||||
tree *, enum vect_def_type *, tree *);
|
tree *, enum vect_def_type *, tree *);
|
||||||
extern bool supportable_widening_operation (enum tree_code, gimple, tree, tree,
|
extern bool supportable_widening_operation (enum tree_code, gimple, tree, tree,
|
||||||
tree *, tree *, enum tree_code *,
|
enum tree_code *, enum tree_code *,
|
||||||
enum tree_code *, int *,
|
int *, VEC (tree, heap) **);
|
||||||
VEC (tree, heap) **);
|
|
||||||
extern bool supportable_narrowing_operation (enum tree_code, tree, tree,
|
extern bool supportable_narrowing_operation (enum tree_code, tree, tree,
|
||||||
enum tree_code *,
|
enum tree_code *,
|
||||||
int *, VEC (tree, heap) **);
|
int *, VEC (tree, heap) **);
|
||||||
|
|
Loading…
Reference in New Issue