From 3ecc5273c1484e5ec72b72068f384924db7d161c Mon Sep 17 00:00:00 2001 From: Akira Hatanaka Date: Sat, 12 May 2012 03:22:13 +0000 Subject: Delete all functions that are no longer needed in MipsFunctionInfo, including the ones that get or set the frame index for the $gp save slot. Remove the piece of code in MipsFunctionInfo::getGlobalBaseReg() which returns GP. This function should always return a virtual register. llvm-svn: 156695 --- llvm/lib/Target/Mips/MipsMachineFunction.cpp | 7 ------- 1 file changed, 7 deletions(-) (limited to 'llvm/lib/Target/Mips/MipsMachineFunction.cpp') diff --git a/llvm/lib/Target/Mips/MipsMachineFunction.cpp b/llvm/lib/Target/Mips/MipsMachineFunction.cpp index 8535b290b43..e3746d4a420 100644 --- a/llvm/lib/Target/Mips/MipsMachineFunction.cpp +++ b/llvm/lib/Target/Mips/MipsMachineFunction.cpp @@ -22,10 +22,6 @@ static cl::opt FixGlobalBaseReg("mips-fix-global-base-reg", cl::Hidden, cl::init(true), cl::desc("Always use $gp as the global base register.")); -bool MipsFunctionInfo::globalBaseRegFixed() const { - return FixGlobalBaseReg; -} - bool MipsFunctionInfo::globalBaseRegSet() const { return GlobalBaseReg; } @@ -37,9 +33,6 @@ unsigned MipsFunctionInfo::getGlobalBaseReg() { const MipsSubtarget &ST = MF.getTarget().getSubtarget(); - if (FixGlobalBaseReg && ST.isABI_O32()) // $gp is the global base register. - return GlobalBaseReg = Mips::GP; - const TargetRegisterClass *RC = ST.isABI_N64() ? (const TargetRegisterClass*)&Mips::CPU64RegsRegClass : (const TargetRegisterClass*)&Mips::CPURegsRegClass; -- cgit v1.2.3