[PATCH] D50827: [DAGCombiner] Don't reassociate operations that have the vector reduction flag set.

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 16 11:09:31 PDT 2018


craig.topper added inline comments.


================
Comment at: lib/CodeGen/SelectionDAG/DAGCombiner.cpp:953-954
+    // Don't reassociate reductions.
+    if (N0->getFlags().hasVectorReduction())
+      return SDValue();
+
----------------
spatel wrote:
> Not sure if this is possible: what if the root node and N1 do not have the reduction flag set? In that case, we want to allow the 'if' clause at line 975 to fire even though N0 has the reduction flag set rather than bailing out?
Oops. I'll fix that.


https://reviews.llvm.org/D50827





More information about the llvm-commits mailing list