PR libfortran/64770 Segfault when trying to open existing file with status="new".
[official-gcc.git] / gcc / testsuite / gcc.dg / gomp / pr34610.c
blob85db164b529a8b5b7621f50689aa65c33fb7533d
1 /* PR gcov-profile/34610 */
2 /* { dg-do compile } */
3 /* { dg-options "-O2 -fprofile-arcs -fopenmp" } */
5 extern void bar (int);
6 extern void baz (int) __attribute__((noreturn));
8 void
9 foo (int k)
11 int i;
12 #pragma omp for schedule(dynamic)
13 for (i = 0; i < 10; ++i)
14 bar (i);
15 #pragma omp parallel for schedule(static)
16 for (i = 0; i < 10; ++i)
17 bar (i);
18 #pragma omp parallel for schedule(static, 4)
19 for (i = 0; i < 10; ++i)
20 bar (i);
21 if (k)
22 #pragma omp for schedule(dynamic)
23 for (i = 0; i < 10; ++i)
24 baz (i);
25 #pragma omp parallel
26 for (i = 0; i < 10; ++i)
27 bar (i);