[all-commits] [llvm/llvm-project] e909a2: [Flang][OpenMP][Lower] Program level implicit SAVE...

agozillon via All-commits all-commits at lists.llvm.org
Thu Jul 13 10:17:42 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: e909a2c1ca4d1f37a28293e6607136888ed889db
      https://github.com/llvm/llvm-project/commit/e909a2c1ca4d1f37a28293e6607136888ed889db
  Author: Andrew Gozillon <Andrew.Gozillon at amd.com>
  Date:   2023-07-13 (Thu, 13 Jul 2023)

  Changed paths:
    M flang/include/flang/Lower/OpenMP.h
    M flang/lib/Lower/Bridge.cpp
    M flang/lib/Lower/OpenMP.cpp
    A flang/test/Lower/OpenMP/omp-declare-target-program-var.f90

  Log Message:
  -----------
  [Flang][OpenMP][Lower] Program level implicit SAVE variable handling for declare target

This is an attempt at mimicing the method in which
threadprivate handles the following type of variables:

program main
  integer :: i
  !$omp declare target to(i)
end

Which essentially generates a GlobalOp for the variable (which
would normally only be an alloca) when it's instantiated. The
main difference is there is no operation generated within the
function, instead the declare target attribute is appended
later within handleDeclareTarget.

Reviewers: kiranchandramohan

Differential Revision: https://reviews.llvm.org/D152037




More information about the All-commits mailing list