[PATCH] D121187: [DAGCombiner][VP] Add DAGCombine for VP_MUL.

Simon Moll via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 11 08:15:03 PST 2022


simoll added inline comments.


================
Comment at: llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp:22807
+
+  // fold vp_mul X, (splat 0), Mask, EVL -> vp_select Mask, undef, (splat 0),
+  // EVL
----------------
craig.topper wrote:
> If one of the true/false values of the VP_SELECT is undef can we ignore the mask and EVL and return the other operand? @simoll @frasercrmck
I believe so. Also for vp ops other than select or merge, if the mask is undef, we can scratch the operation entirely. If evl is undef, we can cut short to `unreachable`.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D121187/new/

https://reviews.llvm.org/D121187



More information about the llvm-commits mailing list