default implementation. Update comment on the default version, which made it
sound like most targets override it. Currently only X86 and SystemZ override
this method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82651
91177308-0d34-0410-b5e6-
96231b3b80d8
return hasFP(MF) ? BF::FP : BF::SP;
}
-int
-BlackfinRegisterInfo::getFrameIndexOffset(MachineFunction &MF, int FI) const {
- const TargetFrameInfo &TFI = *MF.getTarget().getFrameInfo();
- MachineFrameInfo *MFI = MF.getFrameInfo();
- return MFI->getObjectOffset(FI) + MFI->getStackSize() -
- TFI.getOffsetOfLocalArea() + MFI->getOffsetAdjustment();
-}
-
unsigned BlackfinRegisterInfo::getEHExceptionRegister() const {
llvm_unreachable("What is the exception register");
return 0;
void emitEpilogue(MachineFunction &MF, MachineBasicBlock &MBB) const;
unsigned getFrameRegister(MachineFunction &MF) const;
- int getFrameIndexOffset(MachineFunction &MF, int FI) const;
unsigned getRARegister() const;
// Exception handling queries.
/// getFrameIndexOffset - Returns the displacement from the frame register to
/// the stack frame of the specified index. This is the default implementation
-/// which is likely incorrect for the target.
+/// which is overridden for some targets.
int TargetRegisterInfo::getFrameIndexOffset(MachineFunction &MF, int FI) const {
const TargetFrameInfo &TFI = *MF.getTarget().getFrameInfo();
MachineFrameInfo *MFI = MF.getFrameInfo();