Fix a problem Nate found where we swapped the operands of SHL/SHR_PARTS. This
authorChris Lattner <sabre@nondot.org>
Tue, 30 Aug 2005 17:42:59 +0000 (17:42 +0000)
committerChris Lattner <sabre@nondot.org>
Tue, 30 Aug 2005 17:42:59 +0000 (17:42 +0000)
fixes fourinarow

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@23153 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/PowerPC/PPCISelDAGToDAG.cpp

index 85c582c192a35a00ba854baeb89cbfeafeb11cd6..93e96376b5997ecedc450e442df53ddba656423a 100644 (file)
@@ -1228,8 +1228,8 @@ SDOperand PPC32DAGToDAGISel::Select(SDOperand Op) {
     return Result[Op.ResNo];
   }
   case ISD::SHL_PARTS: {
-    SDOperand HI = Select(N->getOperand(0));
-    SDOperand LO = Select(N->getOperand(1));
+    SDOperand LO = Select(N->getOperand(0));
+    SDOperand HI = Select(N->getOperand(1));
     SDOperand SH = Select(N->getOperand(2));
     SDOperand SH_LO_R = CurDAG->getTargetNode(PPC::SUBFIC, MVT::i32, MVT::Flag,
                                               SH, getI32Imm(32));
@@ -1247,8 +1247,8 @@ SDOperand PPC32DAGToDAGISel::Select(SDOperand Op) {
     return Result[Op.ResNo];
   }
   case ISD::SRL_PARTS: {
-    SDOperand HI = Select(N->getOperand(0));
-    SDOperand LO = Select(N->getOperand(1));
+    SDOperand LO = Select(N->getOperand(0));
+    SDOperand HI = Select(N->getOperand(1));
     SDOperand SH = Select(N->getOperand(2));
     SDOperand SH_HI_L = CurDAG->getTargetNode(PPC::SUBFIC, MVT::i32, MVT::Flag,
                                               SH, getI32Imm(32));