V8 Project
|
#include <heap-profiler.h>
Private Member Functions | |
Heap * | heap () const |
Private Attributes | |
SmartPointer< HeapObjectsMap > | ids_ |
List< HeapSnapshot * > | snapshots_ |
SmartPointer< StringsStorage > | names_ |
unsigned | next_snapshot_uid_ |
List< v8::HeapProfiler::WrapperInfoCallback > | wrapper_callbacks_ |
SmartPointer< AllocationTracker > | allocation_tracker_ |
bool | is_tracking_object_moves_ |
Definition at line 17 of file heap-profiler.h.
|
explicit |
Definition at line 15 of file heap-profiler.cc.
v8::internal::HeapProfiler::~HeapProfiler | ( | ) |
Definition at line 28 of file heap-profiler.cc.
References v8::internal::DeleteHeapSnapshot(), and snapshots_.
|
inline |
Definition at line 35 of file heap-profiler.h.
References allocation_tracker_.
Referenced by v8::internal::V8HeapExplorer::AddEntry(), v8::internal::HeapSnapshotJSONSerializer::Serialize(), v8::internal::HeapSnapshotJSONSerializer::SerializeSnapshot(), v8::internal::HeapSnapshotJSONSerializer::SerializeTraceNodeInfos(), and v8::internal::HeapSnapshotJSONSerializer::SerializeTraceTree().
Definition at line 155 of file heap-profiler.cc.
References allocation_tracker_, and size.
void v8::internal::HeapProfiler::ClearHeapObjectMap | ( | ) |
Definition at line 192 of file heap-profiler.cc.
References heap(), ids_, is_tracking_allocations(), and is_tracking_object_moves_.
void v8::internal::HeapProfiler::DefineWrapperClass | ( | uint16_t | class_id, |
v8::HeapProfiler::WrapperInfoCallback | callback | ||
) |
Definition at line 46 of file heap-profiler.cc.
References v8::internal::List< T, AllocationPolicy >::AddBlock(), DCHECK, v8::HeapProfiler::kPersistentHandleNoClassId, NULL, and wrapper_callbacks_.
void v8::internal::HeapProfiler::DeleteAllSnapshots | ( | ) |
Definition at line 34 of file heap-profiler.cc.
References v8::internal::DeleteHeapSnapshot(), heap(), names_, and snapshots_.
Referenced by v8::HeapSnapshot::Delete().
v8::RetainedObjectInfo * v8::internal::HeapProfiler::ExecuteWrapperClassCallback | ( | uint16_t | class_id, |
Object ** | wrapper | ||
) |
Definition at line 57 of file heap-profiler.cc.
References NULL, v8::Utils::ToLocal(), and wrapper_callbacks_.
Referenced by v8::internal::NativeObjectsExplorer::VisitSubtreeWrapper().
Handle< HeapObject > v8::internal::HeapProfiler::FindHeapObjectById | ( | SnapshotObjectId | id | ) |
size_t v8::internal::HeapProfiler::GetMemorySizeUsedByProfiler | ( | ) |
Definition at line 118 of file heap-profiler.cc.
References v8::internal::GetMemoryUsedByList(), ids_, names_, size, and snapshots_.
HeapSnapshot * v8::internal::HeapProfiler::GetSnapshot | ( | int | index | ) |
Definition at line 135 of file heap-profiler.cc.
References snapshots_.
SnapshotObjectId v8::internal::HeapProfiler::GetSnapshotObjectId | ( | Handle< Object > | obj | ) |
Definition at line 140 of file heap-profiler.cc.
References ids_, and v8::HeapProfiler::kUnknownObjectId.
int v8::internal::HeapProfiler::GetSnapshotsCount | ( | ) |
Definition at line 130 of file heap-profiler.cc.
References snapshots_.
Referenced by v8::HeapSnapshot::Delete().
|
inlineprivate |
Definition at line 70 of file heap-profiler.h.
References ids_.
Referenced by ClearHeapObjectMap(), DeleteAllSnapshots(), FindHeapObjectById(), SetRetainedObjectInfo(), StartHeapObjectsTracking(), StopHeapObjectsTracking(), and TakeSnapshot().
|
inline |
Definition at line 38 of file heap-profiler.h.
References ids_.
Referenced by v8::internal::HeapSnapshot::RememberLastJSObjectId().
|
inline |
Definition at line 62 of file heap-profiler.h.
References allocation_tracker_.
Referenced by ClearHeapObjectMap(), StartHeapObjectsTracking(), and StopHeapObjectsTracking().
|
inline |
Definition at line 61 of file heap-profiler.h.
References is_tracking_object_moves_.
Referenced by v8::internal::Heap::OnMoveEvent(), and v8::internal::Heap::SelectScavengingVisitorsTable().
|
inline |
Definition at line 147 of file heap-profiler.cc.
References allocation_tracker_, ids_, size, and to().
Referenced by v8::internal::Heap::OnMoveEvent().
SnapshotObjectId v8::internal::HeapProfiler::PushHeapObjectsStats | ( | OutputStream * | stream | ) |
Definition at line 104 of file heap-profiler.cc.
References ids_.
void v8::internal::HeapProfiler::RemoveSnapshot | ( | HeapSnapshot * | snapshot | ) |
Definition at line 41 of file heap-profiler.cc.
References snapshot(), and snapshots_.
Referenced by v8::internal::HeapSnapshot::Delete().
void v8::internal::HeapProfiler::SetRetainedObjectInfo | ( | UniqueId | id, |
RetainedObjectInfo * | info | ||
) |
Definition at line 168 of file heap-profiler.cc.
References v8::internal::Isolate::global_handles(), heap(), v8::internal::Heap::isolate(), and v8::internal::GlobalHandles::SetRetainedObjectInfo().
void v8::internal::HeapProfiler::StartHeapObjectsTracking | ( | bool | track_allocations | ) |
Definition at line 93 of file heap-profiler.cc.
References allocation_tracker_, DCHECK, v8::internal::Heap::DisableInlineAllocation(), heap(), ids_, is_tracking_allocations(), is_tracking_object_moves_, and names_.
void v8::internal::HeapProfiler::StopHeapObjectsTracking | ( | ) |
Definition at line 109 of file heap-profiler.cc.
References allocation_tracker_, v8::internal::Heap::EnableInlineAllocation(), heap(), ids_, is_tracking_allocations(), and NULL.
HeapSnapshot * v8::internal::HeapProfiler::TakeSnapshot | ( | const char * | name, |
v8::ActivityControl * | control, | ||
v8::HeapProfiler::ObjectNameResolver * | resolver | ||
) |
Definition at line 65 of file heap-profiler.cc.
References v8::internal::HeapSnapshotGenerator::GenerateSnapshot(), heap(), ids_, is_tracking_object_moves_, name, next_snapshot_uid_, NULL, and snapshots_.
Referenced by TakeSnapshot().
HeapSnapshot * v8::internal::HeapProfiler::TakeSnapshot | ( | String * | name, |
v8::ActivityControl * | control, | ||
v8::HeapProfiler::ObjectNameResolver * | resolver | ||
) |
Definition at line 85 of file heap-profiler.cc.
References name, names_, and TakeSnapshot().
|
private |
Definition at line 78 of file heap-profiler.h.
Referenced by allocation_tracker(), AllocationEvent(), is_tracking_allocations(), ObjectMoveEvent(), StartHeapObjectsTracking(), and StopHeapObjectsTracking().
|
private |
Definition at line 73 of file heap-profiler.h.
Referenced by ClearHeapObjectMap(), FindHeapObjectById(), GetMemorySizeUsedByProfiler(), GetSnapshotObjectId(), heap(), heap_object_map(), ObjectMoveEvent(), PushHeapObjectsStats(), StartHeapObjectsTracking(), StopHeapObjectsTracking(), TakeSnapshot(), and UpdateObjectSizeEvent().
|
private |
Definition at line 79 of file heap-profiler.h.
Referenced by ClearHeapObjectMap(), is_tracking_object_moves(), StartHeapObjectsTracking(), and TakeSnapshot().
|
private |
Definition at line 75 of file heap-profiler.h.
Referenced by DeleteAllSnapshots(), GetMemorySizeUsedByProfiler(), names(), StartHeapObjectsTracking(), and TakeSnapshot().
|
private |
Definition at line 76 of file heap-profiler.h.
Referenced by TakeSnapshot().
|
private |
Definition at line 74 of file heap-profiler.h.
Referenced by DeleteAllSnapshots(), GetMemorySizeUsedByProfiler(), GetSnapshot(), GetSnapshotsCount(), RemoveSnapshot(), TakeSnapshot(), and ~HeapProfiler().
|
private |
Definition at line 77 of file heap-profiler.h.
Referenced by DefineWrapperClass(), and ExecuteWrapperClassCallback().