| OLD | NEW |
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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_GRAPH_H_ | 5 #ifndef VM_OBJECT_GRAPH_H_ |
| 6 #define VM_OBJECT_GRAPH_H_ | 6 #define VM_OBJECT_GRAPH_H_ |
| 7 | 7 |
| 8 #include "vm/allocation.h" | 8 #include "vm/allocation.h" |
| 9 #include "vm/object.h" | 9 #include "vm/object.h" |
| 10 | 10 |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 82 intptr_t RetainingPath(Object* obj, const Array& path); | 82 intptr_t RetainingPath(Object* obj, const Array& path); |
| 83 | 83 |
| 84 // Find the objects that reference 'obj'. Populates the provided array with | 84 // Find the objects that reference 'obj'. Populates the provided array with |
| 85 // pairs of (object pointing to 'obj', offset of pointer in words), as far as | 85 // pairs of (object pointing to 'obj', offset of pointer in words), as far as |
| 86 // there is room. Returns the number of objects found. | 86 // there is room. Returns the number of objects found. |
| 87 // | 87 // |
| 88 // An object for which this function answers no inbound references might still | 88 // An object for which this function answers no inbound references might still |
| 89 // be live due to references from the stack or embedder handles. | 89 // be live due to references from the stack or embedder handles. |
| 90 intptr_t InboundReferences(Object* obj, const Array& references); | 90 intptr_t InboundReferences(Object* obj, const Array& references); |
| 91 | 91 |
| 92 // Write the isolate's object graph to 'stream'. Smis and nulls are omitted. |
| 93 // TODO(koda): Document format; support streaming/chunking. |
| 94 void Serialize(WriteStream* stream); |
| 95 |
| 92 private: | 96 private: |
| 93 DISALLOW_IMPLICIT_CONSTRUCTORS(ObjectGraph); | 97 DISALLOW_IMPLICIT_CONSTRUCTORS(ObjectGraph); |
| 94 }; | 98 }; |
| 95 | 99 |
| 96 } // namespace dart | 100 } // namespace dart |
| 97 | 101 |
| 98 #endif // VM_OBJECT_GRAPH_H_ | 102 #endif // VM_OBJECT_GRAPH_H_ |
| OLD | NEW |