[llvm] r320365 - [DAGCombiner] Add combined indexed load to the work list

Nemanja Ivanovic via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 11 06:16:02 PST 2017


Author: nemanjai
Date: Mon Dec 11 06:16:02 2017
New Revision: 320365

URL: http://llvm.org/viewvc/llvm-project?rev=320365&view=rev
Log:
[DAGCombiner] Add combined indexed load to the work list

This commit is the first part of https://reviews.llvm.org/D40348.
In order to allow target combines to be performed on newly combined
indexed loads, add them back to the worklist. The remainder of the
above patch will be committed in subsequent revisions and will use
this. Test cases will be included with those follow-up commits.


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=320365&r1=320364&r2=320365&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp Mon Dec 11 06:16:02 2017
@@ -11380,6 +11380,7 @@ bool DAGCombiner::CombineToPreIndexedLoa
   // Replace the uses of Ptr with uses of the updated base value.
   DAG.ReplaceAllUsesOfValueWith(Ptr, Result.getValue(isLoad ? 1 : 0));
   deleteAndRecombine(Ptr.getNode());
+  AddToWorklist(Result.getNode());
 
   return true;
 }




More information about the llvm-commits mailing list