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

Unified Diff: include/v8-profiler.h

Issue 2117343006: Introduce v8::CpuProfiler::New and v8::CpuProfiler::Dispose API. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Remove ProfilerExtension::Scope Created 4 years, 5 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') | no next file with comments »
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 6a09d50ea5635da3f1eff41aa995095b4d59592a..29d3c84a740b03a87a72de28b38f93be3a044779 100644
--- a/include/v8-profiler.h
+++ b/include/v8-profiler.h
@@ -207,14 +207,25 @@ class V8_EXPORT CpuProfile {
void Delete();
};
-
/**
* Interface for controlling CPU profiling. Instance of the
- * profiler can be retrieved using v8::Isolate::GetCpuProfiler.
+ * profiler can be created using v8::CpuProfiler::New method.
*/
class V8_EXPORT CpuProfiler {
public:
/**
+ * Creates a new CPU profiler for the |isolate|. The isolate must be
+ * initialized. The profiler object must be disposed after use by calling
+ * |Dispose| method.
+ */
+ static CpuProfiler* New(Isolate* isolate);
+
+ /**
+ * Disposes the CPU profiler object.
+ */
+ void Dispose();
+
+ /**
* Changes default CPU profiler sampling interval to the specified number
* of microseconds. Default interval is 1000us. This method must be called
* when there are no profiles being recorded.
« no previous file with comments | « include/v8.h ('k') | src/api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698