| Issue |
178230
|
| Summary |
mlir-opt crashes on arith.select with mixed scalar and vector/tile types
|
| Labels |
new issue
|
| Assignees |
|
| Reporter |
mlirBug
|
mlir-opt version: 22.1.0-rc1
mlir-opt crashes with an assertion failure when running `arith.select` on operands that involve a combination of scalar, vector, and AMX tile types. The internal pass casts one of the operands to `ShapedType`, which fails and triggers a hard abort.
```
module {
func.func @main() {
%0 = vector.vscale
%1 = vector.constant_mask [1] : vector<1xi1>
%2 = amx.tile_zero : !amx.tile<16x16xi8>
%3 = arith.index_castui %0 : index to i32
%4 = arith.select %1, %3, %3 : vector<1xi1>, i32
return
}
}
```
```
mlir-opt test.mlir
```
```
mlir-opt: llvm-project-llvmorg-22.1.0-rc1/llvm/include/llvm/Support/Casting.h:560: decltype(auto) llvm::cast(const From&) [with To = mlir::ShapedType; From = mlir::Type]: Assertion `isa<To>(Val) && "cast<Ty>() argument of incompatible type!"' failed.
PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace and instructions to reproduce the bug.
Stack dump:
0. Program arguments: llvmorg-22.1.0-install/bin/mlir-opt test.mlir
#0 0x00005867a97f2e32 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (llvmorg-22.1.0-install/bin/mlir-opt+0x252fe32)
#1 0x00005867a97ef5af llvm::sys::RunSignalHandlers() (llvmorg-22.1.0-install/bin/mlir-opt+0x252c5af)
#2 0x00005867a97ef6fc SignalHandler(int, siginfo_t*, void*) Signals.cpp:0:0
#3 0x000076ea2f645330 (/lib/x86_64-linux-gnu/libc.so.6+0x45330)
#4 0x000076ea2f69eb2c __pthread_kill_implementation ./nptl/pthread_kill.c:44:76
#5 0x000076ea2f69eb2c __pthread_kill_internal ./nptl/pthread_kill.c:78:10
#6 0x000076ea2f69eb2c pthread_kill ./nptl/pthread_kill.c:89:10
#7 0x000076ea2f64527e raise ./signal/../sysdeps/posix/raise.c:27:6
#8 0x000076ea2f6288ff abort ./stdlib/abort.c:81:7
#9 0x000076ea2f62881b _nl_load_domain ./intl/loadmsgcat.c:1177:9
#10 0x000076ea2f63b517 (/lib/x86_64-linux-gnu/libc.so.6+0x3b517)
```
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs