| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 387 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 398 | 398 |
| 399 | 399 |
| 400 // AccessorCallback | 400 // AccessorCallback |
| 401 struct AccessorDescriptor { | 401 struct AccessorDescriptor { |
| 402 MaybeObject* (*getter)(Object* object, void* data); | 402 MaybeObject* (*getter)(Object* object, void* data); |
| 403 MaybeObject* (*setter)(JSObject* object, Object* value, void* data); | 403 MaybeObject* (*setter)(JSObject* object, Object* value, void* data); |
| 404 void* data; | 404 void* data; |
| 405 }; | 405 }; |
| 406 | 406 |
| 407 | 407 |
| 408 // Logging and profiling. | 408 // Logging and profiling. A StateTag represents a possible state of |
| 409 // A StateTag represents a possible state of the VM. When compiled with | 409 // the VM. The logger maintains a stack of these. Creating a VMState |
| 410 // ENABLE_VMSTATE_TRACKING, the logger maintains a stack of these. | 410 // object enters a state by pushing on the stack, and destroying a |
| 411 // Creating a VMState object enters a state by pushing on the stack, and | 411 // VMState object leaves a state by popping the current state from the |
| 412 // destroying a VMState object leaves a state by popping the current state | 412 // stack. |
| 413 // from the stack. | |
| 414 | 413 |
| 415 #define STATE_TAG_LIST(V) \ | 414 #define STATE_TAG_LIST(V) \ |
| 416 V(JS) \ | 415 V(JS) \ |
| 417 V(GC) \ | 416 V(GC) \ |
| 418 V(COMPILER) \ | 417 V(COMPILER) \ |
| 419 V(OTHER) \ | 418 V(OTHER) \ |
| 420 V(EXTERNAL) | 419 V(EXTERNAL) |
| 421 | 420 |
| 422 enum StateTag { | 421 enum StateTag { |
| 423 #define DEF_STATE_TAG(name) name, | 422 #define DEF_STATE_TAG(name) name, |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 510 }; | 509 }; |
| 511 | 510 |
| 512 | 511 |
| 513 // Used to specify whether a receiver is implicitly or explicitly | 512 // Used to specify whether a receiver is implicitly or explicitly |
| 514 // provided to a call. | 513 // provided to a call. |
| 515 enum CallKind { | 514 enum CallKind { |
| 516 CALL_AS_METHOD = 0, | 515 CALL_AS_METHOD = 0, |
| 517 CALL_AS_FUNCTION | 516 CALL_AS_FUNCTION |
| 518 }; | 517 }; |
| 519 | 518 |
| 519 |
| 520 static const uint32_t kHoleNanUpper32 = 0x7FFFFFFF; |
| 521 static const uint32_t kHoleNanLower32 = 0xFFFFFFFF; |
| 522 static const uint32_t kNaNOrInfinityLowerBoundUpper32 = 0x7FF00000; |
| 523 |
| 524 const uint64_t kHoleNanInt64 = |
| 525 (static_cast<uint64_t>(kHoleNanUpper32) << 32) | kHoleNanLower32; |
| 526 const uint64_t kLastNonNaNInt64 = |
| 527 (static_cast<uint64_t>(kNaNOrInfinityLowerBoundUpper32) << 32); |
| 528 |
| 520 } } // namespace v8::internal | 529 } } // namespace v8::internal |
| 521 | 530 |
| 522 #endif // V8_V8GLOBALS_H_ | 531 #endif // V8_V8GLOBALS_H_ |
| OLD | NEW |