This is the mail archive of the
mailing list for the GCC project.
Re: cross-compiled floating point constants broken NOT!
- To: egcs-bugs at egcs dot cygnus dot com
- Subject: Re: cross-compiled floating point constants broken NOT!
- From: David Whitten <whitten at netcom dot com>
- Date: Wed, 3 Feb 1999 09:32:30 -0800 (PST)
- Cc: moshier at mediaone dot net
> Elsewhere the treatment of integer versus floating values does not
> seem so clear-cut. For example, in split_double the pieces get sign
> extended if the input is an integer type but not if it is a floating
> point type. Do we know offhand if that is good or bad?
I'm not sure if it makes sense to sign extend a float.
To my knowledge sign extension is a copy operation of the sign
of a smaller integer into the upper bytes when it is copied into a
register or memory storage that is wider than it is.
Ie: a signed char (1 byte) into a 4 byte storage needs the
upper 3 bytes to be a copy of the sign, (either FF FF FF or 00 00 00)
so that the two's complement works properly.
Float values don't (to my knowledge) use two's complement, hence they
don't need to be sign extended.