diff mbox

pr43430-1.c requires vect_condition target

Message ID OFFD3A5243.8535E8B8-ONC225778E.0022F305-C225778E.00239B5B@il.ibm.com
State New
Headers show

Commit Message

Ira Rosen Aug. 29, 2010, 6:28 a.m. UTC
gcc-patches-owner@gcc.gnu.org wrote on 27/08/2010 03:13:06 PM:

>
> Hi,
> I noticed pr43430-1.c contains conditional code inside the loop.
> To vectorize the loop, vect_condition target is required. OK for
> trunk?
>

It's fine with me, but it maybe better to check for vect_condition when
checking if the loop got vectorized:

 /* { dg-final { cleanup-tree-dump "vect" } } */


Thanks,
Ira

> Cheers,
> Bingfeng
>
> 2010-08-27  Bingfeng Mei  <bmei@broadcom.com>
>
>    * gcc.dg/vect/pr43430-1.c: Requires vect_condition target.
>
> Index: pr43430-1.c
> ===================================================================
> --- pr43430-1.c (revision 163583)
> +++ pr43430-1.c (working copy)
> @@ -1,4 +1,5 @@
>  /* { dg-require-effective-target vect_int } */
> +/* { dg-require-effective-target vect_condition } */
>
>  #include <stdarg.h>
>  #include "tree-vect.h"
>
diff mbox

Patch

Index: pr43430-1.c
===================================================================
--- pr43430-1.c (revision 163538)
+++ pr43430-1.c (working copy)
@@ -35,5 +35,5 @@ 
   return foo (data_ch1, data_ch2, 1);
 }

-/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } } */
+/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1
"vect" { target vect_condition } } } */