|
|
|
|
|
by AlotOfReading
34 days ago
|
|
Your compiler does many optimizations that break numerical reproducibility, especially in floats. I reviewed a PR the other day that wrote
X=AB+(CD)+E; And when I checked 3 different compilers, each of them chose a different way to use FMAs. Even with integer math, you can get different numerical results via UB (e.g. expressions with signed overflow one way and not another). |
|