RFA: Support infinity, NaN, and denormalized numbers in floatformat.c

Carlo Wood carlo@alinoe.com
Wed Dec 3 18:57:00 GMT 2003

On Wed, Dec 03, 2003 at 01:44:28PM -0500, Ian Lance Taylor wrote:
> literal, I can use the floatformat structures to pull it apart.  I
> then plan to output the literal as a C99 hex floating point constant.
> (A couple of people suggested this approach, and I can't think of a
> good reason to not do it.)

I think they meant to use C99 hex as the base for a new mangling,
and then print that more or less literally when demangling.  That would
avoid rounding on both ends (I understood that C99 corresponds exactly
with the internal representation of floats by gcc anyway) and removes all
target dependency.  I disagree with this, but well - its not that important.

> This approach probably doesn't help you, since you probably don't want
> to deal with the floatformat routines.
They allocate memory - therefore prefer to simply output the mangled bit.
After all,...

> I do think this is all kind of ridiculous, since I'm sure that nobody
> uses floating point constants in template expressions in real life.

Exactly what I've said several times :/.  I think my last patch is my
last word in the subject of demangling floats.  I'll have another look
iff a third party files a real-life complaint through GNATS, and not

Thanks for your reply,

More information about the Gdb-patches mailing list