[PATCH] D103458: [SLP]Improve gathering of scalar elements.

Guozhi Wei via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 30 15:17:30 PDT 2021


Carrot added inline comments.


================
Comment at: llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp:4841
+    // No need to insert undefs elements - exit.
+    if (isa<UndefValue>(V))
+      return Vec;
----------------
The problem is here.

An undef value can be a correct value. But a poison always means something is wrong. In line 4866 you created a poison value as default, an undef should overwrite the default poison value.



Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D103458



More information about the llvm-commits mailing list