mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-23 17:24:48 +00:00
Use the cached subtarget off of the machine function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@232128 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -1517,9 +1517,9 @@ static void emitDebugLocValue(const AsmPrinter &AP,
|
|||||||
const DebugLocEntry::Value &Value,
|
const DebugLocEntry::Value &Value,
|
||||||
unsigned PieceOffsetInBits) {
|
unsigned PieceOffsetInBits) {
|
||||||
DIVariable DV = Value.getVariable();
|
DIVariable DV = Value.getVariable();
|
||||||
DebugLocDwarfExpression DwarfExpr(
|
DebugLocDwarfExpression DwarfExpr(*AP.MF->getSubtarget().getRegisterInfo(),
|
||||||
*AP.TM.getSubtargetImpl()->getRegisterInfo(),
|
AP.getDwarfDebug()->getDwarfVersion(),
|
||||||
AP.getDwarfDebug()->getDwarfVersion(), Streamer);
|
Streamer);
|
||||||
// Regular entry.
|
// Regular entry.
|
||||||
if (Value.isInt()) {
|
if (Value.isInt()) {
|
||||||
DIBasicType BTy(DV.getType().resolve(TypeIdentifierMap));
|
DIBasicType BTy(DV.getType().resolve(TypeIdentifierMap));
|
||||||
@ -1570,9 +1570,9 @@ void DebugLocEntry::finalize(const AsmPrinter &AP,
|
|||||||
assert(Offset <= PieceOffset && "overlapping or duplicate pieces");
|
assert(Offset <= PieceOffset && "overlapping or duplicate pieces");
|
||||||
if (Offset < PieceOffset) {
|
if (Offset < PieceOffset) {
|
||||||
// The DWARF spec seriously mandates pieces with no locations for gaps.
|
// The DWARF spec seriously mandates pieces with no locations for gaps.
|
||||||
DebugLocDwarfExpression Expr(
|
DebugLocDwarfExpression Expr(*AP.MF->getSubtarget().getRegisterInfo(),
|
||||||
*AP.TM.getSubtargetImpl()->getRegisterInfo(),
|
AP.getDwarfDebug()->getDwarfVersion(),
|
||||||
AP.getDwarfDebug()->getDwarfVersion(), Streamer);
|
Streamer);
|
||||||
Expr.AddOpPiece(PieceOffset-Offset, 0);
|
Expr.AddOpPiece(PieceOffset-Offset, 0);
|
||||||
Offset += PieceOffset-Offset;
|
Offset += PieceOffset-Offset;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user