fallback: translate: icmp ptr

Run:explore-d9924131a4-20261128-105811
Kind:fallback
Category:translate: icmp ptr M
Occurrences:3 in 3 configs, 2 test files, 5 more counted only
Snippet from:fli-licm.1aaf37e003.ll (mutant of fli-licm.ll) @process_nodes via llvm-extract
Config:-mtriple=riscv64 -target-abi=lp64f -mattr=+zfinx -O0 -code-model=small -verify-machineinstrs
Local check:reproduces at d9924131a4
Compiler Explorer:not uploaded (over --godbolt-limit or disabled)

Snippet:

%struct.Node = type { ptr, ptr }

@G = external global i1
@G.1 = external global i1

; Function Attrs: nounwind
define void @process_nodes(ptr %0) #0 {
entry:
  %1 = icmp eq ptr %0, null
  br i1 %1, label %exit, label %loop

loop:                                             ; preds = %loop, %entry
  %2 = phi ptr [ %4, %loop ], [ %0, %entry ]
  tail call void @do_it(float 1.000000e+00, ptr nonnull %2)
  %3 = getelementptr inbounds %struct.Node, ptr %2, i64 0, i32 0
  %B = srem i1 %1, %1
  %4 = load ptr, ptr %3, align 8
  %C = icmp sge i1 %1, true
  %5 = icmp eq ptr %4, null
  store i1 %C, ptr @G, align 1
  store i1 %B, ptr @G.1, align 1
  br i1 %5, label %exit, label %loop

exit:                                             ; preds = %loop, %entry
  ret void
}

declare void @do_it(float, ptr)

attributes #0 = { nounwind }

Reproduce:

llc -mtriple=riscv64 -target-abi=lp64f -mattr=+zfinx -O0 -code-model=small -verify-machineinstrs -global-isel -global-isel-abort=2 -pass-remarks-missed=gisel.* snippet.ll -o -
llc -mtriple=riscv64 -target-abi=lp64f -mattr=+zfinx -O0 -code-model=small -verify-machineinstrs -global-isel=0 snippet.ll -o -

Local llc output:

remark: <unknown>:0:0: unable to translate instruction: icmp: '  %1 = icmp eq ptr %0, null' (in function: process_nodes)
warning: Instruction selection used fallback path for process_nodes

Occurrences (3):

InputFunctionConfig
exception-pointer-register.0f9f3ebc9d.ll (mutant of exception-pointer-register.ll)caller-mtriple=riscv64 -verify-machineinstrs -mattr=+zhinx -O3 -code-model=small
exception-pointer-register.ccb82412fb.ll (mutant of exception-pointer-register.ll)caller-mtriple=riscv64 -verify-machineinstrs -mattr=+zfinx,+zbb -O3
fli-licm.1aaf37e003.ll (mutant of fli-licm.ll)process_nodes-mtriple=riscv64 -target-abi=lp64f -mattr=+zfinx -O0 -code-model=small -verify-machineinstrs

Generated 2026-11-29 14:49 UTC.