summaryrefslogtreecommitdiff
path: root/lib/Target/ARM/ARMFastISel.cpp
diff options
context:
space:
mode:
authorJim Grosbach <grosbach@apple.com>2013-08-20 19:12:42 +0000
committerJim Grosbach <grosbach@apple.com>2013-08-20 19:12:42 +0000
commit8b262e5ab8cbeb8f6f61d92b20d886675966fe34 (patch)
tree7b469d2e4f4132e8dfd27c3eb88af5d1af6c31a9 /lib/Target/ARM/ARMFastISel.cpp
parent11873fc85af0730d0da051f8b832cf349511b448 (diff)
downloadllvm-8b262e5ab8cbeb8f6f61d92b20d886675966fe34.tar.gz
llvm-8b262e5ab8cbeb8f6f61d92b20d886675966fe34.tar.bz2
llvm-8b262e5ab8cbeb8f6f61d92b20d886675966fe34.tar.xz
ARM: Fix fast-isel copy/paste-o.
Update testcase to be more careful about checking register values. While regexes are general goodness for these sorts of testcases, in this example, the registers are constrained by the calling convention, so we can and should check their explicit values. rdar://14779513 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@188819 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/ARM/ARMFastISel.cpp')
-rw-r--r--lib/Target/ARM/ARMFastISel.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Target/ARM/ARMFastISel.cpp b/lib/Target/ARM/ARMFastISel.cpp
index e1af947b07..f4aaf09038 100644
--- a/lib/Target/ARM/ARMFastISel.cpp
+++ b/lib/Target/ARM/ARMFastISel.cpp
@@ -1762,7 +1762,7 @@ bool ARMFastISel::SelectSelect(const Instruction *I) {
}
unsigned ResultReg = createResultReg(RC);
if (!UseImm) {
- Op2Reg = constrainOperandRegClass(TII.get(MovCCOpc), Op1Reg, 1);
+ Op2Reg = constrainOperandRegClass(TII.get(MovCCOpc), Op2Reg, 1);
Op1Reg = constrainOperandRegClass(TII.get(MovCCOpc), Op1Reg, 2);
BuildMI(*FuncInfo.MBB, FuncInfo.InsertPt, DL, TII.get(MovCCOpc), ResultReg)
.addReg(Op2Reg).addReg(Op1Reg).addImm(ARMCC::NE).addReg(ARM::CPSR);