[Openmp-commits] [PATCH] D129787: [OpenMP][AMDGPU] Add the support for `malloc` and `free` for AMDGPU

Jon Chesterfield via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Fri Jul 15 06:25:49 PDT 2022


JonChesterfield added a comment.

Yep, the host plugin will be passing 0 at an offset where the ockl machinery expects some non-null value. I think that allocator uses some initial block allocated per kernel launch (or possibly per device image), but it should also fall back on a host call to get more memory when that is exhausted which will not work in trunk. It might be documented what setup is expected for the pointer (in particular whether it's shared across kernels and how much memory should be allocated there), otherwise it could be reverse engineered from hip.

Alternatively we could use a different implementation for malloc/free.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D129787



More information about the Openmp-commits mailing list