| Index: src/globals.h
|
| diff --git a/src/globals.h b/src/globals.h
|
| index 2f526a83bbebbb2386b488b2bb3eb134186bcd2e..ac5b71067baba5d3913ae9a8cd35a57db571f849 100644
|
| --- a/src/globals.h
|
| +++ b/src/globals.h
|
| @@ -38,7 +38,7 @@
|
| #if V8_CC_GNU && V8_GNUC_PREREQ(2, 96, 0) && !V8_GNUC_PREREQ(4, 1, 0)
|
| # include <limits> // NOLINT
|
| # define V8_INFINITY std::numeric_limits<double>::infinity()
|
| -#elif V8_CC_MSVC
|
| +#elif V8_LIBC_MSVCRT
|
| # define V8_INFINITY HUGE_VAL
|
| #else
|
| # define V8_INFINITY INFINITY
|
| @@ -71,6 +71,10 @@ namespace internal {
|
| #define V8_HOST_ARCH_IA32 1
|
| #define V8_HOST_ARCH_32_BIT 1
|
| #define V8_HOST_CAN_READ_UNALIGNED 1
|
| +#elif defined(__AARCH64EL__)
|
| +#define V8_HOST_ARCH_A64 1
|
| +#define V8_HOST_ARCH_64_BIT 1
|
| +#define V8_HOST_CAN_READ_UNALIGNED 1
|
| #elif defined(__ARMEL__)
|
| #define V8_HOST_ARCH_ARM 1
|
| #define V8_HOST_ARCH_32_BIT 1
|
| @@ -78,7 +82,7 @@ namespace internal {
|
| #define V8_HOST_ARCH_MIPS 1
|
| #define V8_HOST_ARCH_32_BIT 1
|
| #else
|
| -#error Host architecture was not detected as supported by v8
|
| +#error "Host architecture was not detected as supported by v8"
|
| #endif
|
|
|
| #if defined(__ARM_ARCH_7A__) || \
|
| @@ -95,11 +99,13 @@ namespace internal {
|
| // in the same way as the host architecture, that is, target the native
|
| // environment as presented by the compiler.
|
| #if !V8_TARGET_ARCH_X64 && !V8_TARGET_ARCH_IA32 && \
|
| - !V8_TARGET_ARCH_ARM && !V8_TARGET_ARCH_MIPS
|
| + !V8_TARGET_ARCH_ARM && !V8_TARGET_ARCH_A64 && !V8_TARGET_ARCH_MIPS
|
| #if defined(_M_X64) || defined(__x86_64__)
|
| #define V8_TARGET_ARCH_X64 1
|
| #elif defined(_M_IX86) || defined(__i386__)
|
| #define V8_TARGET_ARCH_IA32 1
|
| +#elif defined(__AARCH64EL__)
|
| +#define V8_TARGET_ARCH_A64 1
|
| #elif defined(__ARMEL__)
|
| #define V8_TARGET_ARCH_ARM 1
|
| #elif defined(__MIPSEL__)
|
| @@ -119,6 +125,9 @@ namespace internal {
|
| #if (V8_TARGET_ARCH_ARM && !(V8_HOST_ARCH_IA32 || V8_HOST_ARCH_ARM))
|
| #error Target architecture arm is only supported on arm and ia32 host
|
| #endif
|
| +#if (V8_TARGET_ARCH_A64 && !(V8_HOST_ARCH_X64 || V8_HOST_ARCH_A64))
|
| +#error Target architecture a64 is only supported on a64 and x64 host
|
| +#endif
|
| #if (V8_TARGET_ARCH_MIPS && !(V8_HOST_ARCH_IA32 || V8_HOST_ARCH_MIPS))
|
| #error Target architecture mips is only supported on mips and ia32 host
|
| #endif
|
| @@ -127,6 +136,9 @@ namespace internal {
|
| // Setting USE_SIMULATOR explicitly from the build script will force
|
| // the use of a simulated environment.
|
| #if !defined(USE_SIMULATOR)
|
| +#if (V8_TARGET_ARCH_A64 && !V8_HOST_ARCH_A64)
|
| +#define USE_SIMULATOR 1
|
| +#endif
|
| #if (V8_TARGET_ARCH_ARM && !V8_HOST_ARCH_ARM)
|
| #define USE_SIMULATOR 1
|
| #endif
|
| @@ -142,6 +154,8 @@ namespace internal {
|
| #define V8_TARGET_LITTLE_ENDIAN 1
|
| #elif V8_TARGET_ARCH_ARM
|
| #define V8_TARGET_LITTLE_ENDIAN 1
|
| +#elif V8_TARGET_ARCH_A64
|
| +#define V8_TARGET_LITTLE_ENDIAN 1
|
| #elif V8_TARGET_ARCH_MIPS
|
| #define V8_TARGET_LITTLE_ENDIAN 1
|
| #else
|
| @@ -376,6 +390,12 @@ F FUNCTION_CAST(Address addr) {
|
| #define DISABLE_ASAN
|
| #endif
|
|
|
| +#if V8_CC_GNU
|
| +#define V8_IMMEDIATE_CRASH() __builtin_trap()
|
| +#else
|
| +#define V8_IMMEDIATE_CRASH() ((void(*)())0)()
|
| +#endif
|
| +
|
|
|
| // -----------------------------------------------------------------------------
|
| // Forward declarations for frequently used classes
|
|
|