Commit f2f96fb8 authored by Marcus Oakland's avatar Marcus Oakland Committed by Ashok Bhat

AArch64: Make LONG 4 bytes

The libSYS/include/machine_type.h header file states LONG should be
"Data type representing 4 byte signed integer on all supported
platforms" but only provided for defining LONG as INT and ULONG as
UINT when __x86_64__ was defined. This has been changed to when
__LP64__ is defined, so that it also applies to AArch64. The change
to libFDK/include/common_fix.h is then needed to get the project to
compile.

Change-Id: Iea42d7eca97dcc9da772a05b207d134cb999a72a
Signed-off-by: default avatarMarcus Oakland <marcus.oakland@arm.com>
parent fa3eba16
...@@ -226,7 +226,7 @@ FDK_INLINE FIXP_SGL fAbs(FIXP_SGL x) ...@@ -226,7 +226,7 @@ FDK_INLINE FIXP_SGL fAbs(FIXP_SGL x)
{ return fixabs_S(x); } { return fixabs_S(x); }
/* workaround for TI C6x compiler but not for TI ARM9E compiler */ /* workaround for TI C6x compiler but not for TI ARM9E compiler */
#if (!defined(__TI_COMPILER_VERSION__) || defined(__TI_TMS470_V5__)) && !defined(__x86_64__) #if (!defined(__TI_COMPILER_VERSION__) || defined(__TI_TMS470_V5__)) && !defined(__LP64__)
FDK_INLINE INT fAbs(INT x) FDK_INLINE INT fAbs(INT x)
{ return fixabs_I(x); } { return fixabs_I(x); }
#endif #endif
...@@ -336,7 +336,7 @@ FDK_INLINE FIXP_SGL fMax(FIXP_SGL a, FIXP_SGL b) ...@@ -336,7 +336,7 @@ FDK_INLINE FIXP_SGL fMax(FIXP_SGL a, FIXP_SGL b)
{ return fixmax_S(a,b); } { return fixmax_S(a,b); }
/* workaround for TI C6x compiler but not for TI ARM9E */ /* workaround for TI C6x compiler but not for TI ARM9E */
#if ((!defined(__TI_COMPILER_VERSION__) || defined(__TI_TMS470_V5__)) && !defined(__x86_64__)) || (FIX_FRACT == 1) #if ((!defined(__TI_COMPILER_VERSION__) || defined(__TI_TMS470_V5__)) && !defined(__LP64__)) || (FIX_FRACT == 1)
FDK_INLINE INT fMax(INT a, INT b) FDK_INLINE INT fMax(INT a, INT b)
{ return fixmax_I(a,b); } { return fixmax_I(a,b); }
FDK_INLINE INT fMin(INT a, INT b) FDK_INLINE INT fMin(INT a, INT b)
......
...@@ -154,15 +154,15 @@ amm-info@iis.fraunhofer.de ...@@ -154,15 +154,15 @@ amm-info@iis.fraunhofer.de
typedef signed int INT; typedef signed int INT;
typedef unsigned int UINT; typedef unsigned int UINT;
#ifdef __x86_64__ #ifdef __LP64__
/* force FDK long-datatypes to 4 byte */ /* force FDK long-datatypes to 4 byte */
/* jdr: Use defines to avoid type alias problems on 64 bit machines. */ /* jdr: Use defines to avoid type alias problems on 64 bit machines. */
#define LONG INT #define LONG INT
#define ULONG UINT #define ULONG UINT
#else /* __x86_64__ */ #else /* __LP64__ */
typedef signed long LONG; typedef signed long LONG;
typedef unsigned long ULONG; typedef unsigned long ULONG;
#endif /* __x86_64__ */ #endif /* __LP64__ */
typedef signed short SHORT; typedef signed short SHORT;
typedef unsigned short USHORT; typedef unsigned short USHORT;
typedef signed char SCHAR; typedef signed char SCHAR;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment