fallback: legalize: G_VECREDUCE_XOR <N x i1>

Run:explore-d9924131a4-20261128-105811
Kind:fallback
Category:legalize: G_VECREDUCE_XOR <N x i1> M
Occurrences:6 in 6 configs, 2 test files, 27 more counted only
Snippet from:fixed-vectors-vreductions-mask.1285691b72.ll (mutant of fixed-vectors-vreductions-mask.ll) @vreduce_xor_v8i1 via llvm-extract
Config:-mtriple=riscv64 -verify-machineinstrs -mattr=+m,+v -O0
Local check:reproduces at d9924131a4
Compiler Explorer:not uploaded (over --godbolt-limit or disabled)

Snippet:

@G.3 = external global i1

define zeroext i1 @vreduce_xor_v8i1(<8 x i1> %v) {
  %LGV = load i1, ptr @G.3, align 1
  %red = call i1 @llvm.vector.reduce.xor.v8i1(<8 x i1> %v)
  %B = and i1 %red, %LGV
  ret i1 %B
}

; Function Attrs: nocallback nocreateundeforpoison nofree nosync nounwind speculatable willreturn memory(none)
declare i1 @llvm.vector.reduce.xor.v8i1(<8 x i1>) #0

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

Reproduce:

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

Local llc output:

remark: <unknown>:0:0: unable to legalize instruction: %4:_(i1) = G_VECREDUCE_XOR %0:_(<8 x i1>) (in function: vreduce_xor_v8i1)
warning: Instruction selection used fallback path for vreduce_xor_v8i1

Occurrences (6):

InputFunctionConfig
fixed-vectors-reduction-mask-vp.23c6a898f8.ll (mutant of fixed-vectors-reduction-mask-vp.ll)vpreduce_xor_v16i1-mtriple=riscv64 -verify-machineinstrs -mattr=+zicsr -O3
fixed-vectors-vreductions-mask.1285691b72.ll (mutant of fixed-vectors-vreductions-mask.ll)vreduce_xor_v8i1-mtriple=riscv64 -verify-machineinstrs -mattr=+m,+v -O0
fixed-vectors-vreductions-mask.2f5e7967cd.ll (mutant of fixed-vectors-vreductions-mask.ll)vreduce_xor_v256i1-mtriple=riscv32 -verify-machineinstrs -mattr=+m,+v,+d,+zicsr -O3
fixed-vectors-vreductions-mask.429280feae.ll (mutant of fixed-vectors-vreductions-mask.ll)vreduce_xor_v128i1-mtriple=riscv64 -verify-machineinstrs -mattr=+m,+zba -O2
fixed-vectors-vreductions-mask.71f7cca526.ll (mutant of fixed-vectors-vreductions-mask.ll)vreduce_xor_v16i1-mtriple=riscv64 -verify-machineinstrs -mattr=+m,+v,+zihintpause,+f -O2
fixed-vectors-vreductions-mask.8b3f562086.ll (mutant of fixed-vectors-vreductions-mask.ll)vreduce_xor_v128i1-mtriple=riscv32 -verify-machineinstrs -mattr=+m,+v -O0

Generated 2026-11-29 14:49 UTC.