Commit dfc55d30 by Richard Biener Committed by Richard Biener

tree-vect-slp.c (vect_build_slp_tree_1): For BB vectorization do not allow unrolling.

2015-05-12  Richard Biener  <rguenther@suse.de>

	* tree-vect-slp.c (vect_build_slp_tree_1): For BB vectorization
	do not allow unrolling.

	* gcc.dg/vect/bb-slp-35.c: New testcase.

From-SVN: r223033
parent 9b7df66f
2015-05-12 Richard Biener <rguenther@suse.de>
* tree-vect-slp.c (vect_build_slp_tree_1): For BB vectorization
do not allow unrolling.
2015-05-11 Richard Henderson <rth@redhat.com> 2015-05-11 Richard Henderson <rth@redhat.com>
* config/i386/i386-modes.def (CCP): New. * config/i386/i386-modes.def (CCP): New.
......
2015-05-12 Richard Biener <rguenther@suse.de>
* gcc.dg/vect/bb-slp-35.c: New testcase.
2015-05-11 Mikael Morin <mikael@gcc.gnu.org> 2015-05-11 Mikael Morin <mikael@gcc.gnu.org>
PR fortran/66100 PR fortran/66100
......
/* { dg-do compile } */
/* { dg-require-effective-target vect_int } */
void foo (int * __restrict__ p, short * __restrict__ q)
{
p[0] = q[0] + 1;
p[1] = q[1] + 1;
p[2] = q[2] + 1;
p[3] = q[3] + 1;
}
/* { dg-final { scan-tree-dump "basic block vectorized" "slp2" } } */
/* { dg-final { cleanup-tree-dump "slp2" } } */
...@@ -568,6 +568,19 @@ vect_build_slp_tree_1 (loop_vec_info loop_vinfo, bb_vec_info bb_vinfo, ...@@ -568,6 +568,19 @@ vect_build_slp_tree_1 (loop_vec_info loop_vinfo, bb_vec_info bb_vinfo,
return false; return false;
} }
/* If populating the vector type requires unrolling then fail
before adjusting *max_nunits for basic-block vectorization. */
if (bb_vinfo
&& TYPE_VECTOR_SUBPARTS (vectype) > group_size)
{
dump_printf_loc (MSG_MISSED_OPTIMIZATION, vect_location,
"Build SLP failed: unrolling required "
"in basic block SLP\n");
/* Fatal mismatch. */
matches[0] = false;
return false;
}
/* In case of multiple types we need to detect the smallest type. */ /* In case of multiple types we need to detect the smallest type. */
if (*max_nunits < TYPE_VECTOR_SUBPARTS (vectype)) if (*max_nunits < TYPE_VECTOR_SUBPARTS (vectype))
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment