fallback: legalize: G_VECREDUCE_AND <N x i8>

Run:explore-d9924131a4-20261128-105811
Kind:fallback
Category:legalize: G_VECREDUCE_AND <N x i8> M
Occurrences:5 in 4 configs, 2 test files, 8 more counted only
Snippet from:fixed-vectors-reduction-int.3f0195a6d1.ll (mutant of fixed-vectors-reduction-int.ll) @vreduce_and_v256i8 via llvm-extract
Config:-mtriple=riscv64 -verify-machineinstrs -mattr=+m,+v,+d,+zba -O1
Local check:reproduces at d9924131a4
Compiler Explorer:not uploaded (over --godbolt-limit or disabled)

Snippet:

define i8 @vreduce_and_v256i8(ptr %x) {
  %v = load <256 x i8>, ptr %x, align 256
  %B = udiv <256 x i8> %v, %v
  %red = call i8 @llvm.vector.reduce.and.v256i8(<256 x i8> %B)
  ret i8 %red
}

; Function Attrs: nocallback nocreateundeforpoison nofree nosync nounwind speculatable willreturn memory(none)
declare i8 @llvm.vector.reduce.and.v256i8(<256 x i8>) #0

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

Reproduce:

llc -mtriple=riscv64 -verify-machineinstrs -mattr=+m,+v,+d,+zba -O1 -global-isel -global-isel-abort=2 -pass-remarks-missed=gisel.* snippet.ll -o -
llc -mtriple=riscv64 -verify-machineinstrs -mattr=+m,+v,+d,+zba -O1 -global-isel=0 snippet.ll -o -

Local llc output:

remark: <unknown>:0:0: unable to legalize instruction: %3:_(i8) = G_VECREDUCE_AND %2:_(<256 x i8>) (in function: vreduce_and_v256i8)
warning: Instruction selection used fallback path for vreduce_and_v256i8

Occurrences (5):

InputFunctionConfig
fixed-vectors-reduction-int-vp.4f20a69ffe.ll (mutant of fixed-vectors-reduction-int-vp.ll)front_ele_v32i8-mtriple=riscv32 -verify-machineinstrs -O0
fixed-vectors-reduction-int.3f0195a6d1.ll (mutant of fixed-vectors-reduction-int.ll)vreduce_and_v256i8-mtriple=riscv64 -verify-machineinstrs -mattr=+m,+v,+d,+zba -O1
fixed-vectors-reduction-int.819a963a97.ll (mutant of fixed-vectors-reduction-int.ll)vreduce_and_v64i8-mtriple=riscv32 -verify-machineinstrs -mattr=+m,+v,+f,+zicsr -O1
fixed-vectors-reduction-int.a7dd883617.ll (mutant of fixed-vectors-reduction-int.ll)vreduce_and_v16i8-mtriple=riscv32 -verify-machineinstrs -mattr=+m,+v,+zicsr -O1
fixed-vectors-reduction-int.a7dd883617.ll (mutant of fixed-vectors-reduction-int.ll)vreduce_and_v128i8-mtriple=riscv32 -verify-machineinstrs -mattr=+m,+v,+zicsr -O1

Generated 2026-11-29 14:49 UTC.