Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(454)

Side by Side Diff: src/globals.h

Issue 1790001: Add a V8 specific target architecture to the GYP file... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 10 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | tools/gyp/v8.gyp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
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) 49 #elif defined(_MIPS_ARCH_MIPS32R2)
50 #define V8_HOST_ARCH_MIPS 1 50 #define V8_HOST_ARCH_MIPS 1
51 #define V8_HOST_ARCH_32_BIT 1 51 #define V8_HOST_ARCH_32_BIT 1
52 #else 52 #else
53 #error Your host architecture was not detected as supported by v8 53 #error Host architecture was not detected as supported by v8
54 #endif 54 #endif
55 55
56 // Check for supported combinations of host and target architectures.
57 #if defined(V8_TARGET_ARCH_IA32) && !defined(V8_HOST_ARCH_IA32)
58 #error Target architecture ia32 is only supported on ia32 host
59 #endif
60 #if defined(V8_TARGET_ARCH_X64) && !defined(V8_HOST_ARCH_X64)
61 #error Target architecture x64 is only supported on x64 host
62 #endif
63 #if (defined(V8_TARGET_ARCH_ARM) && \
64 !(defined(V8_HOST_ARCH_IA32) || defined(V8_HOST_ARCH_ARM)))
65 #error Target architecture arm is only supported on arm and ia32 host
66 #endif
67 #if (defined(V8_TARGET_ARCH_MIPS) && \
68 !(defined(V8_HOST_ARCH_IA32) || defined(V8_HOST_ARCH_MIPS)))
69 #error Target architecture mips is only supported on mips and ia32 host
70 #endif
71
72 // Define unaligned read for the target architectures supporting it.
56 #if defined(V8_TARGET_ARCH_X64) || defined(V8_TARGET_ARCH_IA32) 73 #if defined(V8_TARGET_ARCH_X64) || defined(V8_TARGET_ARCH_IA32)
57 #define V8_TARGET_CAN_READ_UNALIGNED 1 74 #define V8_TARGET_CAN_READ_UNALIGNED 1
58 #elif V8_TARGET_ARCH_ARM 75 #elif V8_TARGET_ARCH_ARM
59 #elif V8_TARGET_ARCH_MIPS 76 #elif V8_TARGET_ARCH_MIPS
60 #else 77 #else
61 #error Your target architecture is not supported by v8 78 #error Target architecture is not supported by v8
62 #endif 79 #endif
63 80
64 // Support for alternative bool type. This is only enabled if the code is 81 // Support for alternative bool type. This is only enabled if the code is
65 // compiled with USE_MYBOOL defined. This catches some nasty type bugs. 82 // compiled with USE_MYBOOL defined. This catches some nasty type bugs.
66 // For instance, 'bool b = "false";' results in b == true! This is a hidden 83 // For instance, 'bool b = "false";' results in b == true! This is a hidden
67 // source of bugs. 84 // source of bugs.
68 // However, redefining the bool type does have some negative impact on some 85 // However, redefining the bool type does have some negative impact on some
69 // platforms. It gives rise to compiler warnings (i.e. with 86 // platforms. It gives rise to compiler warnings (i.e. with
70 // MSVC) in the API header files when mixing code that uses the standard 87 // MSVC) in the API header files when mixing code that uses the standard
71 // bool with code that uses the redefined version. 88 // bool with code that uses the redefined version.
(...skipping 534 matching lines...) Expand 10 before | Expand all | Expand 10 after
606 CMOV = 15, // x86 623 CMOV = 15, // x86
607 RDTSC = 4, // x86 624 RDTSC = 4, // x86
608 CPUID = 10, // x86 625 CPUID = 10, // x86
609 VFP3 = 1, // ARM 626 VFP3 = 1, // ARM
610 ARMv7 = 2, // ARM 627 ARMv7 = 2, // ARM
611 SAHF = 0}; // x86 628 SAHF = 0}; // x86
612 629
613 } } // namespace v8::internal 630 } } // namespace v8::internal
614 631
615 #endif // V8_GLOBALS_H_ 632 #endif // V8_GLOBALS_H_
OLDNEW
« no previous file with comments | « no previous file | tools/gyp/v8.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698