[llvm] [SLP]Improved reduction cost/codegen (PR #118293)
Alexey Bataev via llvm-commits
llvm-commits at lists.llvm.org
Mon Jan 27 10:11:33 PST 2025
================
@@ -2710,6 +2710,23 @@ class BasicTTIImplBase : public TargetTransformInfoImplCRTPBase<T> {
return *LT.first.getValue();
}
+ bool isFullSingleRegisterType(Type *Tp) const {
+ std::pair<InstructionCost, MVT> LT = getTypeLegalizationCost(Tp);
+ if (!LT.first.isValid() || LT.first > 1)
+ return false;
+
+ if (auto *FTp = dyn_cast<FixedVectorType>(Tp);
+ Tp && LT.second.isFixedLengthVector()) {
----------------
alexey-bataev wrote:
Misprint, must be `FTp`
https://github.com/llvm/llvm-project/pull/118293
More information about the llvm-commits
mailing list