On 18.08.21 13:18, Jakub Jelinek wrote:
gcc/testsuite/ChangeLog:
* gfortran.dg/nothing-1.f90: New test.
* gfortran.dg/nothing-2.f90: New test.
While testing manually with -fopenmp, I did manage to place it for the
testsuite run outside the 'gomp/' subdirectory. – Now fixed → attachment.
For completeness (as already discussed on IRC):
+ !$omp nothing
+ if (.false.) &
+& & !$omp nothing
+ i = i + 1
This indeed does not trigger the sentinel (as also discussed on IRC and as
comment in the test).
While
if (x) &
!$omp nothing
gives an error but it is not obviously invalid. → That's now OpenMP spec bug
#2914.
Tobias
-----------------
Siemens Electronic Design Automation GmbH; Anschrift: Arnulfstraße 201, 80634
München; Gesellschaft mit beschränkter Haftung; Geschäftsführer: Thomas
Heurung, Frank Thürauf; Sitz der Gesellschaft: München; Registergericht
München, HRB 106955
commit f0fca213bc52644ba896da622b35842a6157bd98
Author: Tobias Burnus <[email protected]>
Date: Wed Aug 18 21:47:04 2021 +0200
Fortran: Add OpenMP's nothing directive support (con't)
Fix directory to enable -fopenmp processing.
gcc/testsuite/
PR testsuite/101963
* gfortran.dg/nothing-1.f90: Moved to ...
* gfortran.dg/gomp/nothing-1.f90: ... here.
* gfortran.dg/nothing-2.f90: Moved to ...
* gfortran.dg/gomp/nothing-2.f90: ... here;
avoid $ issue in $OMP in dg-error.
---
gcc/testsuite/gfortran.dg/{ => gomp}/nothing-1.f90 | 0
gcc/testsuite/gfortran.dg/{ => gomp}/nothing-2.f90 | 2 +-
2 files changed, 1 insertion(+), 1 deletion(-)
diff --git a/gcc/testsuite/gfortran.dg/nothing-1.f90 b/gcc/testsuite/gfortran.dg/gomp/nothing-1.f90
similarity index 100%
rename from gcc/testsuite/gfortran.dg/nothing-1.f90
rename to gcc/testsuite/gfortran.dg/gomp/nothing-1.f90
diff --git a/gcc/testsuite/gfortran.dg/nothing-2.f90 b/gcc/testsuite/gfortran.dg/gomp/nothing-2.f90
similarity index 75%
rename from gcc/testsuite/gfortran.dg/nothing-2.f90
rename to gcc/testsuite/gfortran.dg/gomp/nothing-2.f90
index 74a4a5a22b0..554d4ef99ca 100644
--- a/gcc/testsuite/gfortran.dg/nothing-2.f90
+++ b/gcc/testsuite/gfortran.dg/gomp/nothing-2.f90
@@ -3,5 +3,5 @@ pure subroutine foo
end subroutine
subroutine bar
- !$omp nothing foo ! { dg-error "Unexpected junk after $OMP NOTHING statement" }
+ !$omp nothing foo ! { dg-error "Unexpected junk after .OMP NOTHING statement" }
end