[Mlir-commits] [mlir] [mlir][ArmSVE] Add convert_to/from_svbool ops (PR #68586)

Andrzej WarzyƄski llvmlistbot at llvm.org
Wed Oct 11 08:28:20 PDT 2023


================
@@ -37,6 +37,19 @@ def IsFixedVectorTypePred : CPred<[{::llvm::isa<::mlir::VectorType>($_self) &&
 def IsScalableVectorTypePred : CPred<[{::llvm::isa<::mlir::VectorType>($_self) &&
                                    ::llvm::cast<VectorType>($_self).isScalable()}]>;
 
+// Whether a type is a scalable VectorType, with a single trailing scalable dimension.
+// Examples:
+// Valid:
+//   - vector<[4]xf32>, vector<2x3x[2]xi64>, vector<32x[8]xi32>
+// Invalid
+//   - vector<[4]x8xi32>, vector<[2]x[2]xf64>, vector<2x[8]x4xi32>
+def IsOnlyTrailingDimScalablePred : And<[
----------------
banach-space wrote:

[nit] "IsOnlyTrailingDimScalablePred" --> "IsVectorTypeWithOnlyTrailingDimScalablePred"

I think that this would be more consistent with other predicates and also more informative. Bit of a mouthful, but it's a rather non-trivial predicate.

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


More information about the Mlir-commits mailing list