Add compile command to each testcase
[gcc-vect-testsuite.git] / vect-72.c
blob67a197519521a8314257a921d2bef183e9dd4072
1 /* { dg-require-effective-target vect_int } */
3 #include <stdarg.h>
4 #include "tree-vect.h"
6 #define N 128
8 /* unaligned load. */
10 char ia[N];
11 char ib[N+1];
13 __attribute__ ((noinline))
14 int main1 ()
16 int i;
18 for (i=0; i < N+1; i++)
20 ib[i] = i;
21 /* Avoid vectorization. */
22 if (i%3 == 0)
23 ib[i] = 5;
26 for (i = 1; i < N+1; i++)
28 ia[i-1] = ib[i];
31 /* check results: */
32 for (i = 1; i <= N; i++)
34 if (ia[i-1] != ib[i])
35 abort ();
38 return 0;
41 int main (void)
43 check_vect ();
45 return main1 ();
48 /* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" { xfail vect_no_align } } } */
49 /* { dg-final { scan-tree-dump-times "Vectorizing an unaligned access" 1 "vect" { xfail vect_no_align } } } */
50 /* { dg-final { scan-tree-dump-times "Alignment of access forced using peeling" 0 "vect" } } */
51 /* { dg-final { cleanup-tree-dump "vect" } } */