[PATCH] D90697: [Flang][OpenMP 4.5] Add semantic check for OpenMP Reduction Clause
Kiran Chandramohan via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Mar 7 16:01:15 PST 2021
kiranchandramohan accepted this revision.
kiranchandramohan added a comment.
LGTM. Thanks for the patience.
@clementval Do you have further concerns about this patch?
================
Comment at: flang/lib/Semantics/check-directive-structure.h:208
+ DirectiveContext *GetEnclosingDirContext() {
+ CHECK(!dirContext_.empty());
----------------
Nit: Praveen added a "GetEnclosingContextWithDir" with D91920.
================
Comment at: flang/lib/Semantics/check-omp-structure.cpp:521
+void OmpStructureChecker::Leave(const parser::OmpEndBlockDirective &x) {
+ if ((GetContext().directive == llvm::omp::Directive::OMPD_end_single) ||
----------------
Nit: Please add a comment on why this pop is required and why it is only for these two directives. If more are to be added later on then please add a todo.
================
Comment at: flang/test/Semantics/omp-reduction07.f90:4
+! 2.15.3.6 Reduction Clause
+program omp_reduction
+
----------------
Nit: convert one of the tests in this file to work with max/min/....
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D90697/new/
https://reviews.llvm.org/D90697
More information about the llvm-commits
mailing list