| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef V8_GLOBALS_H_ | 5 #ifndef V8_GLOBALS_H_ |
| 6 #define V8_GLOBALS_H_ | 6 #define V8_GLOBALS_H_ |
| 7 | 7 |
| 8 #include "include/v8stdint.h" | 8 #include "include/v8stdint.h" |
| 9 | 9 |
| 10 #include "src/base/build_config.h" | 10 #include "src/base/build_config.h" |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 | 141 |
| 142 const int kDoubleSizeLog2 = 3; | 142 const int kDoubleSizeLog2 = 3; |
| 143 | 143 |
| 144 #if V8_HOST_ARCH_64_BIT | 144 #if V8_HOST_ARCH_64_BIT |
| 145 const int kPointerSizeLog2 = 3; | 145 const int kPointerSizeLog2 = 3; |
| 146 const intptr_t kIntptrSignBit = V8_INT64_C(0x8000000000000000); | 146 const intptr_t kIntptrSignBit = V8_INT64_C(0x8000000000000000); |
| 147 const uintptr_t kUintptrAllBitsSet = V8_UINT64_C(0xFFFFFFFFFFFFFFFF); | 147 const uintptr_t kUintptrAllBitsSet = V8_UINT64_C(0xFFFFFFFFFFFFFFFF); |
| 148 const bool kRequiresCodeRange = true; | 148 const bool kRequiresCodeRange = true; |
| 149 const size_t kMaximalCodeRangeSize = 512 * MB; | 149 const size_t kMaximalCodeRangeSize = 512 * MB; |
| 150 #if V8_OS_WIN | 150 #if V8_OS_WIN |
| 151 const size_t kMinimumCodeRangeSize = 2 * MB; | 151 const size_t kMinimumCodeRangeSize = 4 * MB; |
| 152 const size_t kReservedCodeRangePages = 1; | 152 const size_t kReservedCodeRangePages = 1; |
| 153 #else | 153 #else |
| 154 const size_t kMinimumCodeRangeSize = 1 * MB; | 154 const size_t kMinimumCodeRangeSize = 3 * MB; |
| 155 const size_t kReservedCodeRangePages = 0; | 155 const size_t kReservedCodeRangePages = 0; |
| 156 #endif | 156 #endif |
| 157 #else | 157 #else |
| 158 const int kPointerSizeLog2 = 2; | 158 const int kPointerSizeLog2 = 2; |
| 159 const intptr_t kIntptrSignBit = 0x80000000; | 159 const intptr_t kIntptrSignBit = 0x80000000; |
| 160 const uintptr_t kUintptrAllBitsSet = 0xFFFFFFFFu; | 160 const uintptr_t kUintptrAllBitsSet = 0xFFFFFFFFu; |
| 161 #if V8_TARGET_ARCH_X64 && V8_TARGET_ARCH_32_BIT | 161 #if V8_TARGET_ARCH_X64 && V8_TARGET_ARCH_32_BIT |
| 162 // x32 port also requires code range. | 162 // x32 port also requires code range. |
| 163 const bool kRequiresCodeRange = true; | 163 const bool kRequiresCodeRange = true; |
| 164 const size_t kMaximalCodeRangeSize = 256 * MB; | 164 const size_t kMaximalCodeRangeSize = 256 * MB; |
| 165 const size_t kMinimumCodeRangeSize = 1 * MB; | 165 const size_t kMinimumCodeRangeSize = 3 * MB; |
| 166 const size_t kReservedCodeRangePages = 0; | 166 const size_t kReservedCodeRangePages = 0; |
| 167 #else | 167 #else |
| 168 const bool kRequiresCodeRange = false; | 168 const bool kRequiresCodeRange = false; |
| 169 const size_t kMaximalCodeRangeSize = 0 * MB; | 169 const size_t kMaximalCodeRangeSize = 0 * MB; |
| 170 const size_t kMinimumCodeRangeSize = 0 * MB; | 170 const size_t kMinimumCodeRangeSize = 0 * MB; |
| 171 const size_t kReservedCodeRangePages = 0; | 171 const size_t kReservedCodeRangePages = 0; |
| 172 #endif | 172 #endif |
| 173 #endif | 173 #endif |
| 174 | 174 |
| 175 STATIC_ASSERT(kPointerSize == (1 << kPointerSizeLog2)); | 175 STATIC_ASSERT(kPointerSize == (1 << kPointerSizeLog2)); |
| (...skipping 627 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 803 | 803 |
| 804 inline bool IsConciseMethod(FunctionKind kind) { | 804 inline bool IsConciseMethod(FunctionKind kind) { |
| 805 DCHECK(IsValidFunctionKind(kind)); | 805 DCHECK(IsValidFunctionKind(kind)); |
| 806 return kind & FunctionKind::kConciseMethod; | 806 return kind & FunctionKind::kConciseMethod; |
| 807 } | 807 } |
| 808 } } // namespace v8::internal | 808 } } // namespace v8::internal |
| 809 | 809 |
| 810 namespace i = v8::internal; | 810 namespace i = v8::internal; |
| 811 | 811 |
| 812 #endif // V8_GLOBALS_H_ | 812 #endif // V8_GLOBALS_H_ |
| OLD | NEW |