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 "src/compiler.h" | 8 #include "src/compiler.h" |
9 #include "src/hashmap.h" | 9 #include "src/hashmap.h" |
10 #include "src/heap-profiler.h" | 10 #include "src/heap-profiler.h" |
(...skipping 619 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
630 CodeSerializer(Isolate* isolate, SnapshotByteSink* sink, String* source, | 630 CodeSerializer(Isolate* isolate, SnapshotByteSink* sink, String* source, |
631 Code* main_code) | 631 Code* main_code) |
632 : Serializer(isolate, sink), source_(source), main_code_(main_code) { | 632 : Serializer(isolate, sink), source_(source), main_code_(main_code) { |
633 set_root_index_wave_front(Heap::kStrongRootListLength); | 633 set_root_index_wave_front(Heap::kStrongRootListLength); |
634 InitializeCodeAddressMap(); | 634 InitializeCodeAddressMap(); |
635 } | 635 } |
636 | 636 |
637 virtual void SerializeObject(Object* o, HowToCode how_to_code, | 637 virtual void SerializeObject(Object* o, HowToCode how_to_code, |
638 WhereToPoint where_to_point, int skip); | 638 WhereToPoint where_to_point, int skip); |
639 | 639 |
640 void SerializeBuiltin(Code* builtin, HowToCode how_to_code, | 640 void SerializeBuiltin(int builtin_index, HowToCode how_to_code, |
641 WhereToPoint where_to_point); | 641 WhereToPoint where_to_point); |
642 void SerializeCodeStub(Code* stub, HowToCode how_to_code, | 642 void SerializeIC(Code* ic, HowToCode how_to_code, |
| 643 WhereToPoint where_to_point); |
| 644 void SerializeCodeStub(uint32_t stub_key, HowToCode how_to_code, |
643 WhereToPoint where_to_point); | 645 WhereToPoint where_to_point); |
644 void SerializeSourceObject(HowToCode how_to_code, | 646 void SerializeSourceObject(HowToCode how_to_code, |
645 WhereToPoint where_to_point); | 647 WhereToPoint where_to_point); |
646 void SerializeHeapObject(HeapObject* heap_object, HowToCode how_to_code, | 648 void SerializeHeapObject(HeapObject* heap_object, HowToCode how_to_code, |
647 WhereToPoint where_to_point); | 649 WhereToPoint where_to_point); |
648 int AddCodeStubKey(uint32_t stub_key); | 650 int AddCodeStubKey(uint32_t stub_key); |
649 | 651 |
650 DisallowHeapAllocation no_gc_; | 652 DisallowHeapAllocation no_gc_; |
651 String* source_; | 653 String* source_; |
652 Code* main_code_; | 654 Code* main_code_; |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
750 // Following the header, we store, in sequential order | 752 // Following the header, we store, in sequential order |
751 // - code stub keys | 753 // - code stub keys |
752 // - serialization payload | 754 // - serialization payload |
753 | 755 |
754 ScriptData* script_data_; | 756 ScriptData* script_data_; |
755 bool owns_script_data_; | 757 bool owns_script_data_; |
756 }; | 758 }; |
757 } } // namespace v8::internal | 759 } } // namespace v8::internal |
758 | 760 |
759 #endif // V8_SERIALIZE_H_ | 761 #endif // V8_SERIALIZE_H_ |
OLD | NEW |