[PATCH] D105053: [INSTCOMBINE] Transform reduction(shuffle V, poison, unique_mask) to reduction(V).

Alexey Bataev via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 28 13:27:54 PDT 2021


ABataev added inline comments.


================
Comment at: llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp:2014
+        SmallBitVector UsedIndeces(Mask.size());
+        for (int Idx : Mask) {
+          if (Idx == UndefMaskElem || UsedIndeces.test(Idx))
----------------
lebedev.ri wrote:
> ABataev wrote:
> > lebedev.ri wrote:
> > > This doesn't deal with non-canonical shuffle variant properly (and the test is missing)
> > > 
> > > 
> > What do you mean by `non-canonical shuffle`?
> `match(Arg, m_Shuffle(m_Undef(), m_Value(V), m_Mask(Mask)))`
Ah, yes, will fix it, thanks!


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D105053



More information about the llvm-commits mailing list