[llvm-commits] CVS: llvm/lib/Target/PowerPC/PPC32ISelSimple.cpp
Chris Lattner
lattner at cs.uiuc.edu
Mon Nov 29 22:36:23 PST 2004
Changes in directory llvm/lib/Target/PowerPC:
PPC32ISelSimple.cpp updated: 1.114 -> 1.115
---
Log message:
Fix test/Regression/CodeGen/PowerPC/2004-11-29-ShrCrash.ll
---
Diffs of the changes: (+3 -1)
Index: llvm/lib/Target/PowerPC/PPC32ISelSimple.cpp
diff -u llvm/lib/Target/PowerPC/PPC32ISelSimple.cpp:1.114 llvm/lib/Target/PowerPC/PPC32ISelSimple.cpp:1.115
--- llvm/lib/Target/PowerPC/PPC32ISelSimple.cpp:1.114 Tue Nov 30 00:29:10 2004
+++ llvm/lib/Target/PowerPC/PPC32ISelSimple.cpp Tue Nov 30 00:36:11 2004
@@ -2910,7 +2910,9 @@
return;
unsigned SrcReg = getReg (Op, MBB, IP);
- if (isLeftShift) {
+ if (Amount == 0) {
+ BuildMI(*MBB, IP, PPC::OR, 2, DestReg).addReg(SrcReg).addReg(SrcReg);
+ } else if (isLeftShift) {
BuildMI(*MBB, IP, PPC::RLWINM, 4, DestReg).addReg(SrcReg)
.addImm(Amount).addImm(0).addImm(31-Amount);
} else {
More information about the llvm-commits
mailing list