| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef VM_SNAPSHOT_H_ | 5 #ifndef VM_SNAPSHOT_H_ |
| 6 #define VM_SNAPSHOT_H_ | 6 #define VM_SNAPSHOT_H_ |
| 7 | 7 |
| 8 #include "platform/assert.h" | 8 #include "platform/assert.h" |
| 9 #include "vm/allocation.h" | 9 #include "vm/allocation.h" |
| 10 #include "vm/bitfield.h" | 10 #include "vm/bitfield.h" |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 80 class RawSubtypeTestCache; | 80 class RawSubtypeTestCache; |
| 81 class RawTokenStream; | 81 class RawTokenStream; |
| 82 class RawTwoByteString; | 82 class RawTwoByteString; |
| 83 class RawType; | 83 class RawType; |
| 84 class RawTypeArguments; | 84 class RawTypeArguments; |
| 85 class RawTypedData; | 85 class RawTypedData; |
| 86 class RawTypeParameter; | 86 class RawTypeParameter; |
| 87 class RawTypeRef; | 87 class RawTypeRef; |
| 88 class RawUnhandledException; | 88 class RawUnhandledException; |
| 89 class RawUnresolvedClass; | 89 class RawUnresolvedClass; |
| 90 class RawWeakProperty; |
| 90 class String; | 91 class String; |
| 91 class TokenStream; | 92 class TokenStream; |
| 92 class TypeArguments; | 93 class TypeArguments; |
| 93 class TypedData; | 94 class TypedData; |
| 94 class UnhandledException; | 95 class UnhandledException; |
| 95 | 96 |
| 96 // Serialized object header encoding is as follows: | 97 // Serialized object header encoding is as follows: |
| 97 // - Smi: the Smi value is written as is (last bit is not tagged). | 98 // - Smi: the Smi value is written as is (last bit is not tagged). |
| 98 // - VM object (from VM isolate): (object id in vm isolate | 0x3) | 99 // - VM object (from VM isolate): (object id in vm isolate | 0x3) |
| 99 // This valus is serialized as a negative number. | 100 // This valus is serialized as a negative number. |
| (...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 437 RawLiteralToken* NewLiteralToken(); | 438 RawLiteralToken* NewLiteralToken(); |
| 438 RawGrowableObjectArray* NewGrowableObjectArray(); | 439 RawGrowableObjectArray* NewGrowableObjectArray(); |
| 439 RawFloat32x4* NewFloat32x4(float v0, float v1, float v2, float v3); | 440 RawFloat32x4* NewFloat32x4(float v0, float v1, float v2, float v3); |
| 440 RawInt32x4* NewInt32x4(uint32_t v0, uint32_t v1, uint32_t v2, uint32_t v3); | 441 RawInt32x4* NewInt32x4(uint32_t v0, uint32_t v1, uint32_t v2, uint32_t v3); |
| 441 RawFloat64x2* NewFloat64x2(double v0, double v1); | 442 RawFloat64x2* NewFloat64x2(double v0, double v1); |
| 442 RawApiError* NewApiError(); | 443 RawApiError* NewApiError(); |
| 443 RawLanguageError* NewLanguageError(); | 444 RawLanguageError* NewLanguageError(); |
| 444 RawUnhandledException* NewUnhandledException(); | 445 RawUnhandledException* NewUnhandledException(); |
| 445 RawObject* NewInteger(int64_t value); | 446 RawObject* NewInteger(int64_t value); |
| 446 RawStacktrace* NewStacktrace(); | 447 RawStacktrace* NewStacktrace(); |
| 448 RawWeakProperty* NewWeakProperty(); |
| 447 | 449 |
| 448 RawInstructions* GetInstructionsAt(int32_t offset, uword expected_tags) { | 450 RawInstructions* GetInstructionsAt(int32_t offset, uword expected_tags) { |
| 449 return instructions_reader_->GetInstructionsAt(offset, expected_tags); | 451 return instructions_reader_->GetInstructionsAt(offset, expected_tags); |
| 450 } | 452 } |
| 451 | 453 |
| 452 const uint8_t* instructions_buffer_; | 454 const uint8_t* instructions_buffer_; |
| 453 | 455 |
| 454 protected: | 456 protected: |
| 455 SnapshotReader(const uint8_t* buffer, | 457 SnapshotReader(const uint8_t* buffer, |
| 456 intptr_t size, | 458 intptr_t size, |
| (...skipping 671 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1128 private: | 1130 private: |
| 1129 SnapshotWriter* writer_; | 1131 SnapshotWriter* writer_; |
| 1130 bool as_references_; | 1132 bool as_references_; |
| 1131 | 1133 |
| 1132 DISALLOW_COPY_AND_ASSIGN(SnapshotWriterVisitor); | 1134 DISALLOW_COPY_AND_ASSIGN(SnapshotWriterVisitor); |
| 1133 }; | 1135 }; |
| 1134 | 1136 |
| 1135 } // namespace dart | 1137 } // namespace dart |
| 1136 | 1138 |
| 1137 #endif // VM_SNAPSHOT_H_ | 1139 #endif // VM_SNAPSHOT_H_ |
| OLD | NEW |