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 456 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
467 int CurrentAllocationAddress(int space) const { | 467 int CurrentAllocationAddress(int space) const { |
468 ASSERT(space < kNumberOfSpaces); | 468 ASSERT(space < kNumberOfSpaces); |
469 return fullness_[space]; | 469 return fullness_[space]; |
470 } | 470 } |
471 | 471 |
472 Isolate* isolate() const { return isolate_; } | 472 Isolate* isolate() const { return isolate_; } |
473 static void RequestEnable(Isolate* isolate); | 473 static void RequestEnable(Isolate* isolate); |
474 static void InitializeOncePerProcess(); | 474 static void InitializeOncePerProcess(); |
475 static void TearDown(); | 475 static void TearDown(); |
476 | 476 |
477 static bool enabled() { | 477 static bool enabled(Isolate* isolate) { |
478 SerializationState state = static_cast<SerializationState>( | 478 SerializationState state = static_cast<SerializationState>( |
479 NoBarrier_Load(&serialization_state_)); | 479 NoBarrier_Load(&serialization_state_)); |
480 ASSERT(state != SERIALIZER_STATE_UNINITIALIZED); | 480 ASSERT(state != SERIALIZER_STATE_UNINITIALIZED); |
481 return state == SERIALIZER_STATE_ENABLED; | 481 return state == SERIALIZER_STATE_ENABLED; |
482 } | 482 } |
483 SerializationAddressMapper* address_mapper() { return &address_mapper_; } | 483 SerializationAddressMapper* address_mapper() { return &address_mapper_; } |
484 void PutRoot(int index, | 484 void PutRoot(int index, |
485 HeapObject* object, | 485 HeapObject* object, |
486 HowToCode how, | 486 HowToCode how, |
487 WhereToPoint where, | 487 WhereToPoint where, |
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
666 private: | 666 private: |
667 virtual bool ShouldBeInThePartialSnapshotCache(HeapObject* o) { | 667 virtual bool ShouldBeInThePartialSnapshotCache(HeapObject* o) { |
668 return false; | 668 return false; |
669 } | 669 } |
670 }; | 670 }; |
671 | 671 |
672 | 672 |
673 } } // namespace v8::internal | 673 } } // namespace v8::internal |
674 | 674 |
675 #endif // V8_SERIALIZE_H_ | 675 #endif // V8_SERIALIZE_H_ |
OLD | NEW |