This is the mail archive of the libc-hacker@sourceware.cygnus.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: libm-i387 bug?


Zack Weinberg <zack@rabi.phys.columbia.edu> writes:

> This test program prints "-1.949464 0.000000". Shouldn't it print
> "0.000000 1.000000" ?
> 
> zw
> 
> #include <math.h>
> #include <stdio.h>
> 
> int main(void)
> {
>   printf("%f %f", fdim(2.0, 3.0), fdim(3.0, 2.0));
>   return 0;
> }

Did you defined _GNU_SOURCE?  I get (with the i686 implementation of
these functions) the correct result.

-- 
---------------.      drepper at gnu.org  ,-.   1325 Chesapeake Terrace
Ulrich Drepper  \    ,-------------------'   \  Sunnyvale, CA 94089 USA
Cygnus Solutions `--' drepper at cygnus.com   `------------------------


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]