1 // RUN: %libomp-compile-and-run
2 // RUN: env OMP_NUM_THREADS=1 %libomp-run
7 volatile int attempt
= 0;
9 for (i
= 0; i
< 10; ++i
) {
11 #pragma omp parallel for
12 for (int i
= 0; i
< 2; i
++) {
15 if (a
[0] != 2 || a
[1] != 2)
18 #pragma omp teams distribute parallel for if (attempt >= 2)
19 for (int i
= 0; i
< 2; i
++) {
22 if (a
[0] != 1 || a
[1] != 1)