miscompile: miscompile rv64: addi,andi,fcvt.lu.s,fcvt.wu.s,lbu,li

Run:explore-d9924131a4-20261128-105811
Kind:miscompile
Category:miscompile rv64: addi,andi,fcvt.lu.s,fcvt.wu.s,lbu,li M
Occurrences:1 in 1 configs, 1 test files
Snippet from:rv64zfhmin-half-convert.c7c1c5c2.e5ec1d14.d371f6cb46.ll (mutant of rv64zfhmin-half-convert.c7c1c5c2.e5ec1d14.ll) @zext_fptoui via llvm-extract
Config:-mtriple=riscv64 -verify-machineinstrs -target-abi lp64f -mattr=+zfhmin,+m,+zvfh -O0
Local check:reproduces at d9924131a4
Compiler Explorer:not applicable: Compiler Explorer compiles RISC-V but cannot run it

Snippet:

@G = external global i32
@G.1 = external global i8
@G.2 = external global i8
@G.5 = external global i1

; Function Attrs: nounwind
define zeroext i32 @zext_fptoui(half %a) #0 {
  %LGV = load i8, ptr @G.1, align 1
  %B1 = ashr i8 %LGV, 0
  %1 = fptoui half %a to i32
  %C2 = icmp sle i8 %LGV, %LGV
  %B = xor i32 %1, 0
  store i32 %B, ptr @G, align 4
  store i8 %B1, ptr @G.2, align 1
  store i1 %C2, ptr @G.5, align 1
  ret i32 %1
}

attributes #0 = { nounwind }

Reproduce:

./exec_oracle.py --flags '-mtriple=riscv64 -verify-machineinstrs -target-abi lp64f -mattr=+zfhmin,+m,+zvfh -O0' --funcs zext_fptoui snippet.ll

Local execution result:

7 of 64 inputs differ (first: #12)
SelectionDAG hash 5bef58d3690d6076, GlobalISel hash b0327560e339d2be
b0: llc -mtriple=riscv64 -verify-machineinstrs -target-abi lp64f -mattr=+zfhmin,+m,+zvfh -O0 -global-isel=0
b1: llc -mtriple=riscv64 -verify-machineinstrs -target-abi lp64f -mattr=+zfhmin,+m,+zvfh -O2 -global-isel=0
b2: llc -mtriple=riscv64 -verify-machineinstrs -target-abi lp64f -mattr=+zfhmin,+m,+zvfh -O0 -global-isel -global-isel-abort=2

Occurrences (1):

InputFunctionConfig
rv64zfhmin-half-convert.c7c1c5c2.e5ec1d14.d371f6cb46.ll (mutant of rv64zfhmin-half-convert.c7c1c5c2.e5ec1d14.ll)zext_fptoui-mtriple=riscv64 -verify-machineinstrs -target-abi lp64f -mattr=+zfhmin,+m,+zvfh -O0

Generated 2026-11-29 14:49 UTC.