diff --git a/lib/Target/Mips/MipsTargetMachine.cpp b/lib/Target/Mips/MipsTargetMachine.cpp index 858723bad9d..1e6e8527267 100644 --- a/lib/Target/Mips/MipsTargetMachine.cpp +++ b/lib/Target/Mips/MipsTargetMachine.cpp @@ -105,7 +105,6 @@ public: } virtual bool addInstSelector(); - virtual bool addPreRegAlloc(); virtual bool addPreSched2(); virtual bool addPreEmitPass(); }; @@ -130,14 +129,6 @@ bool MipsPassConfig::addPreEmitPass() { return true; } -bool MipsPassConfig::addPreRegAlloc() { - // Do not restore $gp if target is Mips64. - // In N32/64, $gp is a callee-saved register. - if (!getMipsSubtarget().hasMips64()) - PM->add(createMipsEmitGPRestorePass(getMipsTargetMachine())); - return true; -} - bool MipsPassConfig::addPreSched2() { PM->add(createMipsExpandPseudoPass(getMipsTargetMachine())); return true;