[all-commits] [llvm/llvm-project] 216ba6: [flang][OpenMP] Privatize vars referenced in state...

Leandro Lupori via All-commits all-commits at lists.llvm.org
Mon Aug 26 04:39:54 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 216ba6bc6c0d1b65543771420897f4d09beec704
      https://github.com/llvm/llvm-project/commit/216ba6bc6c0d1b65543771420897f4d09beec704
  Author: Leandro Lupori <leandro.lupori at linaro.org>
  Date:   2024-08-26 (Mon, 26 Aug 2024)

  Changed paths:
    M flang/include/flang/Semantics/symbol.h
    M flang/lib/Lower/OpenMP/DataSharingProcessor.cpp
    M flang/lib/Semantics/resolve-directives.cpp
    A flang/test/Lower/OpenMP/statement-function.f90

  Log Message:
  -----------
  [flang][OpenMP] Privatize vars referenced in statement functions (#103390)

Variables referenced in the body of statement functions need to be
handled as if they are explicitly referenced. Otherwise, they are
skipped during implicit privatization, because statement functions
are represented as procedures in the parse tree.

To avoid missing symbols referenced only in statement functions
during implicit privatization, new symbols, associated with them,
are created and inserted into the context of the directive that
privatizes them. They are later collected and processed in
lowering. To avoid confusing these new symbols with regular ones,
they are tagged with the new OmpFromStmtFunction flag.

Fixes https://github.com/llvm/llvm-project/issues/74273



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list