mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-10 22:46:25 +00:00
don't add flag nodes with chain results to the NowDeadNodes
list multiple times when MorphNodeTo can't be applied. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@99735 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
ec243474bc
commit
19e37cbf4f
@ -1614,8 +1614,9 @@ UpdateChainsAndFlags(SDNode *NodeToMatch, SDValue InputChain,
|
||||
CurDAG->ReplaceAllUsesOfValueWith(SDValue(FRN, FRN->getNumValues()-1),
|
||||
InputFlag, &ISU);
|
||||
|
||||
// If the node became dead, delete it.
|
||||
if (FRN->use_empty())
|
||||
// If the node became dead and we haven't already seen it, delete it.
|
||||
if (FRN->use_empty() &&
|
||||
!std::count(NowDeadNodes.begin(), NowDeadNodes.end(), FRN))
|
||||
NowDeadNodes.push_back(FRN);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user