This is the mail archive of the
gdb@sourceware.cygnus.com
mailing list for the GDB project.
Re: long_long.exp testsuite failure...
- To: Scott Bambrough <scottb at netwinder dot org>
- Subject: Re: long_long.exp testsuite failure...
- From: Andrew Cagney <ac131313 at cygnus dot com>
- Date: Wed, 13 Oct 1999 12:13:41 +1000
- CC: GDB Mailing List <gdb at sourceware dot cygnus dot com>, James Ingham <jingham at cygnus dot com>
- Organization: Cygnus Solutions
- References: <380394A9.7BEA1815@netwinder.org>
Scott Bambrough wrote:
>
> Hi,
>
> The following is a fragment from testsuite/gdb.base/long_long.exp,
> modified to correct a problem on ARM Linux. It doesn't work however and
> I don't understand why.
>
> The test assigns an octal value to a long long variable oct then
> attempts to print it as floating point value.
>
> long long oct = 01234567123456701234567LL;
>
> The problem is the ARM floating point storage format is odd. It is
> little endian, with the words swapped to be big endian. As an example,
> the above number in hex is 0xa72ee53977053977. If in GDB, I swap the
> words, setting oct = 0x77053977a72ee539 and then p/f oct, I get the
> expected value -5.9822653797615723e-120. Without the swap, I get
> 2.1386676354387559e+265.
Just BTW, the problem is more common then you think :-) TI's c80 would
have similar problems.
Andrew