Skip to content

Commit a8998fa

Browse files
authored
[mlir][vector][nfc] Move vector.splat test (#145699)
Moves a test for vector.splat so that all invalid tests are grouped together and easy to find.
1 parent 7289b67 commit a8998fa

File tree

1 file changed

+12
-7
lines changed

1 file changed

+12
-7
lines changed

mlir/test/Dialect/Vector/invalid.mlir

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1667,13 +1667,6 @@ func.func @scan_unsupported_kind(%arg0: vector<2x3xf32>, %arg1: vector<3xf32>) -
16671667
return %0#0 : vector<2x3xf32>
16681668
}
16691669

1670-
// -----
1671-
1672-
func.func @invalid_splat(%v : f32) {
1673-
// expected-error@+1 {{invalid kind of type specified: expected builtin.vector, but found 'memref<8xf32>'}}
1674-
vector.splat %v : memref<8xf32>
1675-
return
1676-
}
16771670

16781671
// -----
16791672

@@ -1973,6 +1966,18 @@ func.func @flat_transpose_scalable(%arg0: vector<[16]xf32>) -> vector<[16]xf32>
19731966
return %0 : vector<[16]xf32>
19741967
}
19751968

1969+
//===----------------------------------------------------------------------===//
1970+
// vector.splat
1971+
//===----------------------------------------------------------------------===//
1972+
1973+
// -----
1974+
1975+
func.func @vector_splat_invalid_result(%v : f32) {
1976+
// expected-error@+1 {{invalid kind of type specified: expected builtin.vector, but found 'memref<8xf32>'}}
1977+
vector.splat %v : memref<8xf32>
1978+
return
1979+
}
1980+
19761981
// -----
19771982

19781983
// expected-note @+1 {{prior use here}}

0 commit comments

Comments
 (0)