This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug math/14638] New: fma produced wrong results for (0 * -1.0) + -0.0
- From: "law at redhat dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: Thu, 27 Sep 2012 20:45:29 +0000
- Subject: [Bug math/14638] New: fma produced wrong results for (0 * -1.0) + -0.0
- Auto-submitted: auto-generated
http://sourceware.org/bugzilla/show_bug.cgi?id=14638
Bug #: 14638
Summary: fma produced wrong results for (0 * -1.0) + -0.0
Product: glibc
Version: 2.17
Status: NEW
Severity: normal
Priority: P2
Component: math
AssignedTo: unassigned@sourceware.org
ReportedBy: law@redhat.com
Classification: Unclassified
The FMA implementation in sysdeps/ieee754/dbl-64/s_fma.c produces the wrong
result for this program when run on a x86_64 box that doesn't have fma3/fma4
support.
#include <assert.h>
#include <math.h>
#include <stdlib.h>
int main (void) {
double f1 = 0.0f;
double f2 = -1.0f;
double f3 = -0.0f;
double dresult = fma (f1, f2, f3);
if (! signbit (dresult))
abort ();
exit (0);
}
--
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.