[PATCH] D88786: [CUDA] Don't call __cudaRegisterVariable on C++17 inline variables
Yaxun Liu via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Oct 5 14:43:07 PDT 2020
yaxunl added a comment.
This patch may break some existing HIP applications.
For rdc mode, device vars are merged. Host shadow vars should also be in comdat and merged. HIP runtime just ignores the same shadow var registered with the same device var, everything should work.
For nordc mode, device vars are in different fat binaries. If shadow vars are not in comdat and not merged, they can be registered with device vars in different fat binaries. Things would still work.
I think inline variable and static constexpr member are very useful features. Disabling them for device variable is a big limitation.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D88786/new/
https://reviews.llvm.org/D88786
More information about the cfe-commits
mailing list