[llvm] r289683 - This change does two things:
Eric Christopher via llvm-commits
llvm-commits at lists.llvm.org
Wed Dec 14 10:29:39 PST 2016
Author: echristo
Date: Wed Dec 14 12:29:39 2016
New Revision: 289683
URL: http://llvm.org/viewvc/llvm-project?rev=289683&view=rev
Log:
This change does two things:
Adds a "Discriminator" field to struct DILineInfo, which defaults to 0.
Fills out the "Discriminator" field in DILineInfo in DWARFDebugLine::LineTable::getFileLineInfoForAddress().
in order to have a slightly nicer interface in getFileLineInfoForAddress.
Patch by Simon Que!
Differential Revision: https://reviews.llvm.org/D27649
Modified:
llvm/trunk/include/llvm/DebugInfo/DIContext.h
llvm/trunk/lib/DebugInfo/DWARF/DWARFDebugLine.cpp
Modified: llvm/trunk/include/llvm/DebugInfo/DIContext.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/DebugInfo/DIContext.h?rev=289683&r1=289682&r2=289683&view=diff
==============================================================================
--- llvm/trunk/include/llvm/DebugInfo/DIContext.h (original)
+++ llvm/trunk/include/llvm/DebugInfo/DIContext.h Wed Dec 14 12:29:39 2016
@@ -35,8 +35,12 @@ struct DILineInfo {
uint32_t Line;
uint32_t Column;
+ // DWARF-specific.
+ uint32_t Discriminator;
+
DILineInfo()
- : FileName("<invalid>"), FunctionName("<invalid>"), Line(0), Column(0) {}
+ : FileName("<invalid>"), FunctionName("<invalid>"), Line(0), Column(0),
+ Discriminator(0) {}
bool operator==(const DILineInfo &RHS) const {
return Line == RHS.Line && Column == RHS.Column &&
Modified: llvm/trunk/lib/DebugInfo/DWARF/DWARFDebugLine.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/DebugInfo/DWARF/DWARFDebugLine.cpp?rev=289683&r1=289682&r2=289683&view=diff
==============================================================================
--- llvm/trunk/lib/DebugInfo/DWARF/DWARFDebugLine.cpp (original)
+++ llvm/trunk/lib/DebugInfo/DWARF/DWARFDebugLine.cpp Wed Dec 14 12:29:39 2016
@@ -678,5 +678,6 @@ bool DWARFDebugLine::LineTable::getFileL
return false;
Result.Line = Row.Line;
Result.Column = Row.Column;
+ Result.Discriminator = Row.Discriminator;
return true;
}
More information about the llvm-commits
mailing list