diff options
| author | Akira Hatanaka <ahatanaka@mips.com> | 2012-07-31 21:28:49 +0000 |
|---|---|---|
| committer | Akira Hatanaka <ahatanaka@mips.com> | 2012-07-31 21:28:49 +0000 |
| commit | 02de0e44258b689620a972286e4ee9d0b677bb66 (patch) | |
| tree | bb2617e9ef6580dca4f9eb3a0ad75be6c562584d /llvm/lib/Target/Mips | |
| parent | 33a25af5a81409c324ef29c4c942ea04e0d93836 (diff) | |
| download | bcm5719-llvm-02de0e44258b689620a972286e4ee9d0b677bb66.tar.gz bcm5719-llvm-02de0e44258b689620a972286e4ee9d0b677bb66.zip | |
Let PEI::calculateFrameObjectOffsets compute the final stack size rather than
computing it in MipsFrameLowering::emitPrologue.
llvm-svn: 161078
Diffstat (limited to 'llvm/lib/Target/Mips')
| -rw-r--r-- | llvm/lib/Target/Mips/MipsFrameLowering.cpp | 11 | ||||
| -rw-r--r-- | llvm/lib/Target/Mips/MipsFrameLowering.h | 2 |
2 files changed, 1 insertions, 12 deletions
diff --git a/llvm/lib/Target/Mips/MipsFrameLowering.cpp b/llvm/lib/Target/Mips/MipsFrameLowering.cpp index d5c02ceab18..ca7ba124e66 100644 --- a/llvm/lib/Target/Mips/MipsFrameLowering.cpp +++ b/llvm/lib/Target/Mips/MipsFrameLowering.cpp @@ -90,10 +90,6 @@ bool MipsFrameLowering::hasFP(const MachineFunction &MF) const { MFI->hasVarSizedObjects() || MFI->isFrameAddressTaken(); } -bool MipsFrameLowering::targetHandlesStackFrameRounding() const { - return true; -} - void MipsFrameLowering::emitPrologue(MachineFunction &MF) const { MachineBasicBlock &MBB = MF.front(); MachineFrameInfo *MFI = MF.getFrameInfo(); @@ -110,12 +106,7 @@ void MipsFrameLowering::emitPrologue(MachineFunction &MF) const { unsigned ADDiu = STI.isABI_N64() ? Mips::DADDiu : Mips::ADDiu; // First, compute final stack size. - unsigned StackAlign = getStackAlignment(); - uint64_t StackSize = RoundUpToAlignment(MFI->getStackSize(), StackAlign); - StackSize += RoundUpToAlignment(MFI->getMaxCallFrameSize(), StackAlign); - - // Update stack size - MFI->setStackSize(StackSize); + uint64_t StackSize = MFI->getStackSize(); // No need to allocate space on the stack. if (StackSize == 0 && !MFI->adjustsStack()) return; diff --git a/llvm/lib/Target/Mips/MipsFrameLowering.h b/llvm/lib/Target/Mips/MipsFrameLowering.h index e364dedff26..2cd8340b075 100644 --- a/llvm/lib/Target/Mips/MipsFrameLowering.h +++ b/llvm/lib/Target/Mips/MipsFrameLowering.h @@ -31,8 +31,6 @@ public: STI(sti) { } - bool targetHandlesStackFrameRounding() const; - /// emitProlog/emitEpilog - These methods insert prolog and epilog code into /// the function. void emitPrologue(MachineFunction &MF) const; |

