This patch implements the following check for THREADPRIVATE construct:
A variable that is part of another variable (as an array, structure element or type parameter inquiry) cannot appear in a threadprivate directive.
Paths
| Differential D109685
[flang][OpenMP] Add semantic check for threadprivate directive ClosedPublic Authored by peixin on Sep 13 2021, 6:22 AM.
Details Summary This patch implements the following check for THREADPRIVATE construct: A variable that is part of another variable (as an array, structure element or type parameter inquiry) cannot appear in a threadprivate directive.
Diff Detail
Event TimelineThis revision is now accepted and ready to land.Sep 13 2021, 7:57 AM Comment Actions
I am studying on them and they will come later. I prefer to separate semantic checks with different styles in multiple PRs to make review work easier, but I will keep similar semantic checks in one PR so that the code will not revised again and again.
Closed by commit rG268521218434: [flang][OpenMP] Add semantic check for threadprivate directive (authored by peixin). · Explain WhySep 14 2021, 9:26 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 372498 flang/lib/Semantics/check-omp-structure.h
flang/lib/Semantics/check-omp-structure.cpp
flang/test/Semantics/omp-allocate03.f90
flang/test/Semantics/omp-allocate07.f90
flang/test/Semantics/omp-parallel-private01.f90
flang/test/Semantics/omp-parallel-private02.f90
flang/test/Semantics/omp-parallel-private03.f90
flang/test/Semantics/omp-parallel-private04.f90
flang/test/Semantics/omp-parallel-shared01.f90
flang/test/Semantics/omp-parallel-shared02.f90
flang/test/Semantics/omp-parallel-shared03.f90
flang/test/Semantics/omp-parallel-shared04.f90
flang/test/Semantics/omp-threadprivate01.f90
|
Nit: an THREADPRIVATE -> a THREADPRIVATE