From 4257e4fbe108af8c4c3ccef9de4a9af254776677 Mon Sep 17 00:00:00 2001 From: Theo de Raadt Date: Fri, 24 May 1996 10:57:44 +0000 Subject: darn good reason not use a primarily big-endian cpu in little-endian mode: the ARM port runs little-endian, but it's fp is still big-endian! --- lib/libm/src/math_private.h | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'lib/libm') diff --git a/lib/libm/src/math_private.h b/lib/libm/src/math_private.h index 741f1fd9ee9..a2b81a1881f 100644 --- a/lib/libm/src/math_private.h +++ b/lib/libm/src/math_private.h @@ -11,7 +11,7 @@ /* * from: @(#)fdlibm.h 5.1 93/09/24 - * $Id: math_private.h,v 1.2 1995/10/28 00:57:20 deraadt Exp $ + * $Id: math_private.h,v 1.3 1996/05/24 10:57:43 deraadt Exp $ */ #ifndef _MATH_PRIVATE_H_ @@ -34,7 +34,12 @@ /* A union which permits us to convert between a double and two 32 bit ints. */ -#if BYTE_ORDER == BIG_ENDIAN +/* + * The arm32 port is little endian except for the FP word order which is + * big endian. + */ + +#if (BYTE_ORDER == BIG_ENDIAN) || defined(arm32) typedef union { @@ -48,7 +53,7 @@ typedef union #endif -#if BYTE_ORDER == LITTLE_ENDIAN +#if (BYTE_ORDER == LITTLE_ENDIAN) && !defined(arm32) typedef union { -- cgit v1.2.3