diff options
author | Bob Wilson <bob.wilson@apple.com> | 2009-09-23 20:57:02 +0000 |
---|---|---|
committer | Bob Wilson <bob.wilson@apple.com> | 2009-09-23 20:57:02 +0000 |
commit | abfdbbfd1a6974802c4a51e6ff0c9c31b50883e3 (patch) | |
tree | 84cb2680e00deb9fe55e6e2e1108a53c0b307571 /llvm/lib | |
parent | 71130ca141ede4b6f4e3ef1603d2b8b4587db5e8 (diff) | |
download | bcm5719-llvm-abfdbbfd1a6974802c4a51e6ff0c9c31b50883e3.tar.gz bcm5719-llvm-abfdbbfd1a6974802c4a51e6ff0c9c31b50883e3.zip |
Remove BlackfinRegisterInfo::getFrameIndexOffset since it is the same as the
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.
llvm-svn: 82651
Diffstat (limited to 'llvm/lib')
-rw-r--r-- | llvm/lib/Target/Blackfin/BlackfinRegisterInfo.cpp | 8 | ||||
-rw-r--r-- | llvm/lib/Target/Blackfin/BlackfinRegisterInfo.h | 1 | ||||
-rw-r--r-- | llvm/lib/Target/TargetRegisterInfo.cpp | 2 |
3 files changed, 1 insertions, 10 deletions
diff --git a/llvm/lib/Target/Blackfin/BlackfinRegisterInfo.cpp b/llvm/lib/Target/Blackfin/BlackfinRegisterInfo.cpp index e820c3b1ff6..bb132c57ddd 100644 --- a/llvm/lib/Target/Blackfin/BlackfinRegisterInfo.cpp +++ b/llvm/lib/Target/Blackfin/BlackfinRegisterInfo.cpp @@ -451,14 +451,6 @@ unsigned BlackfinRegisterInfo::getFrameRegister(MachineFunction &MF) const { 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; diff --git a/llvm/lib/Target/Blackfin/BlackfinRegisterInfo.h b/llvm/lib/Target/Blackfin/BlackfinRegisterInfo.h index 57aea5d3dc1..5379ca5c914 100644 --- a/llvm/lib/Target/Blackfin/BlackfinRegisterInfo.h +++ b/llvm/lib/Target/Blackfin/BlackfinRegisterInfo.h @@ -76,7 +76,6 @@ namespace llvm { 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. diff --git a/llvm/lib/Target/TargetRegisterInfo.cpp b/llvm/lib/Target/TargetRegisterInfo.cpp index 902ee0c04d8..43123991ea8 100644 --- a/llvm/lib/Target/TargetRegisterInfo.cpp +++ b/llvm/lib/Target/TargetRegisterInfo.cpp @@ -85,7 +85,7 @@ BitVector TargetRegisterInfo::getAllocatableSet(MachineFunction &MF, /// 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(); |