gfortran.dg/gomp/metadirective-3.f90: xfail on offload_nvptx

Currently, 'target' with a nested metadirective creating a 'teams' will
fail with a bogus error ("‘target’ construct with nested ‘teams’ construct
contains directives outside of the ‘teams’ construct").
That's tracked at PR118694 - and, hence, expected.

However, the testcase metadirective-3.f90 triggers this when compiling for
'target offload_nvptx' (otherwise, the code is optimized away). Use xfail to
silence the error as it is known and there is a tracking PR.

gcc/testsuite/ChangeLog:

	* gfortran.dg/gomp/metadirective-3.f90: Add xfail when
	compiling for offload_nvptx.
This commit is contained in:
Tobias Burnus 2025-02-18 15:48:39 +01:00
parent c5752c1f01
commit 8d922a8039

View file

@ -22,4 +22,7 @@ end module
! that alternative and not produce a metadirective at all. Otherwise this
! won't be resolved until late.
! { dg-final { scan-tree-dump-not "#pragma omp metadirective" "gimple" { target { ! offload_nvptx } } } }
! { dg-final { scan-tree-dump "#pragma omp metadirective" "gimple" { target { offload_nvptx } } } }
! The following two are xfail because the bogus error triggers and thus prevents the dump, cf. PR118694
! { dg-final { scan-tree-dump "#pragma omp metadirective" "gimple" { target { offload_nvptx } xfail { offload_nvptx } } } }
! { dg-bogus "'target' construct with nested 'teams' construct contains directives outside of the 'teams' construct" "PR118694" { xfail offload_nvptx } 10 }