[PATCH] D90697: [Flang][OpenMP 4.5] Add semantic check for OpenMP Reduction Clause

Yashaswini Hegde via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Dec 19 03:43:15 PST 2020


yhegde marked an inline comment as not done.
yhegde added inline comments.


================
Comment at: flang/lib/Semantics/check-directive-structure.h:286
+bool DirectiveStructureChecker<D, C, PC,
+    ClauseEnumSize>::CheckPrivateReductionVariable(Symbol *symbol) {
+  if (!GetContext().reductionSymbols.empty()) {
----------------
clementval wrote:
> Maybe I miss the point here but the function itself does not check for any private attribute on the symbol or smith like that. It just check whether the symbol is in the list of `reductionSymbol` which can be populated differently. 
A list item that appears on reduction clause cannot appear in the private clause. This function is initiated from private clause, checks whether the same symbol appeared on the reduction clauses from the same context. 


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