[all-commits] [llvm/llvm-project] 096ee4: [Flang][OpenMP] Implement "promotion" of use_devic...

agozillon via All-commits all-commits at lists.llvm.org
Wed Mar 13 08:18:44 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 096ee4e16fd62cd578d20ec4e8ad4756f4e369ee
      https://github.com/llvm/llvm-project/commit/096ee4e16fd62cd578d20ec4e8ad4756f4e369ee
  Author: agozillon <Andrew.Gozillon at amd.com>
  Date:   2024-03-13 (Wed, 13 Mar 2024)

  Changed paths:
    M flang/lib/Lower/OpenMP/OpenMP.cpp
    M flang/lib/Semantics/check-omp-structure.cpp
    A flang/test/Lower/OpenMP/use-device-ptr-to-use-device-addr.f90
    M flang/test/Semantics/OpenMP/use_device_ptr1.f90

  Log Message:
  -----------
  [Flang][OpenMP] Implement "promotion" of use_device_ptr non-cptr arguments to use_device_addr (#82834)

This effectively implements some now deprecated OpenMP functionality
that some applications (most notably at the moment GenASiS)
unfortunately depend on (deprecated in specification version 5.2):

"If a list item in a use_device_ptr clause is not of type C_PTR, the
behavior is as if the list item appeared in a use_device_addr clause.
Support for such list items in a use_device_ptr clause is deprecated."

This PR downgrades the hard-error to a deprecated warning and "promotes"
the above cases by simply moving the offending operands from the
use_device_ptr value list to the back of the use_device_addr list (and
moves the related symbols, locs and types that form the BlockArgs
correspondingly) and then the generation of the target data construct
proceeds as normal.



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