================
@@ -36,6 +46,15 @@ extern "C" {
#pragma omp end declare variant
#ifdef __AMDGCN__
+#pragma omp begin declare variant match(
\
+ device = {arch(amdgcn)},
\
+ implementation = {extension(disable_implicit_base)})
+
+void *malloc(size_t Size) { return llvm_device_malloc(Size); }
+void free(void *Ptr) { llvm_device_free(Ptr); }
----------------
jhuber6 wrote:
Unsure how to feel about this, here we always replace `malloc` calls with the
one inside the OpenMP device runtime library won't it?
https://github.com/llvm/llvm-project/pull/69806
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits