| OLD | NEW |
| 1 // Copyright 2006-2009 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2009 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 28 matching lines...) Expand all Loading... |
| 39 #define V8_HOST_ARCH_X64 1 | 39 #define V8_HOST_ARCH_X64 1 |
| 40 #define V8_HOST_ARCH_64_BIT 1 | 40 #define V8_HOST_ARCH_64_BIT 1 |
| 41 #define V8_HOST_CAN_READ_UNALIGNED 1 | 41 #define V8_HOST_CAN_READ_UNALIGNED 1 |
| 42 #elif defined(_M_IX86) || defined(__i386__) | 42 #elif defined(_M_IX86) || defined(__i386__) |
| 43 #define V8_HOST_ARCH_IA32 1 | 43 #define V8_HOST_ARCH_IA32 1 |
| 44 #define V8_HOST_ARCH_32_BIT 1 | 44 #define V8_HOST_ARCH_32_BIT 1 |
| 45 #define V8_HOST_CAN_READ_UNALIGNED 1 | 45 #define V8_HOST_CAN_READ_UNALIGNED 1 |
| 46 #elif defined(__ARMEL__) | 46 #elif defined(__ARMEL__) |
| 47 #define V8_HOST_ARCH_ARM 1 | 47 #define V8_HOST_ARCH_ARM 1 |
| 48 #define V8_HOST_ARCH_32_BIT 1 | 48 #define V8_HOST_ARCH_32_BIT 1 |
| 49 #elif defined(_MIPS_ARCH_MIPS32R2) |
| 50 #define V8_HOST_ARCH_MIPS 1 |
| 51 #define V8_HOST_ARCH_32_BIT 1 |
| 49 #else | 52 #else |
| 50 #error Your host architecture was not detected as supported by v8 | 53 #error Your host architecture was not detected as supported by v8 |
| 51 #endif | 54 #endif |
| 52 | 55 |
| 53 #if defined(V8_TARGET_ARCH_X64) || defined(V8_TARGET_ARCH_IA32) | 56 #if defined(V8_TARGET_ARCH_X64) || defined(V8_TARGET_ARCH_IA32) |
| 54 #define V8_TARGET_CAN_READ_UNALIGNED 1 | 57 #define V8_TARGET_CAN_READ_UNALIGNED 1 |
| 55 #elif V8_TARGET_ARCH_ARM | 58 #elif V8_TARGET_ARCH_ARM |
| 59 #elif V8_TARGET_ARCH_MIPS |
| 56 #else | 60 #else |
| 57 #error Your target architecture is not supported by v8 | 61 #error Your target architecture is not supported by v8 |
| 58 #endif | 62 #endif |
| 59 | 63 |
| 60 // Support for alternative bool type. This is only enabled if the code is | 64 // Support for alternative bool type. This is only enabled if the code is |
| 61 // compiled with USE_MYBOOL defined. This catches some nasty type bugs. | 65 // compiled with USE_MYBOOL defined. This catches some nasty type bugs. |
| 62 // For instance, 'bool b = "false";' results in b == true! This is a hidden | 66 // For instance, 'bool b = "false";' results in b == true! This is a hidden |
| 63 // source of bugs. | 67 // source of bugs. |
| 64 // However, redefining the bool type does have some negative impact on some | 68 // However, redefining the bool type does have some negative impact on some |
| 65 // platforms. It gives rise to compiler warnings (i.e. with | 69 // platforms. It gives rise to compiler warnings (i.e. with |
| (...skipping 539 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 605 | 609 |
| 606 // Feature flags bit positions. They are mostly based on the CPUID spec. | 610 // Feature flags bit positions. They are mostly based on the CPUID spec. |
| 607 // (We assign CPUID itself to one of the currently reserved bits -- | 611 // (We assign CPUID itself to one of the currently reserved bits -- |
| 608 // feel free to change this if needed.) | 612 // feel free to change this if needed.) |
| 609 enum CpuFeature { SSE3 = 32, // x86 | 613 enum CpuFeature { SSE3 = 32, // x86 |
| 610 SSE2 = 26, // x86 | 614 SSE2 = 26, // x86 |
| 611 CMOV = 15, // x86 | 615 CMOV = 15, // x86 |
| 612 RDTSC = 4, // x86 | 616 RDTSC = 4, // x86 |
| 613 CPUID = 10, // x86 | 617 CPUID = 10, // x86 |
| 614 VFP3 = 1, // ARM | 618 VFP3 = 1, // ARM |
| 619 ARMv7 = 2, // ARM |
| 615 SAHF = 0}; // x86 | 620 SAHF = 0}; // x86 |
| 616 | 621 |
| 617 } } // namespace v8::internal | 622 } } // namespace v8::internal |
| 618 | 623 |
| 619 #endif // V8_GLOBALS_H_ | 624 #endif // V8_GLOBALS_H_ |
| OLD | NEW |