aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
diff options
context:
space:
mode:
authorJoseph Huber <jhuber6@vols.utk.edu>2023-08-14 16:19:29 -0500
committerJoseph Huber <jhuber6@vols.utk.edu>2023-08-25 18:51:56 -0500
commitaa78e94b0bc66375de7f2383b4e39c07cd482104 (patch)
tree43aaae275f49e41092e05f2ae863f82f82d7ff76 /llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
parent79cf24e2118f5070d93da51b6d8c7c8598ae2671 (diff)
downloadllvm-aa78e94b0bc66375de7f2383b4e39c07cd482104.zip
llvm-aa78e94b0bc66375de7f2383b4e39c07cd482104.tar.gz
llvm-aa78e94b0bc66375de7f2383b4e39c07cd482104.tar.bz2
[Libomptarget] Support mapping indirect host calls to device functions
The changes in D157738 allowed for us to emit stub globals on the device in the offloading entry section. These globals contain the addresses of device functions and allow us to map host functions to their corresponding device equivalent. This patch provides the initial support required to build a table on the device to lookup the associated value. This is done by finding these entries and creating a global table on the device that can be searched with a simple binary search. This requires an allocation, which supposedly should be automatically freed at plugin shutdown. This includes a basic test which looks up device pointers via a host pointer using the added function. This will need to be built upon to provide full support for these calls in the runtime. To support reverse offloading it would also be useful to provide a reverse table that allows us to get host functions from device stubs. Depends on D157738 Reviewed By: jdoerfert Differential Revision: https://reviews.llvm.org/D157918
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp')
0 files changed, 0 insertions, 0 deletions