fallback: legalize: G_ICMP <2 x s1>,<2 x s64>

Run:explore-bc8218b282-20261015-075519
Kind:fallback
Category:legalize: G_ICMP <2 x s1>,<2 x s64> NEW
Occurrences:4 in 4 configs, 2 test files
Snippet from:rv32zbb.8e461c7fca.ll (mutant of rv32zbb.ll) @ctpop_v2i64_ne_one via llvm-extract
Config:-mtriple=riscv32 -mattr=+zbb -verify-machineinstrs
Local check:reproduces at bc8218b282
Compiler Explorer:not uploaded (over --godbolt-limit or disabled)

Snippet:

@G.1 = external global i8

; Function Attrs: nounwind
define <2 x i1> @ctpop_v2i64_ne_one(<2 x i64> %a) #0 {
  %1 = call <2 x i64> @llvm.ctpop.v2i64(<2 x i64> %a)
  %B = urem i8 42, 127
  %2 = icmp ne <2 x i64> %1, splat (i64 1)
  store i8 %B, ptr @G.1, align 1
  ret <2 x i1> %2
}

; Function Attrs: nocallback nocreateundeforpoison nofree nosync nounwind speculatable willreturn memory(none)
declare <2 x i64> @llvm.ctpop.v2i64(<2 x i64>) #1

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

Reproduce:

llc -mtriple=riscv32 -mattr=+zbb -verify-machineinstrs -global-isel -global-isel-abort=2 -pass-remarks-missed=gisel.* snippet.ll -o -
llc -mtriple=riscv32 -mattr=+zbb -verify-machineinstrs -global-isel=0 snippet.ll -o -

Local llc output:

remark: <unknown>:0:0: unable to legalize instruction: %9:_(<2 x s1>) = G_ICMP intpred(ule), %8:_(<2 x s64>), %7:_ (in function: ctpop_v2i64_ne_one)
warning: Instruction selection used fallback path for ctpop_v2i64_ne_one

Occurrences (4):

InputFunctionConfig
rv32zbb.8e461c7fca.ll (mutant of rv32zbb.ll)ctpop_v2i64_ne_one-mtriple=riscv32 -mattr=+zbb -verify-machineinstrs
rv32zbb.c30e6f302a.ll (mutant of rv32zbb.ll)ctpop_v2i64_ne_one-mtriple=riscv32 -verify-machineinstrs
rv64zbb.b97297403e.ll (mutant of rv64zbb.ll)ctpop_v2i64_eq_one-mtriple=riscv64 -mattr=+zbb -verify-machineinstrs
rv64zbb.fbb33c4520.ll (mutant of rv64zbb.ll)ctpop_v2i64_eq_one-mtriple=riscv64 -verify-machineinstrs

Generated 2026-10-15 08:05 UTC.