[PATCH] Have gdb display float infinity.
Dwayne Grant McConnell
dgm69@us.ibm.com
Mon Aug 22 21:42:00 GMT 2005
On Mon, 22 Aug 2005, Mark Kettenis wrote:
> > Date: Mon, 22 Aug 2005 14:00:11 -0500 (Central Daylight Time)
> > From: Dwayne Grant McConnell <dgm69@us.ibm.com>
> >
> > I noticed that gdb does display NaNs in a special way but not infinity.
> > This patch changes that. I'm a bit new here so I have a few questions.
>
> Thanks! Since you're new, I'll have to ask whether you have a
> copyright assignment for gdb?
Yes. I have one for all the toolchain. I have contributed only to glibc up
to this point. Remind me, do I need to give you a reference number or
somesuch?
> > 1. Should I submit a testcase to go along with the patch? as a separate
> > patch? (I have no idea were to put it yet but I figured I would ask.)
>
> Yes please! A seperate patch is fine, but make sure it gets in
> shortly before or after the fix gets in.
Will do.
> > 2. I simply duplicated floatformat_is_nan() with one minor change to
> > produce floatformat_is_inf(). I could have done this differently. Should I
> > have changed float_format_is_nan() to float_format_is_nan_or_inf() and
> > given the function a parameter for NaN v Inf? Something else?
>
> Hmm, this indeeds seems to duplicate a fair amount of code. Having
> seperate functions for nan and inf is good I think, but do you see a
> way to avoid code duplication?
Let me think about it and I'll submit an alternate patch.
> > I have tested this with both ppc and ppc64 but nothing else.
>
> It'd be great if you also could test this on another platform,
> preferably amd64, i386 or m68k since those have extended double
> formats.
I'll see what I can do.
--
Dwayne Grant McConnell <dgm69@us.ibm.com>
Lotus Notes: Dwayne McConnell/Austin/IBM@IBMUS
More information about the Gdb-patches
mailing list