Fix warning with -Wsign-compare -Wsystem-headers
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / ldist-14.c
blobfa4d1a828798790d4935096ba6ce4d0b82f1847f
1 /* { dg-do compile } */
2 /* { dg-options "-O2 -fno-strict-aliasing -ftree-loop-distribution -fdump-tree-ldist-details" } */
4 struct desc {
5 int i;
6 void * __restrict__ data;
7 int j;
8 } a, b;
10 float foo (int n)
12 int i;
13 float * __restrict__ x, * __restrict__ y, tmp = 0.0;
14 x = (float * __restrict__)a.data;
15 y = (float * __restrict__)b.data;
16 for (i = 0; i < n; ++i)
18 x[i] = 0.0;
19 tmp += y[i];
21 return tmp;
24 /* Distributing the loop doesn't expose more parallelism. */
25 /* { dg-final { scan-tree-dump-not "Loop 1 distributed: split to 2 loops" "ldist" } } */