Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(43)

Unified Diff: src/api.cc

Issue 93843004: Add methods for finding object by its snapshot id and id for an object (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: One more time Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « include/v8-profiler.h ('k') | src/heap-profiler.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/api.cc
diff --git a/src/api.cc b/src/api.cc
index aee9e3a469eae454a9fdc7b241142050044a730a..d0ec5d64340c1b33307a2a69b6f86773698e0679 100644
--- a/src/api.cc
+++ b/src/api.cc
@@ -7486,6 +7486,19 @@ SnapshotObjectId HeapProfiler::GetObjectId(Handle<Value> value) {
}
+Handle<Value> HeapProfiler::FindObjectById(SnapshotObjectId id) {
+ i::Handle<i::Object> obj =
+ reinterpret_cast<i::HeapProfiler*>(this)->FindHeapObjectById(id);
+ if (obj.is_null()) return Local<Value>();
+ return Utils::ToLocal(obj);
+}
+
+
+void HeapProfiler::ClearObjectIds() {
+ reinterpret_cast<i::HeapProfiler*>(this)->ClearHeapObjectMap();
+}
+
+
const HeapSnapshot* HeapProfiler::TakeHeapSnapshot(
Handle<String> title,
ActivityControl* control,
« no previous file with comments | « include/v8-profiler.h ('k') | src/heap-profiler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698