1 /* { dg-do compile } */
2 /* { dg-additional-options "-foffload=disable -fdump-tree-gimple" } */
3 /* { dg-additional-options "-mavx512bw -mavx512vl" { target { i?86-*-* x86_64-*-* } } } */
5 #pragma omp requires atomic_default_mem_order(seq_cst)
9 #pragma omp declare variant (f01) match (device={isa("avx512f","avx512vl")}) /* 16 */
10 #pragma omp declare variant (f02) match (implementation={vendor(score(15):gnu)})
11 #pragma omp declare variant (f03) match (user={condition(score(11):1)})
16 #pragma omp declare variant (f05) match (device={isa(avx512f,avx512vl)}) /* 16 */
17 #pragma omp declare variant (f06) match (implementation={vendor(score(15):gnu)})
18 #pragma omp declare variant (f07) match (user={condition(score(17):1)})
24 #pragma omp declare variant (f09) match (device={arch(x86_64)},user={condition(score(65):1)}) /* 64+65 */
25 #pragma omp declare variant (f10) match (implementation={vendor(score(127):"gnu")})
26 #pragma omp declare variant (f11) match (device={isa(ssse3)}) /* 128 */
27 #pragma omp declare variant (f12) match (implementation={atomic_default_mem_order(score(126):seq_cst)})
32 #pragma omp declare variant (f14) match (construct={teams,parallel,for}) /* 16+8+4 */
33 #pragma omp declare variant (f15) match (construct={parallel},user={condition(score(19):1)}) /* 8+19 */
34 #pragma omp declare variant (f16) match (implementation={atomic_default_mem_order(score(27):seq_cst)})
39 #pragma omp declare variant (f18) match (construct={teams,parallel,for}) /* 16+8+4 */
40 #pragma omp declare variant (f19) match (construct={for},user={condition(score(25):1)}) /* 4+25 */
41 #pragma omp declare variant (f20) match (implementation={atomic_default_mem_order(score(28):seq_cst)})
46 #pragma omp declare variant (f22) match (construct={parallel,for}) /* 2+1 */
47 #pragma omp declare variant (f23) match (construct={for}) /* 0 */
48 #pragma omp declare variant (f24) match (implementation={atomic_default_mem_order(score(2):seq_cst)})
53 #pragma omp declare variant (f26) match (construct={parallel,for}) /* 2+1 */
54 #pragma omp declare variant (f27) match (construct={for},user={condition(1)}) /* 4 */
55 #pragma omp declare variant (f28) match (implementation={atomic_default_mem_order(score(3):seq_cst)})
62 #pragma omp parallel for /* 2 constructs in OpenMP context, isa has score 2^4. */
63 for (i
= 0; i
< 1; i
++)
64 f04 (); /* { dg-final { scan-tree-dump-times "f01 \\\(\\\);" 1 "gimple" { target i?86-*-* x86_64-*-* } } } */
65 /* { dg-final { scan-tree-dump-times "f02 \\\(\\\);" 1 "gimple" { target { ! { i?86-*-* x86_64-*-* } } } } } */
66 #pragma omp target teams /* 2 constructs in OpenMP context, isa has score 2^4. */
67 f08 (); /* { dg-final { scan-tree-dump-times "f07 \\\(\\\);" 1 "gimple" } } */
69 #pragma omp parallel for
70 for (i
= 0; i
< 1; i
++)
71 #pragma omp parallel for /* 5 constructs in OpenMP context, arch is 2^6, isa 2^7. */
72 for (j
= 0; j
< 1; j
++)
74 f13 (); /* { dg-final { scan-tree-dump-times "f09 \\\(\\\);" 1 "gimple" { target { { i?86-*-* x86_64-*-* } && lp64 } } } } */
75 /* { dg-final { scan-tree-dump-times "f11 \\\(\\\);" 1 "gimple" { target { { i?86-*-* x86_64-*-* } && { ! lp64 } } } } } */
76 /* { dg-final { scan-tree-dump-times "f10 \\\(\\\);" 1 "gimple" { target { ! { i?86-*-* x86_64-*-* } } } } } */
77 f17 (); /* { dg-final { scan-tree-dump-times "f14 \\\(\\\);" 1 "gimple" } } */
78 f21 (); /* { dg-final { scan-tree-dump-times "f19 \\\(\\\);" 1 "gimple" } } */
81 for (i
= 0; i
< 1; i
++)
82 #pragma omp parallel for
83 for (j
= 0; j
< 1; j
++)
85 f25 (); /* { dg-final { scan-tree-dump-times "f22 \\\(\\\);" 1 "gimple" } } */
86 f29 (); /* { dg-final { scan-tree-dump-times "f27 \\\(\\\);" 1 "gimple" } } */