TypedDINodeRef<T> is a redundant wrapper of Metadata * that is actually a T *.
Accordingly, change DI{Node,Scope,Type}Ref uses to {const,} DI{Node,Scope,Type} *
This allows us to delete many resolve() calls that clutter the code.
Paths
| Differential D61369
[DebugInfo] Delete TypedDINodeRef ClosedPublic Authored by MaskRay on May 1 2019, 1:26 AM.
Details
Summary TypedDINodeRef<T> is a redundant wrapper of Metadata * that is actually a T *. Accordingly, change DI{Node,Scope,Type}Ref uses to {const,} DI{Node,Scope,Type} *
Diff Detail
Event TimelineComment Actions lgtm, thanks!
This revision is now accepted and ready to land.May 6 2019, 10:39 AM Closed by commit rL360108: [DebugInfo] Delete TypedDINodeRef (authored by MaskRay). · Explain WhyMay 6 2019, 7:05 PM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 197513 include/llvm/CodeGen/DebugHandlerBase.h
include/llvm/IR/DebugInfoMetadata.h
lib/Bitcode/Reader/MetadataLoader.cpp
lib/CodeGen/AsmPrinter/CodeViewDebug.h
lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
lib/CodeGen/AsmPrinter/DebugHandlerBase.cpp
lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
lib/CodeGen/AsmPrinter/DwarfDebug.h
lib/CodeGen/AsmPrinter/DwarfDebug.cpp
lib/CodeGen/AsmPrinter/DwarfUnit.h
lib/CodeGen/AsmPrinter/DwarfUnit.cpp
lib/IR/DIBuilder.cpp
lib/IR/DebugInfo.cpp
lib/IR/DebugInfoMetadata.cpp
lib/Target/BPF/BTFDebug.cpp
tools/opt/BreakpointPrinter.cpp
|
I can confirm the original motivation (MDString-based ODR-uniquing). @rnk, is it still thought to be useful for CodeView?