| 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_SERIALIZE_H_ | 5 #ifndef V8_SERIALIZE_H_ |
| 6 #define V8_SERIALIZE_H_ | 6 #define V8_SERIALIZE_H_ |
| 7 | 7 |
| 8 #include "hashmap.h" | 8 #include "hashmap.h" |
| 9 | 9 |
| 10 namespace v8 { | 10 namespace v8 { |
| (...skipping 433 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 444 int CurrentAllocationAddress(int space) const { | 444 int CurrentAllocationAddress(int space) const { |
| 445 ASSERT(space < kNumberOfSpaces); | 445 ASSERT(space < kNumberOfSpaces); |
| 446 return fullness_[space]; | 446 return fullness_[space]; |
| 447 } | 447 } |
| 448 | 448 |
| 449 Isolate* isolate() const { return isolate_; } | 449 Isolate* isolate() const { return isolate_; } |
| 450 static void RequestEnable(Isolate* isolate); | 450 static void RequestEnable(Isolate* isolate); |
| 451 static void InitializeOncePerProcess(); | 451 static void InitializeOncePerProcess(); |
| 452 static void TearDown(); | 452 static void TearDown(); |
| 453 | 453 |
| 454 static bool enabled() { | 454 static bool enabled(Isolate* isolate) { |
| 455 SerializationState state = static_cast<SerializationState>( | 455 SerializationState state = static_cast<SerializationState>( |
| 456 NoBarrier_Load(&serialization_state_)); | 456 NoBarrier_Load(&serialization_state_)); |
| 457 ASSERT(state != SERIALIZER_STATE_UNINITIALIZED); | 457 ASSERT(state != SERIALIZER_STATE_UNINITIALIZED); |
| 458 return state == SERIALIZER_STATE_ENABLED; | 458 return state == SERIALIZER_STATE_ENABLED; |
| 459 } | 459 } |
| 460 SerializationAddressMapper* address_mapper() { return &address_mapper_; } | 460 SerializationAddressMapper* address_mapper() { return &address_mapper_; } |
| 461 void PutRoot(int index, | 461 void PutRoot(int index, |
| 462 HeapObject* object, | 462 HeapObject* object, |
| 463 HowToCode how, | 463 HowToCode how, |
| 464 WhereToPoint where, | 464 WhereToPoint where, |
| (...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 643 private: | 643 private: |
| 644 virtual bool ShouldBeInThePartialSnapshotCache(HeapObject* o) { | 644 virtual bool ShouldBeInThePartialSnapshotCache(HeapObject* o) { |
| 645 return false; | 645 return false; |
| 646 } | 646 } |
| 647 }; | 647 }; |
| 648 | 648 |
| 649 | 649 |
| 650 } } // namespace v8::internal | 650 } } // namespace v8::internal |
| 651 | 651 |
| 652 #endif // V8_SERIALIZE_H_ | 652 #endif // V8_SERIALIZE_H_ |
| OLD | NEW |