[PATCH] D142116: [Cost] Add CostKind to getVectorInstrCost and its related users

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 19 09:49:00 PST 2023


craig.topper added inline comments.


================
Comment at: llvm/include/llvm/CodeGen/BasicTTIImpl.h:1677
+        ScalarizationCost += getScalarizationOverhead(cast<VectorType>(RetTy),
+                                                      true, false, CostKind);
       ScalarizationCost +=
----------------
Mind labeling the `true` and `false` parameters while you're here? Should be the same as line 1441.


================
Comment at: llvm/include/llvm/CodeGen/BasicTTIImpl.h:1732
+          ScalarizationCost =
+              getScalarizationOverhead(RetVTy, true, false, CostKind);
         ScalarCalls = std::max(ScalarCalls,
----------------
Label and the true and false


================
Comment at: llvm/include/llvm/CodeGen/BasicTTIImpl.h:1743
+            ScalarizationCost +=
+                getScalarizationOverhead(VTy, false, true, CostKind);
           ScalarCalls = std::max(ScalarCalls,
----------------
Label the true and false


================
Comment at: llvm/include/llvm/CodeGen/BasicTTIImpl.h:2155
+              ? ScalarizationCostPassed
+              : getScalarizationOverhead(RetVTy, true, false, CostKind);
 
----------------
Label the true and false


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D142116



More information about the llvm-commits mailing list