fallback: legalize: G_EXTRACT_SUBVECTOR <N x f16>,<N x f16>

Run:explore-d9924131a4-20261128-105811
Kind:fallback
Category:legalize: G_EXTRACT_SUBVECTOR <N x f16>,<N x f16> M
Occurrences:3 in 3 configs, 1 test files, 18 more counted only
Snippet from:fixed-vectors-extract-subvector.ab54157124.ll (mutant of fixed-vectors-extract-subvector.ll) @extract_v2f16_v4f16_0 via llvm-extract
Config:-mtriple=riscv32 -riscv-v-vector-bits-max=128 -verify-machineinstrs -mattr=+m,+v,+zvfhmin,+zvfbfmin,+a,+zbs -O0
Local check:reproduces at d9924131a4
Compiler Explorer:not uploaded (over --godbolt-limit or disabled)

Snippet:

define void @extract_v2f16_v4f16_0(ptr %x, ptr %y) {
  %a = load <4 x half>, ptr %x, align 8
  %C = fcmp ogt half 4.200000e+01, +inf
  %c = call <2 x half> @llvm.vector.extract.v2f16.v4f16(<4 x half> %a, i64 0)
  store <2 x half> %c, ptr %y, align 4
  store i1 %C, ptr poison, align 1
  ret void
}

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare <2 x half> @llvm.vector.extract.v2f16.v4f16(<4 x half>, i64 immarg) #0

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

Reproduce:

llc -mtriple=riscv32 -riscv-v-vector-bits-max=128 -verify-machineinstrs -mattr=+m,+v,+zvfhmin,+zvfbfmin,+a,+zbs -O0 -global-isel -global-isel-abort=2 -pass-remarks-missed=gisel.* snippet.ll -o -
llc -mtriple=riscv32 -riscv-v-vector-bits-max=128 -verify-machineinstrs -mattr=+m,+v,+zvfhmin,+zvfbfmin,+a,+zbs -O0 -global-isel=0 snippet.ll -o -

Local llc output:

remark: <unknown>:0:0: unable to legalize instruction: %6:_(<2 x f16>) = G_EXTRACT_SUBVECTOR %2:_(<4 x f16>), 0 (in function: extract_v2f16_v4f16_0)
warning: Instruction selection used fallback path for extract_v2f16_v4f16_0

Occurrences (3):

InputFunctionConfig
fixed-vectors-extract-subvector.0a630585a8.ll (mutant of fixed-vectors-extract-subvector.ll)extract_v2f16_v4f16_0-mtriple=riscv32 -riscv-v-vector-bits-max=128 -verify-machineinstrs -mattr=+m,+v,+zvfh,+zvfbfmin,+zicsr -O0
fixed-vectors-extract-subvector.361ec1f5aa.ll (mutant of fixed-vectors-extract-subvector.ll)extract_v2f16_v4f16_0-mtriple=riscv64 -verify-machineinstrs -mattr=+m,+v,+zvfhmin,+zvfbfmin,+zfhmin,+zvbb -O3
fixed-vectors-extract-subvector.ab54157124.ll (mutant of fixed-vectors-extract-subvector.ll)extract_v2f16_v4f16_0-mtriple=riscv32 -riscv-v-vector-bits-max=128 -verify-machineinstrs -mattr=+m,+v,+zvfhmin,+zvfbfmin,+a,+zbs -O0

Generated 2026-11-29 14:49 UTC.