[llvm] r312856 - [X86] Use ReplaceNode instead of ReplaceUses when converting X86ISD::SHRUNKBLEND to ISD::VSELECT during isel.
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 8 22:57:20 PDT 2017
Author: ctopper
Date: Fri Sep 8 22:57:19 2017
New Revision: 312856
URL: http://llvm.org/viewvc/llvm-project?rev=312856&view=rev
Log:
[X86] Use ReplaceNode instead of ReplaceUses when converting X86ISD::SHRUNKBLEND to ISD::VSELECT during isel.
This ensures that the SHRUNKBLEND node gets erased immediately.
Modified:
llvm/trunk/lib/Target/X86/X86ISelDAGToDAG.cpp
Modified: llvm/trunk/lib/Target/X86/X86ISelDAGToDAG.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86ISelDAGToDAG.cpp?rev=312856&r1=312855&r2=312856&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86ISelDAGToDAG.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86ISelDAGToDAG.cpp Fri Sep 8 22:57:19 2017
@@ -2326,7 +2326,7 @@ void X86DAGToDAGISel::Select(SDNode *Nod
SDValue VSelect = CurDAG->getNode(
ISD::VSELECT, SDLoc(Node), Node->getValueType(0), Node->getOperand(0),
Node->getOperand(1), Node->getOperand(2));
- ReplaceUses(SDValue(Node, 0), VSelect);
+ ReplaceNode(Node, VSelect.getNode());
SelectCode(VSelect.getNode());
// We already called ReplaceUses.
return;
More information about the llvm-commits
mailing list