[PATCH] D57779: [SLP] Add support for throttling.

Dinar Temirbulatov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Aug 31 19:32:03 PDT 2019


dtemirbulatov marked 2 inline comments as done.
dtemirbulatov added inline comments.


================
Comment at: lib/Transforms/Vectorize/SLPVectorizer.cpp:2949
+void BoUpSLP::recordSeeds(ArrayRef<Value *> Ops) {
+  Seeds.push_back(SmallVector<Value *, 8>(Ops.begin(), Ops.end()));
+}
----------------
ABataev wrote:
> `emplace_back(Ops.begin(), Ops.end())`?
Hmm, it does not work out of ArrayRef without specifying the constructor.


================
Comment at: lib/Transforms/Vectorize/SLPVectorizer.cpp:3764-3765
+    if (!TE.NeedToGather) {
+      for (Value *V : TE.Scalars)
+        ScalarsToVec.insert(V);
+    }
----------------
ABataev wrote:
> Use `llvm::copy`
I could not use llvm::copy here since Scalars is SmallVector and ScalarsToVec declared as SmallPtrSet type.


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

https://reviews.llvm.org/D57779





More information about the llvm-commits mailing list