diff options
author | Chris Lattner <sabre@nondot.org> | 2010-02-23 23:01:35 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-02-23 23:01:35 +0000 |
commit | 5857e0add8ab25825628d1ef19cec027e605dcd5 (patch) | |
tree | 36145a77c8e44eaf5366c8fb50e319021ad9736b /lib/CodeGen/SelectionDAG/SelectionDAG.cpp | |
parent | 450986db9607b1444cb50740fa4c102f20f92f6b (diff) |
make selectnodeto set the nodeid to -1. This makes it more akin to
creating a new node then replacing uses.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@97000 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SelectionDAG/SelectionDAG.cpp')
-rw-r--r-- | lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/lib/CodeGen/SelectionDAG/SelectionDAG.cpp index e67135028f..f5e7000167 100644 --- a/lib/CodeGen/SelectionDAG/SelectionDAG.cpp +++ b/lib/CodeGen/SelectionDAG/SelectionDAG.cpp @@ -4553,7 +4553,10 @@ SDNode *SelectionDAG::SelectNodeTo(SDNode *N, unsigned MachineOpc, SDNode *SelectionDAG::SelectNodeTo(SDNode *N, unsigned MachineOpc, SDVTList VTs, const SDValue *Ops, unsigned NumOps) { - return MorphNodeTo(N, ~MachineOpc, VTs, Ops, NumOps); + N = MorphNodeTo(N, ~MachineOpc, VTs, Ops, NumOps); + // Reset the NodeID to -1. + N->setNodeId(-1); + return N; } SDNode *SelectionDAG::MorphNodeTo(SDNode *N, unsigned Opc, |