mirror of
https://github.com/RPCSX/llvm.git
synced 2024-12-03 09:21:13 +00:00
Move default FrameReg val to getFrameIndexReference(). Otherwise, debug info can get bogus values.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@89618 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
7ab38dfccb
commit
a37aa54622
@ -807,6 +807,7 @@ ARMBaseRegisterInfo::getFrameIndexReference(MachineFunction &MF, int FI,
|
||||
int Offset = MFI->getObjectOffset(FI) + MFI->getStackSize();
|
||||
bool isFixed = MFI->isFixedObjectIndex(FI);
|
||||
|
||||
FrameReg = ARM::SP;
|
||||
if (AFI->isGPRCalleeSavedArea1Frame(FI))
|
||||
Offset -= AFI->getGPRCalleeSavedArea1Offset();
|
||||
else if (AFI->isGPRCalleeSavedArea2Frame(FI))
|
||||
@ -1162,9 +1163,9 @@ ARMBaseRegisterInfo::eliminateFrameIndex(MachineBasicBlock::iterator II,
|
||||
assert(i < MI.getNumOperands() && "Instr doesn't have FrameIndex operand!");
|
||||
}
|
||||
|
||||
unsigned FrameReg = ARM::SP;
|
||||
int FrameIndex = MI.getOperand(i).getIndex();
|
||||
int Offset = MFI->getObjectOffset(FrameIndex) + MFI->getStackSize() + SPAdj;
|
||||
unsigned FrameReg;
|
||||
|
||||
Offset = getFrameIndexReference(MF, FrameIndex, FrameReg);
|
||||
if (FrameReg != ARM::SP)
|
||||
|
Loading…
Reference in New Issue
Block a user