Subject: Re: NetBSD/vax 1.6 pkgsrc perl build?
To: NetBSD/vax Mailing List <port-vax@netbsd.org>
From: Brian Chase <vaxzilla@jarai.org>
List: port-vax
Date: 11/02/2002 20:00:34
On Sun, 3 Nov 2002, der Mouse wrote:
> > The F_float is a 32-bits. It's sign magnitude number with a sign
> > bit, 7-bits of exponent, and 24-bits for the fractional part. The
> > range is given as 0.29x10^-38 through 1.7x10^38.
>
> 7 bits of exponent gives you a range of only 1.08e-19 through 9.22e18
> (2^-63 to 2^63); you need 8 bits of exponent to get the range of
> 0.29e-38 to 1.7e38.
>
> I believe it's 1 bit sign, 8 bits exponent, 24 bits mantissa - but that
> 24 bits includes the hidden bit, which is not actually stored.
Oops, you're correct. Here are some ASCII versions of what's in
the VARM:
F_float
15
31 16|14 7 6 0
+------------------+-+--------+-------+
| fraction |S| exp | fract | :A
+------------------+-+--------+-------+
D_float
15
31 16|14 7 6 0
+------------------+-+--------+-------+
| fraction |S| exp | fract | :A
+------------------+-+--------+-------+
| fraction | fraction | :A+4
+------------------+------------------+
63 32
G_float
15
31 16|14 4 3 0
+------------------+-+----------+-----+
| fraction |S| exponent |fract| :A
+------------------+-+----------+-----+
| fraction | fraction | :A+4
+------------------+------------------+
63 32
H_float
15
31 16|14 0
+------------------+-+----------------+
| fraction |S| exponent | :A
+------------------+-+----------------+
| fraction | fraction | :A+4
+------------------+------------------+
| fraction | fraction | :A+8
+------------------+------------------+
| fraction | fraction | :A+12
+------------------+------------------+
127 96
-brian.