[PATCH] D143967: [DebugInfo][BPF] Add 'btf:type_tag' annotation in DWARF
David Blaikie via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Nov 8 10:54:04 PST 2023
dblaikie accepted this revision.
dblaikie added a comment.
This revision is now accepted and ready to land.
Fair enough - all seems a bit unfortunate to be pushing these attributes through to places they don't technically apply to (both complicates the implementation, and might be confusing to users).
Thanks for trying the prototype - not clear what the right design is, so let's go with what you've got here.
================
Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:1249
+ llvm::DIType *WrappedDI = getOrCreateType(WrappedTy, Unit);
+ if (Annotations.size() == 0)
+ return WrappedDI;
----------------
use `empty()` rather than `size() == 0`
================
Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:1252
+
+ if (WrappedDI == nullptr)
+ WrappedDI = DBuilder.createUnspecifiedType("void");
----------------
probably write this as `if (!WrappedDI)`
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D143967/new/
https://reviews.llvm.org/D143967
More information about the cfe-commits
mailing list