[llvm] r232128 - Use the cached subtarget off of the machine function.
Eric Christopher
echristo at gmail.com
Thu Mar 12 17:38:19 PDT 2015
Author: echristo
Date: Thu Mar 12 19:38:19 2015
New Revision: 232128
URL: http://llvm.org/viewvc/llvm-project?rev=232128&view=rev
Log:
Use the cached subtarget off of the machine function.
Modified:
llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
Modified: llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp?rev=232128&r1=232127&r2=232128&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp (original)
+++ llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp Thu Mar 12 19:38:19 2015
@@ -1517,9 +1517,9 @@ static void emitDebugLocValue(const AsmP
const DebugLocEntry::Value &Value,
unsigned PieceOffsetInBits) {
DIVariable DV = Value.getVariable();
- DebugLocDwarfExpression DwarfExpr(
- *AP.TM.getSubtargetImpl()->getRegisterInfo(),
- AP.getDwarfDebug()->getDwarfVersion(), Streamer);
+ DebugLocDwarfExpression DwarfExpr(*AP.MF->getSubtarget().getRegisterInfo(),
+ AP.getDwarfDebug()->getDwarfVersion(),
+ Streamer);
// Regular entry.
if (Value.isInt()) {
DIBasicType BTy(DV.getType().resolve(TypeIdentifierMap));
@@ -1570,9 +1570,9 @@ void DebugLocEntry::finalize(const AsmPr
assert(Offset <= PieceOffset && "overlapping or duplicate pieces");
if (Offset < PieceOffset) {
// The DWARF spec seriously mandates pieces with no locations for gaps.
- DebugLocDwarfExpression Expr(
- *AP.TM.getSubtargetImpl()->getRegisterInfo(),
- AP.getDwarfDebug()->getDwarfVersion(), Streamer);
+ DebugLocDwarfExpression Expr(*AP.MF->getSubtarget().getRegisterInfo(),
+ AP.getDwarfDebug()->getDwarfVersion(),
+ Streamer);
Expr.AddOpPiece(PieceOffset-Offset, 0);
Offset += PieceOffset-Offset;
}
More information about the llvm-commits
mailing list