News for hackers. Stuff that matters.
Re:GCC optimized code gives strange floating point results by EpicEng on Monday February 27, 2017 @10:22AM (#13744858)
Interesting. This reminds me of a bug I had to track down when rewriting a bunch of Java image analysis code in C# (yeah I would have preferred neither language for this sort of thing, but that's a different story.)

Java has a flag which allows you to specify how 32-bit floating point arithmetic happens (STRICT_FP or something.) C# does not, and was doing extended precision math on floats (80-bit register) and then truncating the result. This led to small differences in feature extraction output.

There are no comments on this comment yet.