aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Target/PowerPC/PPCRegisterInfo.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2007-02-01 00:39:08 +0000
committerChris Lattner <sabre@nondot.org>2007-02-01 00:39:08 +0000
commit9aa2895360bd3951fc4f204d8699b84fd9ea6ba5 (patch)
tree459eac77f514e526c8d4daa67a9831a00cd6d1b6 /lib/Target/PowerPC/PPCRegisterInfo.cpp
parent36a724341c7ed62ebccd7408f2e5f4e130f8d22d (diff)
downloadexternal_llvm-9aa2895360bd3951fc4f204d8699b84fd9ea6ba5.zip
external_llvm-9aa2895360bd3951fc4f204d8699b84fd9ea6ba5.tar.gz
external_llvm-9aa2895360bd3951fc4f204d8699b84fd9ea6ba5.tar.bz2
Fix CodeGen/PowerPC/2007-01-31-InlineAsmAddrMode.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33732 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/PowerPC/PPCRegisterInfo.cpp')
-rw-r--r--lib/Target/PowerPC/PPCRegisterInfo.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Target/PowerPC/PPCRegisterInfo.cpp b/lib/Target/PowerPC/PPCRegisterInfo.cpp
index 4324b9d..fb80350 100644
--- a/lib/Target/PowerPC/PPCRegisterInfo.cpp
+++ b/lib/Target/PowerPC/PPCRegisterInfo.cpp
@@ -522,6 +522,9 @@ PPCRegisterInfo::eliminateFrameIndex(MachineBasicBlock::iterator II) const {
}
// Take into account whether it's an add or mem instruction
unsigned OffIdx = (i == 2) ? 1 : 2;
+ if (MI.getOpcode() == TargetInstrInfo::INLINEASM)
+ OffIdx = i-1;
+
// Get the frame index.
int FrameIndex = MI.getOperand(i).getFrameIndex();