Error in fused multiply add

Carlos O'Donell carlos@systemhalted.org
Sat Jul 5 21:30:00 GMT 2008


On Fri, Jul 4, 2008 at 3:05 AM, John Pryce <j.d.pryce@ntlworld.com> wrote:
> Platform:
>  Model Identifier:     MacBookPro2,2
>  Processor Name:       Intel Core 2 Duo
>  OS: Mac OS X 10.4.11 Tiger
>  Compiler: i686-apple-darwin8-gcc-4.0.1 (GCC) 4.0.1

What C library are you using? Are you actually linking against glibc?

If you *are* linking against glibc, please provide a test case.

This works perfectly fine on my i686-pc-linux-gnu GNU/Libc based system.

cat >> test.c <<EOF
#include <stdio.h>
#include <stdlib.h>
#include <math.h>

int main (void) {
  printf("fma(+inf,+inf,0) = %g\n", fma(INFINITY,INFINITY,0));
  return 0;
}
EOF
gcc -std=c99 -lm -o test test.c
./test
fma(+inf,+inf,0) = inf

Cheers,
Carlos.



More information about the Libc-help mailing list