[PATCH] D116967: [HIP] Fix device malloc/free
Yaxun Liu via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Jan 10 12:34:59 PST 2022
yaxunl created this revision.
yaxunl added reviewers: tra, b-sumner.
yaxunl requested review of this revision.
ROCm 4.5 device library introduced `__ockl_dm_alloc` and `__oclk_dm_dealloc`
for supporting device side malloc/free.
This patch redefines device malloc/free to use these functions.
It also fixes a bug in the wrapper header which incorrectly defines free
with return type void* instead of void.
https://reviews.llvm.org/D116967
Files:
clang/lib/Headers/__clang_hip_runtime_wrapper.h
clang/test/Headers/hip-header.hip
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D116967.398718.patch
Type: text/x-patch
Size: 4023 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220110/2ab30814/attachment.bin>
More information about the cfe-commits
mailing list