diff --git a/gcc/testsuite/gfortran.dg/gomp/combined-if.f90 b/gcc/testsuite/gfortran.dg/gomp/combined-if.f90 index bf4a9a85d34..0bb6c28b286 100644 --- a/gcc/testsuite/gfortran.dg/gomp/combined-if.f90 +++ b/gcc/testsuite/gfortran.dg/gomp/combined-if.f90 @@ -104,5 +104,6 @@ contains end module ! { dg-final { scan-tree-dump-times "(?n)#pragma omp target.* if\\(" 9 "omplower" } } -! { dg-final { scan-tree-dump-times "(?n)#pragma omp simd.* if\\(" 7 "omplower" } } +! { dg-final { scan-tree-dump-times "(?n)#pragma omp simd.* if\\(" 4 "omplower" { target { ! offload_nvptx } } } } +! { dg-final { scan-tree-dump-times "(?n)#pragma omp simd.* if\\(" 7 "omplower" { target { offload_nvptx } } } } ! { dg-final { scan-tree-dump-times "(?n)#pragma omp parallel.* if\\(" 6 "omplower" } } diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp index cf0cfa11eb9..2279361175d 100644 --- a/gcc/testsuite/lib/target-supports.exp +++ b/gcc/testsuite/lib/target-supports.exp @@ -9820,6 +9820,14 @@ proc check_effective_target_vect_max_reduc { } { return 0 } +# Return 1 if the compiler has been configured with nvptx offloading. + +proc check_effective_target_offload_nvptx { } { + return [check_no_compiler_messages offload_nvptx assembly { + int main () {return 0;} + } "-foffload=nvptx-none" ] +} + # Return 1 if the compiler has been configured with hsa offloading. proc check_effective_target_offload_hsa { } { @@ -9828,7 +9836,7 @@ proc check_effective_target_offload_hsa { } { } "-foffload=hsa" ] } -# Return 1 if the compiler has been configured with hsa offloading. +# Return 1 if the compiler has been configured with gcn offloading. proc check_effective_target_offload_gcn { } { return [check_no_compiler_messages offload_gcn assembly {