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

Unified Diff: include/v8-profiler.h

Issue 10049002: Introduce a way to grab heap stats. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: comments addressed Created 8 years, 8 months 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.h ('k') | src/api.cc » ('j') | test/cctest/test-heap-profiler.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/v8-profiler.h
diff --git a/include/v8-profiler.h b/include/v8-profiler.h
index e36659fb48da438082baa47090c66ab77ca05da5..77419493990ffc813baf4235153cc23a691481aa 100644
--- a/include/v8-profiler.h
+++ b/include/v8-profiler.h
@@ -418,6 +418,33 @@ class V8EXPORT HeapProfiler {
ActivityControl* control = NULL);
/**
+ * Starts tracking of heap objects population statistics. After calling
+ * this method, all heap objects relocations done by the garbage collector
+ * are being registered.
+ */
+ static void StartHeapObjectsTracking();
+
+ /**
+ * Adds a new time interval entry to the aggregated statistics array. The
+ * time interval entry contains information on the current heap objects
+ * population size. The method also updates aggregated statistics and
+ * reports updates for all previous time intervals via the OutputStream
+ * object. Updates on each time interval are provided as pairs of time
+ * interval index and updated heap objects count.
+ *
+ * StartHeapObjectsTracking must be called before the first call to this
+ * method.
+ */
+ static void PushHeapObjectsStats(OutputStream* stream);
+
+ /**
+ * Stops tracking of heap objects population statistics, cleans up all
+ * collected data. StartHeapObjectsTracking must be called again prior to
+ * calling PushHeapObjectsStats next time.
+ */
+ static void StopHeapObjectsTracking();
+
+ /**
* Deletes all snapshots taken. All previously returned pointers to
* snapshots and their contents become invalid after this call.
*/
« no previous file with comments | « include/v8.h ('k') | src/api.cc » ('j') | test/cctest/test-heap-profiler.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698