1 /* { dg-require-effective-target vect_int } */
2 
3 #include <stdarg.h>
4 #include "tree-vect.h"
5 
6 #define N 16
7 
8 char cb[N] = {2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17};
9 char cc[N] = {1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16};
10 
11 __attribute__ ((noinline)) int
main1(void)12 main1 (void)
13 {
14   int i;
15   int diff = 0;
16 
17   /* Cross-iteration cycle.  */
18   diff = 0;
19   for (i = 0; i < N; i++) {
20     diff += (cb[i] - cc[i]);
21   }
22 
23   /* Check results.  */
24   if (diff != 16)
25     abort();
26 
27   return 0;
28 }
29 
main(void)30 int main (void)
31 {
32   check_vect ();
33   return main1 ();
34 }
35 
36 /* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" { target vect_unpack } } } */
37 
38 
39