This is the mail archive of the libc-ports@sources.redhat.com mailing list for the libc-ports project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Test tstdiomisc fails when multiplication of NAN by -1 results in NAN


On Mon, 24 May 2010, Carlos O'Donell wrote:

> On Sun, May 23, 2010 at 12:37 PM, John David Anglin
> <dave@hiauly1.hia.nrc.ca> wrote:
> > Carlos,
> >
> > You have found a bug. ?The code should xor the sign bit when doing
> > negation. ?The existing code doesn't work for NANs. ?I'll try to
> > fix negdf2 and negsf2.
> 
> Should I file a bug?

I'm testing a fix.  I'll install to 4.6 and backport later.
A bug report would provide a record of the problem and fix.

> You are correct, I've checked for 64-bit, and this is correct. I was
> accidentally using the 32-bit float formats.
> 
> However, there is a bug in gdb then, which shows the NaN value as a
> 32-bit value and interprets only the top 32-bits of the 64-bit double
> -1.0 and displays -1.875 as if it were a 32-bit float.

Yah, I have never liked gdb's handling of floating point values.
For example, does "p/x val" interpret `val' as a float or double
when val is a hex constant string.  It seems to depend on the
length of the string.  You can't specify a size with `p'.  Values
in registers are another story.

Dave
-- 
J. David Anglin                                  dave.anglin@nrc-cnrc.gc.ca
National Research Council of Canada              (613) 990-0752 (FAX: 952-6602)


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