[llvm] [AArch64] Consider streaming mode in TTI interfaces for vectorization. (PR #96305)

Sander de Smalen via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 24 03:04:37 PDT 2024


================
@@ -2162,19 +2162,20 @@ AArch64TTIImpl::getRegisterBitWidth(TargetTransformInfo::RegisterKind K) const {
   case TargetTransformInfo::RGK_Scalar:
     return TypeSize::getFixed(64);
   case TargetTransformInfo::RGK_FixedWidthVector:
-    if (!ST->isNeonAvailable() && !EnableFixedwidthAutovecInStreamingMode)
-      return TypeSize::getFixed(0);
-
-    if (ST->hasSVE())
+    if (ST->useSVEForFixedLengthVectors() &&
+        (ST->isSVEAvailable() || EnableFixedwidthAutovecInStreamingMode))
       return TypeSize::getFixed(
           std::max(ST->getMinSVEVectorSizeInBits(), 128u));
----------------
sdesmalen-arm wrote:

That's a good point, we'll need to fix this. To make this work for streaming-SVE functions, do we need a change to the ACLE itself as well?

https://github.com/llvm/llvm-project/pull/96305


More information about the llvm-commits mailing list