Re:Weird compiler bug – Same code, different results
by zaitanz on Friday January 29, 2021 @06:30PM
(#25964249)
This is very true. Once upon a time -o3 would enable fast-math. We're very careful to ensure we use test models to verify the outputs of release binaries. Enabling fast-math as you have said optimises the equations in a way that produces different results.
Source: I've been working on such optimizations this past week. And that means establishing precisely which flags I need to have enabled in order for optimization to kick in.