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_OBJECT_H_ | 5 #ifndef VM_OBJECT_H_ |
6 #define VM_OBJECT_H_ | 6 #define VM_OBJECT_H_ |
7 | 7 |
8 #include "include/dart_api.h" | 8 #include "include/dart_api.h" |
9 #include "platform/assert.h" | 9 #include "platform/assert.h" |
10 #include "platform/utils.h" | 10 #include "platform/utils.h" |
(...skipping 13 matching lines...) Expand all Loading... |
24 // Forward declarations. | 24 // Forward declarations. |
25 #define DEFINE_FORWARD_DECLARATION(clazz) \ | 25 #define DEFINE_FORWARD_DECLARATION(clazz) \ |
26 class clazz; | 26 class clazz; |
27 CLASS_LIST(DEFINE_FORWARD_DECLARATION) | 27 CLASS_LIST(DEFINE_FORWARD_DECLARATION) |
28 #undef DEFINE_FORWARD_DECLARATION | 28 #undef DEFINE_FORWARD_DECLARATION |
29 class Api; | 29 class Api; |
30 class ArgumentsDescriptor; | 30 class ArgumentsDescriptor; |
31 class Assembler; | 31 class Assembler; |
32 class Closure; | 32 class Closure; |
33 class Code; | 33 class Code; |
| 34 class DisassemblyFormatter; |
34 class DeoptInstr; | 35 class DeoptInstr; |
35 class FinalizablePersistentHandle; | 36 class FinalizablePersistentHandle; |
36 class LocalScope; | 37 class LocalScope; |
37 class ReusableHandleScope; | 38 class ReusableHandleScope; |
38 class ReusableObjectHandleScope; | 39 class ReusableObjectHandleScope; |
39 class Symbols; | 40 class Symbols; |
40 | 41 |
41 #if defined(DEBUG) | 42 #if defined(DEBUG) |
42 #define CHECK_HANDLE() CheckHandle(); | 43 #define CHECK_HANDLE() CheckHandle(); |
43 #else | 44 #else |
(...skipping 3192 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3236 RawDeoptInfo* GetDeoptInfoAtPc(uword pc, intptr_t* deopt_reason) const; | 3237 RawDeoptInfo* GetDeoptInfoAtPc(uword pc, intptr_t* deopt_reason) const; |
3237 | 3238 |
3238 // Returns null if there is no static call at 'pc'. | 3239 // Returns null if there is no static call at 'pc'. |
3239 RawFunction* GetStaticCallTargetFunctionAt(uword pc) const; | 3240 RawFunction* GetStaticCallTargetFunctionAt(uword pc) const; |
3240 // Returns null if there is no static call at 'pc'. | 3241 // Returns null if there is no static call at 'pc'. |
3241 RawCode* GetStaticCallTargetCodeAt(uword pc) const; | 3242 RawCode* GetStaticCallTargetCodeAt(uword pc) const; |
3242 // Aborts if there is no static call at 'pc'. | 3243 // Aborts if there is no static call at 'pc'. |
3243 void SetStaticCallTargetCodeAt(uword pc, const Code& code) const; | 3244 void SetStaticCallTargetCodeAt(uword pc, const Code& code) const; |
3244 | 3245 |
3245 void Disassemble() const; | 3246 void Disassemble() const; |
| 3247 void Disassemble(DisassemblyFormatter* formatter) const; |
3246 | 3248 |
3247 class Comments : public ZoneAllocated { | 3249 class Comments : public ZoneAllocated { |
3248 public: | 3250 public: |
3249 static Comments& New(intptr_t count); | 3251 static Comments& New(intptr_t count); |
3250 | 3252 |
3251 intptr_t Length() const; | 3253 intptr_t Length() const; |
3252 | 3254 |
3253 void SetPCOffsetAt(intptr_t idx, intptr_t pc_offset); | 3255 void SetPCOffsetAt(intptr_t idx, intptr_t pc_offset); |
3254 void SetCommentAt(intptr_t idx, const String& comment); | 3256 void SetCommentAt(intptr_t idx, const String& comment); |
3255 | 3257 |
(...skipping 3313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6569 | 6571 |
6570 | 6572 |
6571 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, | 6573 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, |
6572 intptr_t index) { | 6574 intptr_t index) { |
6573 return array.At((index * kEntryLength) + kTargetFunctionIndex); | 6575 return array.At((index * kEntryLength) + kTargetFunctionIndex); |
6574 } | 6576 } |
6575 | 6577 |
6576 } // namespace dart | 6578 } // namespace dart |
6577 | 6579 |
6578 #endif // VM_OBJECT_H_ | 6580 #endif // VM_OBJECT_H_ |
OLD | NEW |