aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Target/Mips
diff options
context:
space:
mode:
authorAkira Hatanaka <ahatanaka@mips.com>2012-05-12 03:21:18 +0000
committerAkira Hatanaka <ahatanaka@mips.com>2012-05-12 03:21:18 +0000
commit93f0a823bfce76572432a11bf9aeb1803b78d3e5 (patch)
treeb1bd0f139c959f553d5d9758d93ca2b5a1eec6cb /lib/Target/Mips
parentacf411bd4c1b887c6c4f13d0d82164d32caddce3 (diff)
downloadexternal_llvm-93f0a823bfce76572432a11bf9aeb1803b78d3e5.zip
external_llvm-93f0a823bfce76572432a11bf9aeb1803b78d3e5.tar.gz
external_llvm-93f0a823bfce76572432a11bf9aeb1803b78d3e5.tar.bz2
Stop reserving register $gp. Do not call isGPFI to check whether a frame object
is the $gp save slot. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@156694 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/Mips')
-rw-r--r--lib/Target/Mips/MipsRegisterInfo.cpp9
1 files changed, 1 insertions, 8 deletions
diff --git a/lib/Target/Mips/MipsRegisterInfo.cpp b/lib/Target/Mips/MipsRegisterInfo.cpp
index 37b0ed2..5fdeda9 100644
--- a/lib/Target/Mips/MipsRegisterInfo.cpp
+++ b/lib/Target/Mips/MipsRegisterInfo.cpp
@@ -118,12 +118,6 @@ getReservedRegs(const MachineFunction &MF) const {
Reserved.set(*Reg);
}
- // If GP is dedicated as a global base register, reserve it.
- if (MF.getInfo<MipsFunctionInfo>()->globalBaseRegFixed()) {
- Reserved.set(Mips::GP);
- Reserved.set(Mips::GP_64);
- }
-
// Reserve FP if this function should have a dedicated frame pointer register.
if (MF.getTarget().getFrameLowering()->hasFP(MF)) {
Reserved.set(Mips::FP);
@@ -217,8 +211,7 @@ eliminateFrameIndex(MachineBasicBlock::iterator II, int SPAdj,
// incoming argument, callee-saved register location or local variable.
int64_t Offset;
- if (MipsFI->isOutArgFI(FrameIndex) || MipsFI->isGPFI(FrameIndex) ||
- MipsFI->isDynAllocFI(FrameIndex))
+ if (MipsFI->isOutArgFI(FrameIndex) || MipsFI->isDynAllocFI(FrameIndex))
Offset = spOffset;
else
Offset = spOffset + (int64_t)stackSize;