[Openmp-commits] [PATCH] D102107: [OpenMP] Codegen aggregate for outlined function captures

Jon Chesterfield via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Wed Sep 22 02:47:30 PDT 2021

JonChesterfield added a comment.

In D102107#3014599 <https://reviews.llvm.org/D102107#3014599>, @pdhaliwal wrote:

> It looks like from IR diff that this patch is adding use of kmpc_alloc_shared method. These methods likely won't work on AMDGPU as device malloc is not available. Not sure what could be done apart from marking those tests as XFAIL on amdgcn. :(

That's a good theory. Could confirm by patching the amdgpu malloc to return 0xdeadbeef or similar instead of 0 and seeing if that number shows up in the invalid memory access error. If so there's two problems:
1/ malloc on the gpu can fail, so it would mean we're missing a check on the return code of malloc in the devicertl
2/ increased importance for getting malloc running on amdgpu
The openmp in rocm/aomp does have a malloc, so it would also be interesting to see if they run OK with this patch applied

  rG LLVM Github Monorepo



More information about the Openmp-commits mailing list