- Emit UdtSourceLine information for enums to match MSVC
- Add a method to add UDTSrcLine and call it for all Class/Struct/Union/Enum
- Update test cases to verify the changes
Paths
| Differential D44116
[CodeView] Emit UdtSourceLine information for enums ClosedPublic Authored by asmith on Mar 5 2018, 1:15 PM.
Details Summary
Diff Detail
Event TimelineComment Actions We also probably need to emit S_UDT symbol records in the right place. Can you factor out a method with this code from lowerCompleteTypeClass and make Class, Enum, and Union code call it? This is the duplicated code that has already diverged a little bit: if (const auto *File = Ty->getFile()) { StringIdRecord SIDR(TypeIndex(0x0), getFullFilepath(File)); TypeIndex SIDI = TypeTable.writeLeafType(SIDR); UdtSourceLineRecord USLR(ClassTI, SIDI, Ty->getLine()); TypeTable.writeLeafType(USLR); } addToUDTs(Ty); Comment Actions lgtm
This revision is now accepted and ready to land.Mar 6 2018, 9:59 AM Closed by commit rL326824: [CodeView] Emit UdtSourceLine information for enums (authored by asmith). · Explain WhyMar 6 2018, 10:22 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 137225 llvm/trunk/lib/CodeGen/AsmPrinter/CodeViewDebug.h
llvm/trunk/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
llvm/trunk/test/DebugInfo/COFF/enum.ll
llvm/trunk/test/DebugInfo/COFF/nested-types.ll
|