This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/4943] Inconsistent rounding behaviour for sprintf and IEEE doubles
- From: "vincent+libc at vinc17 dot org" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: 20 Sep 2007 01:02:35 -0000
- Subject: [Bug libc/4943] Inconsistent rounding behaviour for sprintf and IEEE doubles
- References: <20070820142205.4943.paul@inet.co.za>
- Reply-to: sourceware-bugzilla at sourceware dot org
------- Additional Comments From vincent+libc at vinc17 dot org 2007-09-20 01:02 -------
(In reply to comment #4)
> Thank you for making my point for me. Your exact same code compiled
> with MinGW for Windows produces the following output:
This is a different C library under Windows, not the glibc.
> You still don't spot the inconsistency?
No inconsistencies. You get different results because the C standard doesn't
specify these cases and the C libraries are different. FYI, the Mac OS X libc
and the Solaris2.7 libc both give the same results as glibc. So, if there is a
library that would need to change in order to make the results the same
everywhere is MinGW, not the glibc.
> Rounding toward even numbers is mathematical nonsense.
You may think that, but this doesn't make a standard. IEEE-754 rules are already
well-established. So, it would be a bit difficult for you to make things change.
--
http://sourceware.org/bugzilla/show_bug.cgi?id=4943
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.