2015-09-24 Vladimir Makarov <vmakarov@redhat.com>
[official-gcc.git] / gcc / testsuite / gcc.dg / autopar / pr39500-1.c
blob33b93b37aba7678335fd6dda54674638f1c7d9c2
1 /* pr39500: autopar fails to parallel */
2 /* origin: nemokingdom@gmail.com(LiFeng) */
3 /* { dg-do compile } */
4 /* { dg-options "-O2 -ftree-parallelize-loops=4 -fdump-tree-parloops-details" } */
6 void abort (void);
8 int main (void)
10 int i;
11 int x[100000];
13 for (i = 0; i < 10000; i++)
14 x[i] = x[i+10000];
16 for (i = 0; i < 10000; i++)
18 if (x[i] != x[i+10000])
19 abort ();
22 return 0;
25 /* Check that the first loop in parloop got parallelized. */
27 /* { dg-final { scan-tree-dump-times "SUCCESS: may be parallelized" 1 "parloops" } } */