[PATCH] D144770: [SLP] Outline GEP chain cost modeling into new TTI interface - NFCI.

Alexey Bataev via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 1 06:12:53 PST 2023


ABataev added inline comments.


================
Comment at: llvm/include/llvm/Analysis/TargetTransformInfoImpl.h:1029
+                                       TTI::TargetCostKind CostKind) {
+    InstructionCost Cost = TTI::TCC_Free;
+
----------------
Add an assert that all geps are from the same basic block?


================
Comment at: llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp:7161
+    // loads/stores are known to be from/to adjacent locations.
+    if (isa<LoadInst, StoreInst>(VL0)) {
+      // Case 2: estimate costs for pointer related costs when vectorizing to
----------------
What if it is scatter vectorize node? VL0 still should be LoadInst.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D144770



More information about the llvm-commits mailing list