* testsuite/libgomp.fortran/vla7.f90: Add -w to options.
[official-gcc.git] / gcc / testsuite / gcc.dg / vect / vect-ifcvt-9.c
blob75941d7f10f53828a852351049ec84fca13a1185
1 /* { dg-require-effective-target vect_condition } */
3 #include <stdarg.h>
4 #include <signal.h>
5 #include "tree-vect.h"
7 #define N 16
8 #define MAX 42
10 extern void abort(void);
12 int A[N] = {36,39,42,45,43,32,21,12,23,34,45,56,67,78,89,11};
13 int B[N] = {0,0,42,42,42,0,0,0,0,0,42,42,42,42,42,0};
14 void foo () __attribute__((always_inline));
15 void foo ()
17 int i, j;
19 for (i = 0; i < 16; i++)
20 A[i] = ( A[i] >= MAX ? MAX : 0);
23 int main ()
26 int i, j;
27 check_vect ();
28 foo ();
29 /* check results: */
30 for (i = 0; i < N; i++)
31 if (A[i] != B[i])
32 abort ();
34 return 0;
37 /* { dg-final { scan-tree-dump-times "vectorized 1 loops" 2 "vect" } } */
38 /* { dg-final { cleanup-tree-dump "vect" } } */