[PATCH] D78655: [CUDA][HIP] Let non-caputuring lambda be host device

Paul Fultz II via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Jun 26 10:55:49 PDT 2020


pfultz2 added a comment.

> What's the expected HD property of this template function clip?

I think it is intended to be host-only. The function `f` will launch a kernel or threads to utilize the passed lambda.

Ideally, it would be nice to make all inlineable functions implicitly HD. There is a pragma to force HD, but it is broken(due to forcing HD on functions annotated as host-only or device-only). It would be nice to have a flag to enable such behavior(instead of a pragma). Requiring all these explicit HD annotations just seems like we are moving backwards.


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

https://reviews.llvm.org/D78655





More information about the cfe-commits mailing list