[llvm-commits] CVS: llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp
Evan Cheng
evan.cheng at apple.com
Thu Jun 28 18:25:29 PDT 2007
Changes in directory llvm/lib/Target/PowerPC:
PPCISelDAGToDAG.cpp updated: 1.231 -> 1.232
---
Log message:
Prevent PPC::BCC first operand, the PRED number, from being isel'd into a LI instruction.
---
Diffs of the changes: (+4 -1)
PPCISelDAGToDAG.cpp | 5 ++++-
1 files changed, 4 insertions(+), 1 deletion(-)
Index: llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp
diff -u llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp:1.231 llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp:1.232
--- llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp:1.231 Fri Jun 22 09:59:07 2007
+++ llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp Thu Jun 28 20:25:06 2007
@@ -1080,7 +1080,10 @@
// Op #2 is the CR#
// Op #3 is the Dest MBB
AddToISelQueue(N->getOperand(4)); // Op #4 is the Flag.
- SDOperand Ops[] = { N->getOperand(1), N->getOperand(2), N->getOperand(3),
+ // Prevent PPC::PRED_* from being selected into LI.
+ SDOperand Pred =
+ getI32Imm(cast<ConstantSDNode>(N->getOperand(1))->getValue());
+ SDOperand Ops[] = { Pred, N->getOperand(2), N->getOperand(3),
N->getOperand(0), N->getOperand(4) };
return CurDAG->SelectNodeTo(N, PPC::BCC, MVT::Other, Ops, 5);
}
More information about the llvm-commits
mailing list