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

Unified Diff: runtime/vm/trace_buffer.h

Issue 327803003: Provide the isolate with a trace buffer, but do not allocate one by default. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 6 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 | « runtime/vm/isolate.cc ('k') | runtime/vm/trace_buffer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/trace_buffer.h
===================================================================
--- runtime/vm/trace_buffer.h (revision 37183)
+++ runtime/vm/trace_buffer.h (working copy)
@@ -25,7 +25,8 @@
public:
static const intptr_t kDefaultCapacity = 1024;
- explicit TraceBuffer(intptr_t capacity = kDefaultCapacity);
+ static void Init(Isolate* isolate, intptr_t capacity = kDefaultCapacity);
+
~TraceBuffer();
void Clear();
@@ -39,11 +40,12 @@
void PrintToJSONStream(JSONStream* stream) const;
private:
- void Init();
+ TraceBuffer(Isolate* isolate, intptr_t capacity);
void Cleanup();
void Fill(TraceBufferEntry* entry, int64_t micros, char* msg);
void AppendTrace(int64_t micros, char* message);
+ Isolate* isolate_;
TraceBufferEntry* ring_;
const intptr_t ring_capacity_;
intptr_t ring_cursor_;
« no previous file with comments | « runtime/vm/isolate.cc ('k') | runtime/vm/trace_buffer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698