Daily bump.
[official-gcc.git] / libgomp / testsuite / libgomp.c / parloops-exit-first-loop-alt-4.c
blobac420fa3662335d1cfa80061c91dbc0c542bab62
1 /* { dg-do run } */
2 /* { dg-additional-options "-ftree-parallelize-loops=2" } */
4 /* Constant bound, reduction. */
6 #include <stdlib.h>
8 #define N 4000
10 unsigned int *a;
12 unsigned int
13 f (void)
15 int i;
16 unsigned int sum = 1;
18 for (i = 0; i < N; ++i)
19 sum += a[i];
21 return sum;
24 int
25 main (void)
27 unsigned int res;
28 unsigned int array[N];
29 int i;
30 for (i = 0; i < N; ++i)
31 array[i] = i % 7;
32 a = &array[0];
33 res = f ();
34 if (res != 11995)
35 abort ();
36 return 0;