Web lists-archives.com

Re: [Mingw-users] msvcrt printf bug




Hi Alan,

> [...]
> But since you don't seem to be encountering such issues yourself with
> modern Linux gcc,

Oops, I'm blushing a bit... but anyway: I actually use a native 
_Windows_ port of MinGW.  :-D

> I tried the experiment of generating PLplot results [...] using both -O0 and -O3, and indeed the
> results are identical (for 33 standard plplot examples representing
> several hundred pages of plots so it is an extensive test)!

Just excellent!  :-)

> So it
> appears the conclusion must be that floating-point calculations are
> done in much more consistent ways now with gcc for both your case and
> this recent PLplot test , and I intend to double-check that
> (unexpected for me) conclusion for the timeephem and FreeEOS projects
> where results are not so heavily rounded as those of PLplot.

Please do, and keep us posted.

> However, for whatever reason (e.g., everyone might now be using the
> same IEEE floating-point calculation algorithms) assuming this
> floating-point consistency is now true for most compilers (so long as
> no optimization is done other than the normal -O0 through -O3
> options), that is an important floating-point breakthrough that would
> make comparisons of results from one compiler to others _much_ simpler
> (as you have already discovered for your software project).
> Furthermore, if care was used to not gratuitously mess with the order
> of computations from one software release to the next, this
> breakthrough should also simplify consistency testing of results for
> various software versions.

Indeed, I find it extremely valuable.

> Finally, to drag this post back on topic for this list, I haven't paid
> much attention to earlier posts in this thread, but assuming from your
> subject line this floating-point consistency is not currently
> available for any unpatched official release of the MinGW version of
> gcc, this inconsistency is something I would strongly encourage the
> MinGW developers to address to aid such important cross-platform
> consistency testing.

Fully agree. Oops (once again!), I actually have no idea whether the 
precise MinGW compiler we use is a "patched official release"... but 
maybe it is:

C:\>gcc --version
gcc (i686-win32-sjlj-rev3, Built by MinGW-W64 project) 4.9.1
Copyright (C) 2014 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


Best,

Emanuel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
MinGW-users mailing list
MinGW-users@xxxxxxxxxxxxxxxxxxxxx

This list observes the Etiquette found at 
http://www.mingw.org/Mailing_Lists.
We ask that you be polite and do the same.  Disregard for the list etiquette may cause your account to be moderated.

_______________________________________________
You may change your MinGW Account Options or unsubscribe at:
https://lists.sourceforge.net/lists/listinfo/mingw-users
Also: mailto:mingw-users-request@xxxxxxxxxxxxxxxxxxxxx?subject=unsubscribe