diff options
Diffstat (limited to 'llvm/lib/Target/ARM/ARMFrameLowering.cpp')
| -rw-r--r-- | llvm/lib/Target/ARM/ARMFrameLowering.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/llvm/lib/Target/ARM/ARMFrameLowering.cpp b/llvm/lib/Target/ARM/ARMFrameLowering.cpp index 8a8f3237bb6f..9eeb7f20dc8d 100644 --- a/llvm/lib/Target/ARM/ARMFrameLowering.cpp +++ b/llvm/lib/Target/ARM/ARMFrameLowering.cpp @@ -883,9 +883,10 @@ void ARMFrameLowering::emitEpilogue(MachineFunction &MF, /// debug info. It's the same as what we use for resolving the code-gen /// references for now. FIXME: This can go wrong when references are /// SP-relative and simple call frames aren't used. -int ARMFrameLowering::getFrameIndexReference(const MachineFunction &MF, int FI, - Register &FrameReg) const { - return ResolveFrameIndexReference(MF, FI, FrameReg, 0); +StackOffset ARMFrameLowering::getFrameIndexReference(const MachineFunction &MF, + int FI, + Register &FrameReg) const { + return StackOffset::getFixed(ResolveFrameIndexReference(MF, FI, FrameReg, 0)); } int ARMFrameLowering::ResolveFrameIndexReference(const MachineFunction &MF, @@ -2113,8 +2114,7 @@ void ARMFrameLowering::determineCalleeSaves(MachineFunction &MF, unsigned NumExtras = TargetAlign.value() / 4; SmallVector<unsigned, 2> Extras; while (NumExtras && !UnspilledCS1GPRs.empty()) { - unsigned Reg = UnspilledCS1GPRs.back(); - UnspilledCS1GPRs.pop_back(); + unsigned Reg = UnspilledCS1GPRs.pop_back_val(); if (!MRI.isReserved(Reg) && (!AFI->isThumb1OnlyFunction() || isARMLowRegister(Reg))) { Extras.push_back(Reg); @@ -2124,8 +2124,7 @@ void ARMFrameLowering::determineCalleeSaves(MachineFunction &MF, // For non-Thumb1 functions, also check for hi-reg CS registers if (!AFI->isThumb1OnlyFunction()) { while (NumExtras && !UnspilledCS2GPRs.empty()) { - unsigned Reg = UnspilledCS2GPRs.back(); - UnspilledCS2GPRs.pop_back(); + unsigned Reg = UnspilledCS2GPRs.pop_back_val(); if (!MRI.isReserved(Reg)) { Extras.push_back(Reg); NumExtras--; |
