Move [get|set]BasePtrStackAdjustment() from MachineFrameInfo to
X86MachineFunctionInfo as this is currently only used by X86. If this ever
becomes an issue on another arch (e.g., ARM) then we can hoist it back out.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160009 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Target/X86/X86FrameLowering.cpp b/lib/Target/X86/X86FrameLowering.cpp
index 21ad062..bf0ba09 100644
--- a/lib/Target/X86/X86FrameLowering.cpp
+++ b/lib/Target/X86/X86FrameLowering.cpp
@@ -925,7 +925,7 @@
.addReg(StackPtr)
.setMIFlag(MachineInstr::FrameSetup);
- MFI->setBasePtrStackAdjustment(NumBytes);
+ X86FI->setBasePtrStackAdjustment(NumBytes);
}
if (( (!HasFP && NumBytes) || PushedRegs) && needsFrameMoves) {
@@ -1051,7 +1051,7 @@
StackPtr).addReg(BasePtr);
// When restoring from the BP we must use a cached SP adjustment.
- NumBytes = MFI->getBasePtrStackAdjustment();
+ NumBytes = X86FI->getBasePtrStackAdjustment();
}
// If dynamic alloca is used, then reset esp to point to the last callee-saved