[PATCH] D56740: [SelectionDAG] Split very large token factors for chained stores to 64k chunks.

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 15 12:03:49 PST 2019


fhahn created this revision.
fhahn added reviewers: efriedma, craig.topper, aemerson, RKSimon.
Herald added a subscriber: hiraditya.
fhahn added a parent revision: D56739: [SelectionDAG] Add splitAcrossTokenFactors to split nodes with > 64k operands..

Similar to D55073 <https://reviews.llvm.org/D55073>. Without this change, the DAG combiner crashes on code
with more than 64k of stores in a single basic block that form parallelizable 
chains.

No test case, as it would be very IR file.


https://reviews.llvm.org/D56740

Files:
  llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp


Index: llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
===================================================================
--- llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
+++ llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
@@ -19278,6 +19278,7 @@
   if (AddNewChain)
     TFOps.insert(TFOps.begin(), NewChain);
 
+  DAG.splitAcrossTokenFactors(SDLoc(STChain), TFOps);
   SDValue TF = DAG.getNode(ISD::TokenFactor, SDLoc(STChain), MVT::Other, TFOps);
   CombineTo(St, TF);
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D56740.181847.patch
Type: text/x-patch
Size: 472 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190115/42c69066/attachment.bin>


More information about the llvm-commits mailing list