1 /* { dg-do compile } */
2 /* { dg-additional-options "-fdump-tree-original" } */
9 #pragma omp parallel for
10 for (int i
= 0; i
< 10; ++i
)
12 #pragma omp critical hint(omp_sync_hint_none)
14 #pragma omp critical (HASH1) hint(omp_sync_hint_none)
16 #pragma omp critical (HASH2) hint(omp_sync_hint_uncontended)
18 #pragma omp critical (HASH3) hint(omp_sync_hint_contended)
20 #pragma omp critical (HASH4) hint(omp_sync_hint_speculative)
22 #pragma omp critical (HASH5) hint(omp_sync_hint_nonspeculative)
24 #pragma omp critical (HASH6) hint(omp_sync_hint_contended + omp_sync_hint_speculative)
26 #pragma omp critical (HASH7) hint(omp_sync_hint_contended | omp_sync_hint_speculative)
31 /* { dg-final { scan-tree-dump-times "omp critical \\(HASH1\\) hint\\(0\\)" 1 "original" } } */
32 /* { dg-final { scan-tree-dump-times "omp critical \\(HASH2\\) hint\\(1\\)" 1 "original" } } */
33 /* { dg-final { scan-tree-dump-times "omp critical \\(HASH3\\) hint\\(2\\)" 1 "original" } } */
34 /* { dg-final { scan-tree-dump-times "omp critical \\(HASH4\\) hint\\(8\\)" 1 "original" } } */
35 /* { dg-final { scan-tree-dump-times "omp critical \\(HASH5\\) hint\\(4\\)" 1 "original" } } */
36 /* { dg-final { scan-tree-dump-times "omp critical \\(HASH6\\) hint\\(10\\)" 1 "original" } } */
37 /* { dg-final { scan-tree-dump-times "omp critical \\(HASH7\\) hint\\(10\\)" 1 "original" } } */