[PATCH] D157425: [TTI]Add InsertSubvector pattern in improveShuffleKindFromMask().

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 15 03:50:15 PDT 2023


RKSimon added inline comments.


================
Comment at: llvm/include/llvm/CodeGen/BasicTTIImpl.h:937
+                                              int &Index,
+                                              VectorType *&SubTp) const {
     int Limit = Mask.size() * 2;
----------------
VectorType *&SubTy


================
Comment at: llvm/include/llvm/CodeGen/BasicTTIImpl.h:955
+                                                   NumSubElts, Index)) {
+        SubTp = FixedVectorType::get(Ty, NumSubElts);
+        return TTI::SK_InsertSubvector;
----------------
Probably better to pass the whole Vector/Result and then use:
```
SubTy = FixedVectorType::get(Ty->getElementType(), NumSubElts);
```


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D157425



More information about the llvm-commits mailing list