| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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_HEAP_SNAPSHOT_GENERATOR_H_ | 5 #ifndef V8_HEAP_SNAPSHOT_GENERATOR_H_ |
| 6 #define V8_HEAP_SNAPSHOT_GENERATOR_H_ | 6 #define V8_HEAP_SNAPSHOT_GENERATOR_H_ |
| 7 | 7 |
| 8 #include "src/strings-storage.h" | 8 #include "src/strings-storage.h" |
| 9 | 9 |
| 10 namespace v8 { | 10 namespace v8 { |
| (...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 212 SnapshotObjectId FindOrAddEntry(Address addr, | 212 SnapshotObjectId FindOrAddEntry(Address addr, |
| 213 unsigned int size, | 213 unsigned int size, |
| 214 bool accessed = true); | 214 bool accessed = true); |
| 215 bool MoveObject(Address from, Address to, int size); | 215 bool MoveObject(Address from, Address to, int size); |
| 216 void UpdateObjectSize(Address addr, int size); | 216 void UpdateObjectSize(Address addr, int size); |
| 217 SnapshotObjectId last_assigned_id() const { | 217 SnapshotObjectId last_assigned_id() const { |
| 218 return next_id_ - kObjectIdStep; | 218 return next_id_ - kObjectIdStep; |
| 219 } | 219 } |
| 220 | 220 |
| 221 void StopHeapObjectsTracking(); | 221 void StopHeapObjectsTracking(); |
| 222 SnapshotObjectId PushHeapObjectsStats(OutputStream* stream); | 222 SnapshotObjectId PushHeapObjectsStats(OutputStream* stream, |
| 223 int64_t* timestamp_us); |
| 223 const List<TimeInterval>& samples() const { return time_intervals_; } | 224 const List<TimeInterval>& samples() const { return time_intervals_; } |
| 224 size_t GetUsedMemorySize() const; | 225 size_t GetUsedMemorySize() const; |
| 225 | 226 |
| 226 SnapshotObjectId GenerateId(v8::RetainedObjectInfo* info); | 227 SnapshotObjectId GenerateId(v8::RetainedObjectInfo* info); |
| 227 | 228 |
| 228 static const int kObjectIdStep = 2; | 229 static const int kObjectIdStep = 2; |
| 229 static const SnapshotObjectId kInternalRootObjectId; | 230 static const SnapshotObjectId kInternalRootObjectId; |
| 230 static const SnapshotObjectId kGcRootsObjectId; | 231 static const SnapshotObjectId kGcRootsObjectId; |
| 231 static const SnapshotObjectId kGcRootsFirstSubrootId; | 232 static const SnapshotObjectId kGcRootsFirstSubrootId; |
| 232 static const SnapshotObjectId kFirstAvailableObjectId; | 233 static const SnapshotObjectId kFirstAvailableObjectId; |
| (...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 605 friend class HeapSnapshotJSONSerializerEnumerator; | 606 friend class HeapSnapshotJSONSerializerEnumerator; |
| 606 friend class HeapSnapshotJSONSerializerIterator; | 607 friend class HeapSnapshotJSONSerializerIterator; |
| 607 | 608 |
| 608 DISALLOW_COPY_AND_ASSIGN(HeapSnapshotJSONSerializer); | 609 DISALLOW_COPY_AND_ASSIGN(HeapSnapshotJSONSerializer); |
| 609 }; | 610 }; |
| 610 | 611 |
| 611 | 612 |
| 612 } } // namespace v8::internal | 613 } } // namespace v8::internal |
| 613 | 614 |
| 614 #endif // V8_HEAP_SNAPSHOT_GENERATOR_H_ | 615 #endif // V8_HEAP_SNAPSHOT_GENERATOR_H_ |
| OLD | NEW |