diff options
author | Tobias Burnus <tobias@codesourcery.com> | 2022-09-05 18:05:24 +0200 |
---|---|---|
committer | Tobias Burnus <tobias@codesourcery.com> | 2022-09-05 18:06:06 +0200 |
commit | 938cda536019cd6a1bc0dd2346381185b420bbf8 (patch) | |
tree | 78f0c5604425d3e2db0576f1a35066187750ea2f /libgomp | |
parent | b4d8a56a4c62ba8bca55469ae2b841fb4e1334a4 (diff) | |
download | gcc-938cda536019cd6a1bc0dd2346381185b420bbf8.zip gcc-938cda536019cd6a1bc0dd2346381185b420bbf8.tar.gz gcc-938cda536019cd6a1bc0dd2346381185b420bbf8.tar.bz2 |
Fortran/openmp: Partial OpenMP 5.2 doacross and omp_cur_iteration support
Add the Fortran support to the ME/C/C++ commit
r13-2388-ga651e6d59188da8992f8bfae2df1cb4e6316f9e6
gcc/fortran/ChangeLog:
* dump-parse-tree.cc (show_omp_namelist, show_omp_clauses): Handle
omp_cur_iteration and distinguish doacross/depend.
* gfortran.h (enum gfc_omp_depend_doacross_op): Renamed from
gfc_omp_depend_op.
(enum gfc_omp_depend_doacross_op): Add OMP_DOACROSS_SINK_FIRST,
Rename OMP_DEPEND_SINK to OMP_DOACROSS_SINK.
(gfc_omp_namelist) Handle renaming, rename depend_op to
depend_doacross_op.
(struct gfc_omp_clauses): Add doacross_source.
* openmp.cc (gfc_match_omp_depend_sink): Renamed to ...
(gfc_match_omp_doacross_sink): ... this; handle omp_all_memory.
(enum omp_mask2): Add OMP_CLAUSE_DOACROSS.
(gfc_match_omp_clauses): Handle 'doacross' and syntax changes to
depend.
(gfc_match_omp_depobj): Simplify as sink/source are now impossible.
(gfc_match_omp_ordered_depend): Request OMP_CLAUSE_DOACROSS.
(resolve_omp_clauses): Update sink/source checks.
(gfc_resolve_omp_directive): Resolve EXEC_OMP_ORDERED clauses.
* parse.cc (decode_omp_directive): Handle 'ordered doacross'.
* trans-openmp.cc (gfc_trans_omp_clauses): Handle doacross.
(gfc_trans_omp_do): Fix OMP_FOR_ORIG_DECLS handling if 'ordered'
clause is present.
(gfc_trans_omp_depobj): Update for member name change.
libgomp/ChangeLog:
* libgomp.texi (OpenMP 5.2): Update doacross/omp_cur_iteration status.
gcc/testsuite/ChangeLog:
* gfortran.dg/gomp/all-memory-1.f90: Update dg-error.
* gfortran.dg/gomp/depend-iterator-2.f90: Likewise.
* gfortran.dg/gomp/depobj-2.f90: Likewise.
* gfortran.dg/gomp/doacross-5.f90: New test.
* gfortran.dg/gomp/doacross-6.f90: New test.
Diffstat (limited to 'libgomp')
-rw-r--r-- | libgomp/libgomp.texi | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libgomp/libgomp.texi b/libgomp/libgomp.texi index 0f2998c..3df979e 100644 --- a/libgomp/libgomp.texi +++ b/libgomp/libgomp.texi @@ -394,10 +394,11 @@ to address of matching mapped list item per 5.1, Sect. 2.21.7.2 @tab N @tab @item Default map-type for @code{map} clause in @code{target enter/exit data} @tab Y @tab @item New @code{doacross} clause as alias for @code{depend} with - @code{source}/@code{sink} modifier @tab N @tab + @code{source}/@code{sink} modifier @tab Y @tab @item Deprecation of @code{depend} with @code{source}/@code{sink} modifier @tab N @tab -@item @code{omp_cur_iteration} keyword @tab N @tab +@item @code{omp_cur_iteration} keyword @tab P + @tab @code{sink: omp_cur_iteration - 1} unsupported @end multitable @unnumberedsubsec Other new OpenMP 5.2 features |