Subject: Re: Q: ARM32 ABI
To: None <richard.earnshaw@arm.com>
From: Godmar Back <gback@cs.utah.edu>
List: port-arm32
Date: 06/04/1998 01:06:31
 Hi,

thanks for your replies.
I got it basically working, except I am not able to properly return
and print floats and doubles.  Actually, I'm returning them just fine,
but the Java libraries (which implement their own double->ascii
conversion) can't print them, complaining that "133" is an excessively
large digit. (The number it's trying to print is 133.6)
The libraries use a native function to obtain the bit layout of a double,
which is invoked.

So, three short questions:

* Does the arm software floating point emulation use IEEE-754?

    In particular, I need to implement a function that turns a double number
    into its IEEE 754 floating-point "double format" bit layout, where
    Bit 63 represents the sign of the floating-point number.  Bits 62-52 
    represent the exponent.  Bits 51-0 represent the significand (sometimes 
    called the mantissa) of the floating-point number.

* Is it correct to implement this function like so:

    long long doubleToLongBits(double val) { return *(long long *)&val; }

* Do long longs work as advertised in NetBSD/arm32 or are there any known
  caveats?

thanks,

	Godmar