[PATCH] D143501: [clang][DebugInfo] lldb: Use preferred name's type when emitting DW_AT_names
Adrian Prantl via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Feb 14 09:20:04 PST 2023
aprantl added a comment.
> Alternatively, I suppose, the DWARF emission could just look at the preferred name and use that as the DW_AT_type in all cases anyway? Avoids needing a new attribute, etc, though would be a bit quirky in its own way.
Am I understanding you correctly that you suggest we add a new preferred name attribute to DICompositeType and then swap out all uses of those types with references to a typedef using the preferred name and pointing to the unmodified type declaration in AsmPrinter?
Why wouldn't we just implement this directly in CGDebugInfo and emit a DIDerivedType(name: "preferred", type: <original type>) and replace all uses of <original type> there? Then we wouldn't have to modify the IR format at all?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D143501/new/
https://reviews.llvm.org/D143501
More information about the cfe-commits
mailing list