Implement expand support for MERGE_VALUEs that only produces one result.
authorChris Lattner <sabre@nondot.org>
Sat, 24 Nov 2007 19:12:15 +0000 (19:12 +0000)
committerChris Lattner <sabre@nondot.org>
Sat, 24 Nov 2007 19:12:15 +0000 (19:12 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44304 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/SelectionDAG/LegalizeDAG.cpp

index aa8ffaae071146bdc74eb5a11bdf67214421e81c..30b55156c2660765140780558a4824ccbc7f40e6 100644 (file)
@@ -5401,6 +5401,10 @@ void SelectionDAGLegalize::ExpandOp(SDOperand Op, SDOperand &Lo, SDOperand &Hi){
     break;
       
   case ISD::MERGE_VALUES:
+    if (Node->getNumValues() == 1) {
+      ExpandOp(Op.getOperand(0), Lo, Hi);
+      break;
+    }
     // FIXME: For now only expand i64,chain = MERGE_VALUES (x, y)
     assert(Op.ResNo == 0 && Node->getNumValues() == 2 &&
            Op.getValue(1).getValueType() == MVT::Other &&