This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Patch: gcjh -vs- big endian


This patch works for me on a NetWinder.

Tom Tromey wrote:
> 
> I'm checking in the appended patch.
> 
> Scott, I'm CC'ing you because this changes a patch you sent.  Your
> patch changed D_NAN_MASK in gcjh to be word-reversed on big-endian
> machines.  I think we only need to do this on machines where the
> endianness of doubles disagrees with that of long longs.  For
> instance, your patch failed on a Sparc.  Can you verify that the new
> patch continues to work for ARM?
> 
> 2000-03-30  Tom Tromey  <tromey@cygnus.com>
> 
>         * gjavah.c (D_NAN_MASK): Only define as word-reversed when
>         HOST_FLOAT_WORDS_BIG_ENDIAN and HOST_WORDS_BIG_ENDIAN disagree.
> 
> Tom
> 
> Index: gjavah.c
> ===================================================================
> RCS file: /cvs/gcc/egcs/gcc/java/gjavah.c,v
> retrieving revision 1.49
> diff -u -r1.49 gjavah.c
> --- gjavah.c    2000/02/26 04:32:08     1.49
> +++ gjavah.c    2000/03/30 18:28:31
> @@ -203,7 +203,7 @@
> 
>  /* Some useful constants.  */
>  #define F_NAN_MASK 0x7f800000
> -#if (1 == HOST_FLOAT_WORDS_BIG_ENDIAN)
> +#if (1 == HOST_FLOAT_WORDS_BIG_ENDIAN) && ! defined (HOST_WORDS_BIG_ENDIAN)
>  #define D_NAN_MASK 0x000000007ff00000LL
>  #else
>  #define D_NAN_MASK 0x7ff0000000000000LL

-- 
Scott Bambrough - Software Engineer
REBEL.COM    http://www.rebel.com
NetWinder    http://www.netwinder.org

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]