[PATCH] D57059: [SLP] Initial support for the vectorization of the non-power-of-2 vectors.

Sanjay Patel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 23 07:18:02 PDT 2020


spatel added inline comments.


================
Comment at: llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp:7432
+    for (unsigned I = 0, E = ExtraArgs.size(); I < E; ++I, ++It) {
+      Args[I] = It->second;
+    }
----------------
Is it necessary to copy these? If so, it would be better to name this function something like "getCopyOfExtraArgValues" to make that explicit.

If not, we can just make this a standard 'get' method:
  const MapVector<Instruction *, Value *> &getExtraArgs() const {
    return ExtraArgs;
  }

And then access the 'second' data in the user code?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D57059



More information about the llvm-commits mailing list