[libc-commits] [PATCH] D139839: [libc] Add a loader utility for AMDHSA architectures for testing

Joseph Huber via Phabricator via libc-commits libc-commits at lists.llvm.org
Wed Feb 8 07:27:16 PST 2023


jhuber6 updated this revision to Diff 495846.
jhuber6 added a comment.

Updating to just present the loader interface. I attempted to rewrite this with
the OpenMP interface, but found it more difficult than just using HSA directly.

I think this direction is good, as this loader will present itself as a very
simplified interface to test and use the future RPC API.

I've also found some prior work in this direction by Mentor Graphics that
presents a `gcn-run` executable, which is pretty much exactly that this patch
provides.

Right now my plans for this are as follows:

1. Write a single integration test that uses this loader interface
2. Write the NVPTX interface
3. Implement `write_to_stderr` and `exit_early` (Basically a circular buffer the loader will copy back)
4. Find a way to run the regular unit test suite as an integration test.
5. Write a full RPC server that essentially acts as the GPU's "syscall"

After this point, adding new features will simply be implementing it in code.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D139839/new/

https://reviews.llvm.org/D139839

Files:
  libc/utils/CMakeLists.txt
  libc/utils/gpu/CMakeLists.txt
  libc/utils/gpu/loader/CMakeLists.txt
  libc/utils/gpu/loader/Loader.h
  libc/utils/gpu/loader/Main.cpp
  libc/utils/gpu/loader/amdgpu/CMakeLists.txt
  libc/utils/gpu/loader/amdgpu/Loader.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D139839.495846.patch
Type: text/x-patch
Size: 18575 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libc-commits/attachments/20230208/f467f9f0/attachment-0001.bin>


More information about the libc-commits mailing list