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

Unified Diff: runtime/vm/timeline.h

Issue 1406413006: Timeline service protocol support with Observatory UI (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 1 month 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 | « runtime/vm/thread_pool.cc ('k') | runtime/vm/timeline.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/timeline.h
diff --git a/runtime/vm/timeline.h b/runtime/vm/timeline.h
index 9372c04220e5b73d78d2b29cc07ca98ad29e9bc0..1c618145e6165a85ffa9eb47da58c8cd8daad312 100644
--- a/runtime/vm/timeline.h
+++ b/runtime/vm/timeline.h
@@ -30,6 +30,7 @@ class Zone;
V(API, false) \
V(Compiler, false) \
V(Dart, false) \
+ V(Debugger, false) \
V(Embedder, false) \
V(GC, false) \
V(Isolate, false) \
@@ -52,6 +53,8 @@ class Timeline : public AllStatic {
// Reclaim all |TimelineEventBlocks|s that are cached by threads.
static void ReclaimCachedBlocksFromThreads();
+ static void Clear();
+
#define ISOLATE_TIMELINE_STREAM_FLAGS(name, not_used) \
static const bool* Stream##name##EnabledFlag() { \
return &stream_##name##_enabled_; \
@@ -523,6 +526,7 @@ class TimelineEventRecorder {
virtual void CompleteEvent(TimelineEvent* event) = 0;
virtual TimelineEventBlock* GetHeadBlockLocked() = 0;
virtual TimelineEventBlock* GetNewBlockLocked() = 0;
+ virtual void Clear() = 0;
// Utility method(s).
void PrintJSONMeta(JSONArray* array) const;
@@ -560,8 +564,9 @@ class TimelineEventRingRecorder : public TimelineEventRecorder {
TimelineEventBlock* GetHeadBlockLocked();
intptr_t FindOldestBlockIndex() const;
TimelineEventBlock* GetNewBlockLocked();
+ void Clear();
- void PrintJSONEvents(JSONArray* array, TimelineEventFilter* filter) const;
+ void PrintJSONEvents(JSONArray* array, TimelineEventFilter* filter);
TimelineEventBlock** blocks_;
intptr_t capacity_;
@@ -590,6 +595,8 @@ class TimelineEventStreamingRecorder : public TimelineEventRecorder {
TimelineEventBlock* GetHeadBlockLocked() {
return NULL;
}
+ void Clear() {
+ }
TimelineEvent* StartEvent();
void CompleteEvent(TimelineEvent* event);
};
@@ -610,12 +617,10 @@ class TimelineEventEndlessRecorder : public TimelineEventRecorder {
void CompleteEvent(TimelineEvent* event);
TimelineEventBlock* GetNewBlockLocked();
TimelineEventBlock* GetHeadBlockLocked();
-
- void PrintJSONEvents(JSONArray* array, TimelineEventFilter* filter) const;
-
- // Useful only for testing. Only works for one thread.
void Clear();
+ void PrintJSONEvents(JSONArray* array, TimelineEventFilter* filter);
+
TimelineEventBlock* head_;
intptr_t block_index_;
« no previous file with comments | « runtime/vm/thread_pool.cc ('k') | runtime/vm/timeline.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698