summaryrefslogtreecommitdiff
path: root/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
diff options
context:
space:
mode:
authorAndrzej WarzyƄski <andrzej.warzynski@arm.com>2025-09-15 08:35:03 +0100
committerGitHub <noreply@github.com>2025-09-15 08:35:03 +0100
commit0ee7c9434a4745a10cb68217134a356b63a346f9 (patch)
tree593e2c02acd2e7a633c7d42922972154a8f62f5b /mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
parent3371375131c645bb579323b60e92f2b0f9079f24 (diff)
[mlir][vector] Tidy-up testing for to/from_elements unrolling (#158309)
1. Remove `TestUnrollVectorToElements` and `TestUnrollVectorFromElements` test passes - these are not required. 2. Make "vector-from-elements-lowering.mlir" use TD Op for testing (for consistency "vector-to-elements-lowering.mlir" and to make sure that the TD Op, `transform.apply_patterns.vector.unroll_from_elements`, is tested). 3. Unify `CHECK` prefixes (`CHECK-UNROLL` -> `CHECK`). 4. Rename `@to_elements_1d` as `@negative_unroll_to_elements_1d`, for consistency with it's counterpart for `vector.from_elements` and to align with our testing guide (*). (*) https://mlir.llvm.org/getting_started/TestingGuide/#after-step-3-add-the-newly-identified-missing-case
Diffstat (limited to 'mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp')
-rw-r--r--mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp48
1 files changed, 0 insertions, 48 deletions
diff --git a/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp b/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
index c2d184626818..3360f3b70a81 100644
--- a/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
+++ b/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
@@ -756,50 +756,6 @@ struct TestVectorGatherLowering
}
};
-struct TestUnrollVectorFromElements
- : public PassWrapper<TestUnrollVectorFromElements,
- OperationPass<func::FuncOp>> {
- MLIR_DEFINE_EXPLICIT_INTERNAL_INLINE_TYPE_ID(TestUnrollVectorFromElements)
-
- StringRef getArgument() const final {
- return "test-unroll-vector-from-elements";
- }
- StringRef getDescription() const final {
- return "Test unrolling patterns for from_elements ops";
- }
- void getDependentDialects(DialectRegistry &registry) const override {
- registry.insert<func::FuncDialect, vector::VectorDialect, ub::UBDialect>();
- }
-
- void runOnOperation() override {
- RewritePatternSet patterns(&getContext());
- populateVectorFromElementsLoweringPatterns(patterns);
- (void)applyPatternsGreedily(getOperation(), std::move(patterns));
- }
-};
-
-struct TestUnrollVectorToElements
- : public PassWrapper<TestUnrollVectorToElements,
- OperationPass<func::FuncOp>> {
- MLIR_DEFINE_EXPLICIT_INTERNAL_INLINE_TYPE_ID(TestUnrollVectorToElements)
-
- StringRef getArgument() const final {
- return "test-unroll-vector-to-elements";
- }
- StringRef getDescription() const final {
- return "Test unrolling patterns for to_elements ops";
- }
- void getDependentDialects(DialectRegistry &registry) const override {
- registry.insert<func::FuncDialect, vector::VectorDialect>();
- }
-
- void runOnOperation() override {
- RewritePatternSet patterns(&getContext());
- populateVectorToElementsLoweringPatterns(patterns);
- (void)applyPatternsGreedily(getOperation(), std::move(patterns));
- }
-};
-
struct TestFoldArithExtensionIntoVectorContractPatterns
: public PassWrapper<TestFoldArithExtensionIntoVectorContractPatterns,
OperationPass<func::FuncOp>> {
@@ -1071,10 +1027,6 @@ void registerTestVectorLowerings() {
PassRegistration<TestVectorGatherLowering>();
- PassRegistration<TestUnrollVectorFromElements>();
-
- PassRegistration<TestUnrollVectorToElements>();
-
PassRegistration<TestFoldArithExtensionIntoVectorContractPatterns>();
PassRegistration<TestVectorEmulateMaskedLoadStore>();