Match: Fold pow calls to ldexp when possible [PR57492]
[official-gcc.git] / libgomp / testsuite / libgomp.oacc-c-c++-common / kernels-loop-collapse.c
blob997d6c7aad2f2d2128c0e54e4d9a17ec45347226
1 #include <stdlib.h>
3 #define N 100
5 int a[N][N];
7 void __attribute__((noinline, noclone))
8 foo (int m, int n)
10 int i, j;
11 #pragma acc kernels
13 #pragma acc loop collapse(2)
14 for (i = 0; i < m; i++)
15 for (j = 0; j < n; j++)
16 a[i][j] = 1;
20 int
21 main (void)
23 int i, j;
25 for (i = 0; i < N; i++)
26 for (j = 0; j < N; j++)
27 a[i][j] = 0;
29 foo (N, N);
31 for (i = 0; i < N; i++)
32 for (j = 0; j < N; j++)
33 if (a[i][j] != 1)
34 abort ();
36 return 0;