| Issue |
177846
|
| Summary |
mlir-opt --xegpu-propagate-layout crashes when module contains llvm.func declaration
|
| Labels |
new issue
|
| Assignees |
|
| Reporter |
Subway2023
|
# Description
mlir-opt version: 22.1.0-rc1
Running mlir-opt with the --xegpu-propagate-layout pass crashes if the MLIR module contains an llvm.func declaration, even if the rest of the operations are valid. Commenting out the llvm.func declaration prevents the crash. The crash happens during an LLVM type cast and seems unrelated to the other operations in the function.
# Reproduce
location: If the **llvm.func** is commented out, the crash no longer occurs.
```mlir
module {
llvm.func @some_function()
}
```
```
mlir-opt --xegpu-propagate-layout test.mlir
```
```
mlir-opt: /mnt/sdd1/mlir/tool/llvm-project-llvmorg-22.1.0-rc1/llvm/include/llvm/Support/Casting.h:560: decltype(auto) llvm::cast(const From&) [with To = mlir::LLVM::LLVMFunctionType; 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: /mnt/sdd1/sbw/mlir/tool/llvmorg-22.1.0-install/bin/mlir-opt --xegpu-propagate-layout /mnt/sdd1/sbw/mlir/data/genProgram_1229/290349_c830/mlir_steps/290349_c830_5.mlir
#0 0x000058cc2ca13e32 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (/mnt/sdd1/sbw/mlir/tool/llvmorg-22.1.0-install/bin/mlir-opt+0x252fe32)
#1 0x000058cc2ca105af llvm::sys::RunSignalHandlers() (/mnt/sdd1/sbw/mlir/tool/llvmorg-22.1.0-install/bin/mlir-opt+0x252c5af)
#2 0x000058cc2ca106fc SignalHandler(int, siginfo_t*, void*) Signals.cpp:0:0
#3 0x0000720354445330 (/lib/x86_64-linux-gnu/libc.so.6+0x45330)
#4 0x000072035449eb2c __pthread_kill_implementation ./nptl/pthread_kill.c:44:76
#5 0x000072035449eb2c __pthread_kill_internal ./nptl/pthread_kill.c:78:10
#6 0x000072035449eb2c pthread_kill ./nptl/pthread_kill.c:89:10
#7 0x000072035444527e raise ./signal/../sysdeps/posix/raise.c:27:6
#8 0x00007203544288ff abort ./stdlib/abort.c:81:7
#9 0x000072035442881b _nl_load_domain ./intl/loadmsgcat.c:1177:9
#10 0x000072035443b517 (/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