miscompile: miscompile rv64: add,addi,and,andi,andn,fld
| Run: | explore-d9924131a4-20261128-105811 |
| Kind: | miscompile |
| Category: | miscompile rv64: add,addi,and,andi,andn,fld NEW M |
| Occurrences: | 1 in 1 configs, 1 test files |
| Snippet from: | fixed-vectors-extract-i1.37802a4b.963c4820.af2b70cf.560ce5b8.90fd6d3d.fa554d1f.0d064228.066c02134f.ll (mutant of fixed-vectors-extract-i1.37802a4b.963c4820.af2b70cf.560ce5b8.90fd6d3d.fa554d1f.0d064228.ll) @extractelt_v1i1 via llvm-extract |
| Config: | -mtriple=riscv64 -target-abi=lp64d -verify-machineinstrs -mattr=+zicsr,+zve64d,+zbb -O1 -code-model=small |
| Local check: | reproduces at d9924131a4 |
| Compiler Explorer: | not applicable: Compiler Explorer compiles RISC-V but cannot run it |
Snippet:
@G.4 = external global i1
@G.12 = external global double
@G.14 = external global i1
@G.16 = external global i1
; Function Attrs: nounwind
define i1 @extractelt_v1i1(ptr %x, i64 %idx) #0 {
%LGV6 = load i1, ptr @G.14, align 1
%A3 = alloca i1, align 1
store i1 poison, ptr %A3, align 1
%LGV = load double, ptr @G.12, align 8
%A = alloca i1, align 1
%L2 = load i1, ptr %A, align 1
%L1 = load double, ptr %A, align 8
%C = icmp ule i64 %idx, -9223372036854775808
%L = load i128, ptr %A, align 4
%B3 = shl i1 %C, %L2
%L3 = load i1, ptr %A, align 1
%B1 = and i1 %C, %L3
%a = load <1 x i8>, ptr %x, align 1
%b = icmp eq <1 x i8> %a, zeroinitializer
%A4 = alloca ptr, align 8
store i1 poison, ptr %A, align 1
%C5 = icmp eq i64 %idx, %idx
%B = fmul double +inf, %L1
%A2 = alloca double, align 8
store i1 %C, ptr %A, align 1
%B8 = xor i1 %LGV6, true
%c = extractelement <1 x i1> %b, i64 %idx
store ptr poison, ptr %A4, align 8
%G = getelementptr <2 x i64>, ptr %A2, i1 %L3
%G4 = getelementptr double, ptr %x, i1 %L3
store ptr %G, ptr %A4, align 8
store double poison, ptr %A2, align 8
%G1 = getelementptr double, ptr %x, i128 %L
store double %B, ptr %A2, align 8
store ptr %G1, ptr %G, align 8
store i1 %B8, ptr %G1, align 1
%C2 = fcmp oge double %L1, %LGV
store i1 %C2, ptr %A3, align 1
store i1 %B1, ptr @G.4, align 1
store ptr %G4, ptr %G1, align 8
store i1 %C5, ptr %G4, align 1
store i1 %B3, ptr @G.16, align 1
ret i1 %c
}
attributes #0 = { nounwind }
Reproduce:
./exec_oracle.py --flags '-mtriple=riscv64 -target-abi=lp64d -verify-machineinstrs -mattr=+zicsr,+zve64d,+zbb -O1 -code-model=small' --funcs extractelt_v1i1 snippet.ll
Local execution result:
1 of 64 inputs differ (first: #0)
SelectionDAG hash 1f4a1495f3265d30, GlobalISel hash c8435979ed6361a5
b0: llc -mtriple=riscv64 -target-abi=lp64d -verify-machineinstrs -mattr=+zicsr,+zve64d,+zbb -code-model=small -O1 -global-isel=0
b1: llc -mtriple=riscv64 -target-abi=lp64d -verify-machineinstrs -mattr=+zicsr,+zve64d,+zbb -code-model=small -O0 -global-isel=0
b2: llc -mtriple=riscv64 -target-abi=lp64d -verify-machineinstrs -mattr=+zicsr,+zve64d,+zbb -code-model=small -O1 -global-isel -global-isel-abort=2
Occurrences (1):
| Input | Function | Config |
|---|
| fixed-vectors-extract-i1.37802a4b.963c4820.af2b70cf.560ce5b8.90fd6d3d.fa554d1f.0d064228.066c02134f.ll (mutant of fixed-vectors-extract-i1.37802a4b.963c4820.af2b70cf.560ce5b8.90fd6d3d.fa554d1f.0d064228.ll) | extractelt_v1i1 | -mtriple=riscv64 -target-abi=lp64d -verify-machineinstrs -mattr=+zicsr,+zve64d,+zbb -O1 -code-model=small |
Generated 2026-11-29 14:49 UTC.