OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 230 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
241 | 241 |
242 const int kDoubleSizeLog2 = 3; | 242 const int kDoubleSizeLog2 = 3; |
243 | 243 |
244 // Size of the state of a the random number generator. | 244 // Size of the state of a the random number generator. |
245 const int kRandomStateSize = 2 * kIntSize; | 245 const int kRandomStateSize = 2 * kIntSize; |
246 | 246 |
247 #if V8_HOST_ARCH_64_BIT | 247 #if V8_HOST_ARCH_64_BIT |
248 const int kPointerSizeLog2 = 3; | 248 const int kPointerSizeLog2 = 3; |
249 const intptr_t kIntptrSignBit = V8_INT64_C(0x8000000000000000); | 249 const intptr_t kIntptrSignBit = V8_INT64_C(0x8000000000000000); |
250 const uintptr_t kUintptrAllBitsSet = V8_UINT64_C(0xFFFFFFFFFFFFFFFF); | 250 const uintptr_t kUintptrAllBitsSet = V8_UINT64_C(0xFFFFFFFFFFFFFFFF); |
251 const bool kIs64BitArch = true; | |
252 #else | 251 #else |
253 const int kPointerSizeLog2 = 2; | 252 const int kPointerSizeLog2 = 2; |
254 const intptr_t kIntptrSignBit = 0x80000000; | 253 const intptr_t kIntptrSignBit = 0x80000000; |
255 const uintptr_t kUintptrAllBitsSet = 0xFFFFFFFFu; | 254 const uintptr_t kUintptrAllBitsSet = 0xFFFFFFFFu; |
256 const bool kIs64BitArch = false; | |
257 #endif | 255 #endif |
258 | 256 |
259 const int kBitsPerByte = 8; | 257 const int kBitsPerByte = 8; |
260 const int kBitsPerByteLog2 = 3; | 258 const int kBitsPerByteLog2 = 3; |
261 const int kBitsPerPointer = kPointerSize * kBitsPerByte; | 259 const int kBitsPerPointer = kPointerSize * kBitsPerByte; |
262 const int kBitsPerInt = kIntSize * kBitsPerByte; | 260 const int kBitsPerInt = kIntSize * kBitsPerByte; |
263 | 261 |
264 // IEEE 754 single precision floating point number bit layout. | 262 // IEEE 754 single precision floating point number bit layout. |
265 const uint32_t kBinary32SignMask = 0x80000000u; | 263 const uint32_t kBinary32SignMask = 0x80000000u; |
266 const uint32_t kBinary32ExponentMask = 0x7f800000u; | 264 const uint32_t kBinary32ExponentMask = 0x7f800000u; |
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
402 // the backend, so both modes are represented by the kStrictMode value. | 400 // the backend, so both modes are represented by the kStrictMode value. |
403 enum StrictModeFlag { | 401 enum StrictModeFlag { |
404 kNonStrictMode, | 402 kNonStrictMode, |
405 kStrictMode | 403 kStrictMode |
406 }; | 404 }; |
407 | 405 |
408 | 406 |
409 } } // namespace v8::internal | 407 } } // namespace v8::internal |
410 | 408 |
411 #endif // V8_GLOBALS_H_ | 409 #endif // V8_GLOBALS_H_ |
OLD | NEW |