This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Patch: gcjh -vs- big endian
- To: Gcc Patch List <gcc-patches at gcc dot gnu dot org>
- Subject: Patch: gcjh -vs- big endian
- From: Tom Tromey <tromey at cygnus dot com>
- Date: 30 Mar 2000 11:39:56 -0700
- Cc: Scott Bambrough <scottb at netwinder dot org>
- Reply-To: tromey at cygnus dot com
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