1 /* { dg-do compile } */
2 /* { dg-options "-fopenmp" } */
8 #pragma omp for ordered
9 for (i
= 0; i
< 64; i
++)
14 #pragma omp for ordered
15 for (i
= 0; i
< 64; i
++)
17 #pragma omp ordered threads
20 #pragma omp for ordered
21 for (i
= 0; i
< 64; i
++)
23 #pragma omp ordered threads threads /* { dg-error "too many .threads. clauses" } */
27 for (i
= 0; i
< 64; i
++)
29 #pragma omp ordered simd
33 for (i
= 0; i
< 64; i
++)
35 #pragma omp ordered simd simd /* { dg-error "too many .simd. clauses" } */
38 #pragma omp for simd ordered
39 for (i
= 0; i
< 64; i
++)
41 #pragma omp ordered threads, simd
44 #pragma omp for simd ordered
45 for (i
= 0; i
< 64; i
++)
47 #pragma omp ordered threads, simd, threads, simd /* { dg-error "too many .threads. clauses" } */
48 ; /* { dg-error "too many .simd. clauses" "" { target *-*-* } .-1 } */
50 #pragma omp for simd ordered(1)
51 for (i
= 0; i
< 64; i
++)
53 #pragma omp ordered depend(sink: i - 1) /* { dg-error "clause must be closely nested inside a loop with .ordered. clause" } */
54 #pragma omp ordered depend(source) /* { dg-error "clause must be closely nested inside a loop with .ordered. clause" } */
56 #pragma omp for simd ordered(1)
57 for (i
= 0; i
< 64; i
++)
59 #pragma omp ordered doacross(sink: i - 1) /* { dg-error "clause must be closely nested inside a loop with .ordered. clause" } */
60 #pragma omp ordered doacross(source:omp_cur_iteration) /* { dg-error "clause must be closely nested inside a loop with .ordered. clause" } */
62 #pragma omp parallel for simd ordered(1)
63 for (i
= 0; i
< 64; i
++)
65 #pragma omp ordered depend(sink: i - 1) /* { dg-error "clause must be closely nested inside a loop with .ordered. clause" } */
66 #pragma omp ordered depend(source) /* { dg-error "clause must be closely nested inside a loop with .ordered. clause" } */
68 #pragma omp parallel for simd ordered(1)
69 for (i
= 0; i
< 64; i
++)
71 #pragma omp ordered doacross(sink: i - 1) /* { dg-error "clause must be closely nested inside a loop with .ordered. clause" } */
72 #pragma omp ordered doacross(source:) /* { dg-error "clause must be closely nested inside a loop with .ordered. clause" } */
74 #pragma omp parallel for ordered
75 for (i
= 0; i
< 64; i
++)
77 #pragma omp ordered depend(sink: i - 1)
78 #pragma omp ordered depend(source)
80 #pragma omp parallel for ordered
81 for (i
= 0; i
< 64; i
++)
83 #pragma omp ordered doacross(sink: i - 1)
84 #pragma omp ordered doacross(source:)
86 #pragma omp parallel for
87 for (i
= 0; i
< 64; i
++)
89 #pragma omp ordered depend(sink: i - 1) /* { dg-error "clause must be closely nested inside a loop with .ordered. clause" } */
90 #pragma omp ordered depend(source) /* { dg-error "clause must be closely nested inside a loop with .ordered. clause" } */
92 #pragma omp parallel for
93 for (i
= 0; i
< 64; i
++)
95 #pragma omp ordered doacross(sink: i - 1) /* { dg-error "clause must be closely nested inside a loop with .ordered. clause" } */
96 #pragma omp ordered doacross(source:) /* { dg-error "clause must be closely nested inside a loop with .ordered. clause" } */
110 #pragma omp ordered threads
114 #pragma omp ordered threads, threads /* { dg-error "too many .threads. clauses" } */
123 #pragma omp ordered simd
125 #pragma omp ordered simd, simd /* { dg-error "too many .simd. clauses" } */