[llvm] [OpenMP][clang] Register vtables on device for indirect calls runtime (PR #167011)
Joseph Huber via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 24 08:58:42 PST 2025
================
@@ -112,21 +112,58 @@ setupIndirectCallTable(DeviceTy &Device, __tgt_device_image *Image,
llvm::SmallVector<std::pair<void *, void *>> IndirectCallTable;
for (const auto &Entry : Entries) {
if (Entry.Kind != llvm::object::OffloadKind::OFK_OpenMP ||
- Entry.Size == 0 || !(Entry.Flags & OMP_DECLARE_TARGET_INDIRECT))
+ Entry.Size == 0 ||
+ (!(Entry.Flags & OMP_DECLARE_TARGET_INDIRECT) &&
+ !(Entry.Flags & OMP_DECLARE_TARGET_INDIRECT_VTABLE)))
----------------
jhuber6 wrote:
Can you explain the difference between `OMP_DECLARE_TARGET_INDIRECT` and `OMP_DECLARE_TARGET_INDIRECT_VTABLE`? I don't exactly remember what I did for the indirect case, I think it was just a pair of globals or something.
https://github.com/llvm/llvm-project/pull/167011
More information about the llvm-commits
mailing list