[all-commits] [llvm/llvm-project] a5f407: [libomptarget][amdgpu] Macro for accessing GPU var...

Jon Chesterfield via All-commits all-commits at lists.llvm.org
Thu Aug 26 09:28:37 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a5f4074d85bd7633c6d2cd3abaa7ac169430b32c
      https://github.com/llvm/llvm-project/commit/a5f4074d85bd7633c6d2cd3abaa7ac169430b32c
  Author: Jon Chesterfield <jonathanchesterfield at gmail.com>
  Date:   2021-08-26 (Thu, 26 Aug 2021)

  Changed paths:
    M openmp/libomptarget/deviceRTLs/amdgcn/src/target_impl.h
    M openmp/libomptarget/deviceRTLs/common/src/omp_data.cu
    M openmp/libomptarget/deviceRTLs/nvptx/src/target_impl.h

  Log Message:
  -----------
  [libomptarget][amdgpu] Macro for accessing GPU variables from plugin

Lets the amdgpu plugin write to omptarget_device_environment
to enable debugging. Intend to use in the near future to record the
wavesize that a given deviceRTL was compiled with for running on hardware
that supports 32 or 64.

Patch sets all the attributes that are useful. Notably .data means the variable
is set by writing to host memory before copying to the GPU instead of launching
a kernel to update the image. Can simplify the plugin slightly to drop the
code for patching after load if this is used consistently.

NFC on nvptx, cuda plugin seems to work fine without any annotations.

Reviewed By: jdoerfert

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




More information about the All-commits mailing list