[Openmp-commits] [PATCH] D51107: [LIBOMPTARGET] Add support for mapping of lambda captures.

Jonas Hahnfeld via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Thu Aug 23 09:39:53 PDT 2018


Hahnfeld added a comment.

In https://reviews.llvm.org/D51107#1211056, @ABataev wrote:

> This requires some significant redesign of the library itself + possibly the compiler. It would be better if somebody else, more familiar with libomptarget, could implement this.


I'd hope this to be an implementation detail of the library. This is on my list for quite some time...

In https://reviews.llvm.org/D51107#1211075, @ABataev wrote:

> BTW, the main problem here is that there is no mapping between host pointer and device pointer for the firstprivates, just like for the mapped data. We just need to rework the way we allocate the memory for the firstprivate to make `MEMBER_OF` to work.


Hmm, by going through the full stack of data allocation? Yes, I think that would be an acceptable workaround to get things running (certainly better than my hack in https://github.com/clang-ykt/openmp/commit/b836d5ddfc48faa8a61e79668f364608012075e4).
The refactoring that I proposed would then become an optimization to avoid needless queries to find the target pointer (because we can just cache it).


Repository:
  rOMP OpenMP

https://reviews.llvm.org/D51107





More information about the Openmp-commits mailing list