From 87421c86587204a91cdce12e2e249dbeb4c6ed8e Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Sun, 28 Aug 2005 23:59:36 +0000 Subject: Fix a bug in ReplaceAllUsesWith llvm-svn: 23122 --- llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'llvm/lib/CodeGen/SelectionDAG') diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp index 43163151049..b47002f1165 100644 --- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp @@ -2084,7 +2084,7 @@ void SelectionDAG::ReplaceAllUsesWith(SDNode *From, const std::vector &To) { assert(From->getNumValues() == To.size() && "Incorrect number of values to replace with!"); - if (To.size() == 1) { + if (To.size() == 1 && To[0].Val->getNumValues() == 1) { // Degenerate case handled above. ReplaceAllUsesWith(SDOperand(From, 0), To[0]); return; -- cgit v1.2.3