You're probably running into the fact that Intel processors have floating point registers with 80 bits, and when optimization is turned on, operations are done in registers and not truncated as they are when the values are stored to memory.
See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=323 Notice the number of duplicated reports - it's a surprise to a lot of people. There are ways to set the precision used by the FPU, e.g., #include "fpu_control.h" fpu_control_t cw; _FPU_GETCW(cw); cw &= ~_FPU_EXTENDED; cw |= _FPU_DOUBLE; _FPU_SETCW(cw); ------------------------------------------------------------------------------ Site24x7 APM Insight: Get Deep Visibility into Application Performance APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month Monitor end-to-end web transactions and take corrective actions now Troubleshoot faster and improve end-user experience. Signup Now! http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140 _______________________________________________ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public