<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/68068>68068</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[X86][FastISel] assertion converting i15 to float with avx512f feature
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
jacobly0
</td>
</tr>
</table>
<pre>
```llvm
target triple = "x86_64"
define float @f() "target-features"="+avx512f" { ; no assertion when disabled
%1 = uitofp i15 poison to float
ret float %1
}
```
```
$ llc --version # 33e14ecd6aac8c61c055921dd6e564d170fe34d6
LLVM (http://llvm.org/):
LLVM version 17.0.2
DEBUG build with assertions.
$ llc -fast-isel=1 repro.ll
llc: llvm/include/llvm/CodeGen/ValueTypes.h:300: MVT llvm::EVT::getSimpleVT() const: Assertion `isSimple() && "Expected a SimpleValueType!"' failed.
PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace.
Stack dump:
0. Program arguments: llc -fast-isel=1 repro.ll
1. Running pass 'Function Pass Manager' on module 'repro.ll'.
2. Running pass 'X86 DAG->DAG Instruction Selection' on function '@f'
#0 0x00007f192b811b36 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) llvm/lib/Support/Unix/Signals.inc:602:11
#1 0x00007f192b81208b PrintStackTraceSignalHandler(void*) llvm/lib/Support/Unix/Signals.inc:675:1
#2 0x00007f192b810233 llvm::sys::RunSignalHandlers() llvm/lib/Support/Signals.cpp:104:5
#3 0x00007f192b812771 SignalHandler(int) llvm/lib/Support/Unix/Signals.inc:413:1
#4 0x00007f192b05ec90 (/usr/lib64/libc.so.6+0x39c90)
#5 0x00007f192b0af1ec (/usr/lib64/libc.so.6+0x8a1ec)
#6 0x00007f192b05ebe2 gsignal (/usr/lib64/libc.so.6+0x39be2)
#7 0x00007f192b0474ed abort (/usr/lib64/libc.so.6+0x224ed)
#8 0x00007f192b047415 (/usr/lib64/libc.so.6+0x22415)
#9 0x00007f192b057542 (/usr/lib64/libc.so.6+0x32542)
#10 0x00007f1932f7fae9 llvm::EVT::getSimpleVT() const llvm/include/llvm/CodeGen/ValueTypes.h:0:7
#11 0x00007f1932f811f0 llvm::TargetLoweringBase::getSimpleValueType(llvm::DataLayout const&, llvm::Type*, bool) const llvm/include/llvm/CodeGen/TargetLowering.h:1569:47
#12 0x00007f1932f02713 (anonymous namespace)::X86FastISel::X86SelectIntToFP(llvm::Instruction const*, bool) llvm/lib/Target/X86/X86FastISel.cpp:2394:19
#13 0x00007f1932efd3cf (anonymous namespace)::X86FastISel::X86SelectUIToFP(llvm::Instruction const*) llvm/lib/Target/X86/X86FastISel.cpp:2441:3
#14 0x00007f1932eebf03 (anonymous namespace)::X86FastISel::fastSelectInstruction(llvm::Instruction const*) llvm/lib/Target/X86/X86FastISel.cpp:3665:5
#15 0x00007f192fc5e403 llvm::FastISel::selectInstruction(llvm::Instruction const*) llvm/lib/CodeGen/SelectionDAG/FastISel.cpp:1559:7
#16 0x00007f192ff73a5a llvm::SelectionDAGISel::SelectAllBasicBlocks(llvm::Function const&) llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp:1578:13
#17 0x00007f192ff71990 llvm::SelectionDAGISel::runOnMachineFunction(llvm::MachineFunction&) llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp:482:3
#18 0x00007f1933002ca7 (anonymous namespace)::X86DAGToDAGISel::runOnMachineFunction(llvm::MachineFunction&) llvm/lib/Target/X86/X86ISelDAGToDAG.cpp:192:7
#19 0x00007f192f21358c llvm::MachineFunctionPass::runOnFunction(llvm::Function&) llvm/lib/CodeGen/MachineFunctionPass.cpp:91:8
#20 0x00007f192c4e2b85 llvm::FPPassManager::runOnFunction(llvm::Function&) llvm/lib/IR/LegacyPassManager.cpp:1435:23
#21 0x00007f192c4e80bf llvm::FPPassManager::runOnModule(llvm::Module&) llvm/lib/IR/LegacyPassManager.cpp:1481:16
#22 0x00007f192c4e34fb (anonymous namespace)::MPPassManager::runOnModule(llvm::Module&) llvm/lib/IR/LegacyPassManager.cpp:1550:23
#23 0x00007f192c4e300a llvm::legacy::PassManagerImpl::run(llvm::Module&) llvm/lib/IR/LegacyPassManager.cpp:535:16
#24 0x00007f192c4e83c1 llvm::legacy::PassManager::run(llvm::Module&) llvm/lib/IR/LegacyPassManager.cpp:1677:3
#25 0x0000564d056cce4f compileModule(char**, llvm::LLVMContext&) llvm/tools/llc/llc.cpp:754:41
#26 0x0000564d056cb0b5 main llvm/tools/llc/llc.cpp:416:13
#27 0x00007f192b048eea (/usr/lib64/libc.so.6+0x23eea)
#28 0x00007f192b048fa5 __libc_start_main (/usr/lib64/libc.so.6+0x23fa5)
#29 0x0000564d056ca891 _start (llc+0x2e891)
Aborted (core dumped)
```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJy0mMlu47oShp-G3hAxOGpYeCG349wACW7QSQe9CyiKsnVaJg2RyvD2B9RgDZ2DOD0Aga3I4l9fFYtVFIW1xU4rtQJ8DfhmIWq3N9XqHyFNWr6hRWqytxUIUPtXls8HgDYAJU5UO-Wgq4pjqSCgGwgIeY2Cp4ABQtpn2s9M5YVWMC-NcBAwlAMSARL751uRi1wJV1fK-oF04z_JWjy_ckxyQAgE4RoCuobaQGGtqlxhNHzZKw2zwoq0VFlrCEJAOG5Y6sKZ_AgLzOHRFNZo6ExL0D9aKdcjEY473nDTXfT-vv8vYbAsJby4eFaV9TCAUEipwkzJLBBCRjLAEnEeE5xlgeIBy3CIckVZFrQaNzePtxCQaO_cEdAEkC0gWx_dpal2zX-xv93CNg_3tnC4REvSu7G5XH-7gmldlBl8Kdx-iJBdzmhzYd1FYVUJ6AbDSh0rsyzL9qGylIAmsJlesi20LOtMdUSAbL-YTF0pDcj2UZS1eng7KrvcA5pQhPy428eHdixNAE0uHx_ai51y98XhWKrHh27OpdHW-RHJaSJBgArbPnZKjACQwOfH5etRSacyKGAn1JsHBDd5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