fallback: legalize: G_INSERT_VECTOR_ELT <N x f16>

Run:explore-d9924131a4-20261128-105811
Kind:fallback
Category:legalize: G_INSERT_VECTOR_ELT <N x f16> M
Occurrences:4 in 4 configs, 3 test files, 20 more counted only
Snippet from:fixed-vectors-vfmax.43dfb26453.ll (mutant of fixed-vectors-vfmax.ll) @vfmax_v4f16_fv via llvm-extract
Config:-mtriple=riscv32 -target-abi=ilp32d -verify-machineinstrs -mattr=+d,+zfh,+zfbfmin,+zvfbfmin,+v,+zve64d -O0 -code-model=medium
Local check:reproduces at d9924131a4
Compiler Explorer:not uploaded (over --godbolt-limit or disabled)

Snippet:

define <4 x half> @vfmax_v4f16_fv(<4 x half> %a, half %b) {
  %head = insertelement <4 x half> poison, half %b, i32 0
  %splat = shufflevector <4 x half> %head, <4 x half> poison, <4 x i32> zeroinitializer
  %v = call <4 x half> @llvm.maxnum.v4f16(<4 x half> %splat, <4 x half> %a)
  ret <4 x half> %head
}

; Function Attrs: nocallback nocreateundeforpoison nofree nosync nounwind speculatable willreturn memory(none)
declare <4 x half> @llvm.maxnum.v4f16(<4 x half>, <4 x half>) #0

attributes #0 = { nocallback nocreateundeforpoison nofree nosync nounwind speculatable willreturn memory(none) }

Reproduce:

llc -mtriple=riscv32 -target-abi=ilp32d -verify-machineinstrs -mattr=+d,+zfh,+zfbfmin,+zvfbfmin,+v,+zve64d -O0 -code-model=medium -global-isel -global-isel-abort=2 -pass-remarks-missed=gisel.* snippet.ll -o -
llc -mtriple=riscv32 -target-abi=ilp32d -verify-machineinstrs -mattr=+d,+zfh,+zfbfmin,+zvfbfmin,+v,+zve64d -O0 -code-model=medium -global-isel=0 snippet.ll -o -

Local llc output:

remark: <unknown>:0:0: unable to legalize instruction: %7:_(<4 x f16>) = G_INSERT_VECTOR_ELT %8:_, %1:_(f16), %9:_(i32) (in function: vfmax_v4f16_fv)
warning: Instruction selection used fallback path for vfmax_v4f16_fv

Occurrences (4):

InputFunctionConfig
fixed-vectors-lround.f5b963bfc0.ll (mutant of fixed-vectors-lround.ll)lround_v16f16-mtriple=riscv64 -target-abi=lp64d -verify-machineinstrs -mattr=+f,+d,+zvfhmin,+zvfbfmin -O1
fixed-vectors-vfmax.43dfb26453.ll (mutant of fixed-vectors-vfmax.ll)vfmax_v4f16_fv-mtriple=riscv32 -target-abi=ilp32d -verify-machineinstrs -mattr=+d,+zfh,+zfbfmin,+zvfbfmin,+v,+zve64d -O0 -code-model=medium
fp-fcanonicalize.7578b8dd76.ll (mutant of fp-fcanonicalize.ll)fcanonicalize_v4f16_nnan--mtriple=riscv32 -mattr=+-zfh -O1 -verify-machineinstrs
fp-fcanonicalize.d220a59a3a.ll (mutant of fp-fcanonicalize.ll)fcanonicalize_v8f16_nnan--mtriple=riscv32 -O2 -verify-machineinstrs

Generated 2026-11-29 14:49 UTC.