[llvm] r372327 - [DAGCombiner] Add node to the worklist in topological order in scalarizeExtractedVectorLoad
Amaury Sechet via llvm-commits
llvm-commits at lists.llvm.org
Thu Sep 19 07:22:11 PDT 2019
Author: deadalnix
Date: Thu Sep 19 07:22:11 2019
New Revision: 372327
URL: http://llvm.org/viewvc/llvm-project?rev=372327&view=rev
Log:
[DAGCombiner] Add node to the worklist in topological order in scalarizeExtractedVectorLoad
Summary: As per title.
Reviewers: craig.topper, efriedma, RKSimon, lebedev.ri
Subscribers: llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D66661
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp?rev=372327&r1=372326&r2=372327&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp Thu Sep 19 07:22:11 2019
@@ -16845,12 +16845,12 @@ SDValue DAGCombiner::scalarizeExtractedV
SDValue From[] = { SDValue(EVE, 0), SDValue(OriginalLoad, 1) };
SDValue To[] = { Load, Chain };
DAG.ReplaceAllUsesOfValuesWith(From, To, 2);
+ // Make sure to revisit this node to clean it up; it will usually be dead.
+ AddToWorklist(EVE);
// Since we're explicitly calling ReplaceAllUses, add the new node to the
// worklist explicitly as well.
- AddToWorklist(Load.getNode());
AddUsersToWorklist(Load.getNode()); // Add users too
- // Make sure to revisit this node to clean it up; it will usually be dead.
- AddToWorklist(EVE);
+ AddToWorklist(Load.getNode());
++OpsNarrowed;
return SDValue(EVE, 0);
}
More information about the llvm-commits
mailing list