| Issue |
75987
|
| Summary |
SLPVectorizer is non-deterministic after 44dc1e0baae7c4b8a02ba06dcf396d3d452aa873
|
| Labels |
new issue
|
| Assignees |
|
| Reporter |
aeubanks
|
```
$ cat /tmp/a.ll
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"
%struct.AVComplexFloat = type { float, float }
define void @fft7(ptr noundef %0, ptr noundef %1, ptr %2) #0 {
%.sroa.1.0.copyload = load float, ptr null, align 4
%4 = load float, ptr null, align 4
%5 = load ptr, ptr null, align 8
%6 = getelementptr inbounds %struct.AVComplexFloat, ptr %5, i64 6
%7 = load float, ptr %6, align 4
%8 = fsub nsz float 1.000000e+00, %7
%9 = fadd nsz float 1.000000e+00, %7
%10 = getelementptr inbounds %struct.AVComplexFloat, ptr %5, i64 6, i32 1
%11 = load float, ptr %10, align 4
%12 = fadd nsz float 1.000000e+00, %11
%13 = ptrtoint ptr %2 to i64
%14 = trunc i64 1 to i32
%15 = bitcast i32 1 to float
%16 = getelementptr inbounds %struct.AVComplexFloat, ptr %5, i64 5
%17 = load float, ptr %16, align 4
%18 = fadd nsz float 1.000000e+00, %17
%19 = getelementptr inbounds %struct.AVComplexFloat, ptr %5, i64 4, i32 1
%20 = load float, ptr %19, align 4
%21 = fsub nsz float 1.000000e+00, %20
%22 = fadd nsz float 1.000000e+00, %20
%23 = fmul nsz float %9, 0.000000e+00
%24 = fmul nsz float 0.000000e+00, 0.000000e+00
%25 = fsub nsz float %23, 0.000000e+00
%26 = fmul nsz float %18, 0.000000e+00
%27 = fsub nsz float %25, %26
%28 = fmul nsz float %12, 0.000000e+00
%29 = fsub nsz float %28, 0.000000e+00
%30 = fmul nsz float %22, 0.000000e+00
%31 = fsub nsz float %29, %30
%32 = fmul nsz float %21, 0.000000e+00
%33 = fadd nsz float %32, 0.000000e+00
%34 = fadd nsz float %33, 0.000000e+00
%35 = fmul nsz float %8, 0.000000e+00
%36 = fadd nsz float %35, 0.000000e+00
%37 = fadd nsz float %36, 0.000000e+00
%38 = fsub nsz float %27, %34
store float 0.000000e+00, ptr null, align 8
%39 = fadd nsz float %31, %37
%40 = fadd nsz float 1.000000e+00, %38
store float %40, ptr %0, align 4
%41 = fadd nsz float 1.000000e+00, %39
%42 = getelementptr inbounds %struct.AVComplexFloat, ptr %0, i64 0, i32 1
store float %41, ptr %42, align 4
ret void
}
attributes #0 = { alwaysinline nounwind null_pointer_is_valid ssp uwtable "min-legal-vector-width"="0" "no-signed-zeros-fp-math"="true" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+sse3,+x87" "tune-cpu"="generic" }
$ opt -p slp-vectorizer -S /tmp/a.ll -o /tmp/b.ll
$ md5sum /tmp/b.ll
# is not deterministic
```
I bisected this to https://github.com/llvm/llvm-project/commit/44dc1e0baae7c4b8a02ba06dcf396d3d452aa873
@alexey-bataev can you take a look?
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs