Issue |
157997
|
Summary |
AMDGPU asserts on LowerFormalArguments emitted a value with the wrong type with -debug-_only_=isel
|
Labels |
backend:AMDGPU,
crash-on-valid
|
Assignees |
|
Reporter |
arsenm
|
```
; RUN: llc -mcpu=gfx900 -debug-_only_=isel < %s
; Crashes with -debug-_only_=isel
target triple = "amdgcn-amd-amdhsa"
define ptr addrspace(1) @arg_crash(ptr addrspace(1) %sd, ptr %stack, <4 x i32> %node, ptr %offset, i32 %0, i8 %trunc, float %1, float %2, float %mul80, i1 %cmp412.old, <4 x i32> %3, float %4, i32 %5, i1 %cmp442, i1 %or.cond1306, float %.op, ptr addrspace(1) %arrayidx.i.i2202, ptr addrspace(1) %retval.0.i.i22089, ptr addrspace(1) %retval.1.i221310, i1 %cmp575) {
entry:
ret ptr addrspace(1) %sd
}
```
Hits:
```
# | === arg_crash
# | Assertion failed: (EVT(Ins[i].VT) == InVals[i].getValueType() && "LowerFormalArguments emitted a value with the wrong type!"), function LowerArguments, file SelectionDAGBuilder.cpp, line 11851.
# | 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: /Users/matt/src/llvm-project/build_rel_with_debinfo/bin/llc -mcpu=gfx900 -debug-_only_=isel
# | 1. Running pass 'CallGraph Pass Manager' on module '<stdin>'.
# | 2. Running pass 'AMDGPU DAG->DAG Pattern Instruction Selection' on function '@arg_crash'
# | #0 0x00000001068eb944 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (/Users/matt/src/llvm-project/build_rel_with_debinfo/bin/llc+0x1025cf944)
# | #1 0x00000001068e9ac8 llvm::sys::RunSignalHandlers() (/Users/matt/src/llvm-project/build_rel_with_debinfo/bin/llc+0x1025cdac8)
# | #2 0x00000001068ec3f8 SignalHandler(int, __siginfo*, void*) (/Users/matt/src/llvm-project/build_rel_with_debinfo/bin/llc+0x1025d03f8)
# | #3 0x0000000185500624 (/usr/lib/system/libsystem_platform.dylib+0x1804ac624)
# | #4 0x00000001854c688c (/usr/lib/system/libsystem_pthread.dylib+0x18047288c)
# | #5 0x00000001853cfc60 (/usr/lib/system/libsystem_c.dylib+0x18037bc60)
# | #6 0x00000001853ceeec (/usr/lib/system/libsystem_c.dylib+0x18037aeec)
# | #7 0x00000001075dba38 llvm::SelectionDAGISel::LowerArguments(llvm::Function const&) (.cold.26) (/Users/matt/src/llvm-project/build_rel_with_debinfo/bin/llc+0x1032bfa38)
# | #8 0x0000000106759bf4 llvm::SelectionDAGISel::LowerArguments(llvm::Function const&) (/Users/matt/src/llvm-project/build_rel_with_debinfo/bin/llc+0x10243dbf4)
# | #9 0x00000001067b4bc0 llvm::SelectionDAGISel::SelectAllBasicBlocks(llvm::Function const&) (/Users/matt/src/llvm-project/build_rel_with_debinfo/bin/llc+0x102498bc0)
# | #10 0x00000001067b3af8 llvm::SelectionDAGISel::runOnMachineFunction(llvm::MachineFunction&) (/Users/matt/src/llvm-project/build_rel_with_debinfo/bin/llc+0x102497af8)
```
I encountered this on llvm/test/CodeGen/AMDGPU/ipra-return-address-save-restore.ll
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs