From: Richard Sandiford Date: Mon, 21 Oct 2019 06:41:31 +0000 (+0000) Subject: Pass a vec_info to vect_double_mask_nunits X-Git-Tag: upstream/12.2.0~21006 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8d1473958808fe4714ec24991ac83ee6cbf45397;p=platform%2Fupstream%2Fgcc.git Pass a vec_info to vect_double_mask_nunits 2019-10-21 Richard Sandiford gcc/ * tree-vectorizer.h (vect_double_mask_nunits): Take a vec_info. * tree-vect-loop.c (vect_double_mask_nunits): Likewise. * tree-vect-stmts.c (supportable_narrowing_operation): Update call accordingly. From-SVN: r277234 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 8ae7192..dc092c5 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,12 @@ 2019-10-21 Richard Sandiford + * tree-vectorizer.h (vect_double_mask_nunits): Take a vec_info. + * tree-vect-loop.c (vect_double_mask_nunits): Likewise. + * tree-vect-stmts.c (supportable_narrowing_operation): Update call + accordingly. + +2019-10-21 Richard Sandiford + * tree-vectorizer.h (vect_halve_mask_nunits): Take a vec_info. * tree-vect-loop.c (vect_halve_mask_nunits): Likewise. * tree-vect-loop-manip.c (vect_maybe_permute_loop_masks): Update diff --git a/gcc/tree-vect-loop.c b/gcc/tree-vect-loop.c index 5c29084..f6101f3 100644 --- a/gcc/tree-vect-loop.c +++ b/gcc/tree-vect-loop.c @@ -7754,7 +7754,7 @@ vect_halve_mask_nunits (vec_info *, tree type) /* Return a mask type with twice as many elements as TYPE. */ tree -vect_double_mask_nunits (tree type) +vect_double_mask_nunits (vec_info *, tree type) { poly_uint64 nunits = TYPE_VECTOR_SUBPARTS (type) * 2; return build_truth_vector_type (nunits, current_vector_size); diff --git a/gcc/tree-vect-stmts.c b/gcc/tree-vect-stmts.c index 690e2c4..c8f1582 100644 --- a/gcc/tree-vect-stmts.c +++ b/gcc/tree-vect-stmts.c @@ -11650,7 +11650,7 @@ supportable_widening_operation (enum tree_code code, stmt_vec_info stmt_info, narrowing operation (short in the above example). */ bool -supportable_narrowing_operation (vec_info *, enum tree_code code, +supportable_narrowing_operation (vec_info *vinfo, enum tree_code code, tree vectype_out, tree vectype_in, enum tree_code *code1, int *multi_step_cvt, vec *interm_types) @@ -11759,7 +11759,7 @@ supportable_narrowing_operation (vec_info *, enum tree_code code, intermediate_mode = insn_data[icode1].operand[0].mode; if (VECTOR_BOOLEAN_TYPE_P (prev_type)) { - intermediate_type = vect_double_mask_nunits (prev_type); + intermediate_type = vect_double_mask_nunits (vinfo, prev_type); if (intermediate_mode != TYPE_MODE (intermediate_type)) return false; } diff --git a/gcc/tree-vectorizer.h b/gcc/tree-vectorizer.h index 4199b7c..67d4894 100644 --- a/gcc/tree-vectorizer.h +++ b/gcc/tree-vectorizer.h @@ -1706,7 +1706,7 @@ extern tree vect_build_loop_niters (loop_vec_info, bool * = NULL); extern void vect_gen_vector_loop_niters (loop_vec_info, tree, tree *, tree *, bool); extern tree vect_halve_mask_nunits (vec_info *, tree); -extern tree vect_double_mask_nunits (tree); +extern tree vect_double_mask_nunits (vec_info *, tree); extern void vect_record_loop_mask (loop_vec_info, vec_loop_masks *, unsigned int, tree, tree); extern tree vect_get_loop_mask (gimple_stmt_iterator *, vec_loop_masks *,