[Openmp-commits] [PATCH] D93135: [libomptarget][devicertl] Port amdgcn devicertl to openmp

Jon Chesterfield via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Fri Dec 11 11:25:49 PST 2020


JonChesterfield created this revision.
JonChesterfield added reviewers: jdoerfert, grokos, ABataev, ye-luo, ronlieb, tianshilei1992.
Herald added subscribers: jfb, guansong, yaxunl, mgorny, jvesely.
JonChesterfield requested review of this revision.
Herald added subscribers: openmp-commits, sstefan1.
Herald added a project: OpenMP.

[libomptarget][devicertl] Port amdgcn devicertl to openmp

Uses macros to abstract over cuda and openmp syntax for shared variables.
Cuda ignores unknown #pragma, so that macro plus declare target is mostly
sufficient. Nvptx still compiles as cuda for now.

This change is localised to the runtime. It can be improved later by changing
the compiler, e.g. to implicitly wrap a CU with the pragma target, or to bring
the intrinsics into scope implicitly.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D93135

Files:
  openmp/libomptarget/deviceRTLs/amdgcn/CMakeLists.txt
  openmp/libomptarget/deviceRTLs/amdgcn/src/amdgcn_intrinsics.h
  openmp/libomptarget/deviceRTLs/amdgcn/src/amdgcn_locks.hip
  openmp/libomptarget/deviceRTLs/amdgcn/src/amdgcn_smid.hip
  openmp/libomptarget/deviceRTLs/amdgcn/src/target_impl.h
  openmp/libomptarget/deviceRTLs/amdgcn/src/target_impl.hip
  openmp/libomptarget/deviceRTLs/common/omptarget.h
  openmp/libomptarget/deviceRTLs/common/src/cancel.cu
  openmp/libomptarget/deviceRTLs/common/src/critical.cu
  openmp/libomptarget/deviceRTLs/common/src/data_sharing.cu
  openmp/libomptarget/deviceRTLs/common/src/libcall.cu
  openmp/libomptarget/deviceRTLs/common/src/loop.cu
  openmp/libomptarget/deviceRTLs/common/src/omp_data.cu
  openmp/libomptarget/deviceRTLs/common/src/omptarget.cu
  openmp/libomptarget/deviceRTLs/common/src/parallel.cu
  openmp/libomptarget/deviceRTLs/common/src/reduction.cu
  openmp/libomptarget/deviceRTLs/common/src/support.cu
  openmp/libomptarget/deviceRTLs/common/src/sync.cu
  openmp/libomptarget/deviceRTLs/common/src/task.cu
  openmp/libomptarget/deviceRTLs/nvptx/src/target_impl.h

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D93135.311286.patch
Type: text/x-patch
Size: 21722 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/openmp-commits/attachments/20201211/cde17e84/attachment-0001.bin>


More information about the Openmp-commits mailing list