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

Unified Diff: base/trace_event.h

Issue 174118: Don't compile with TraceLog support on by default. (Closed)
Patch Set: Created 11 years, 4 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/trace_event.h
diff --git a/base/trace_event.h b/base/trace_event.h
index d2b6ef116f4fce97300afe308155abd7d9948992..3eb191d22007d27122a9df2ca3867e8d10ab1feb 100644
--- a/base/trace_event.h
+++ b/base/trace_event.h
@@ -29,6 +29,12 @@
#include "base/time.h"
#include "base/timer.h"
+#if 1 // Set to 0 to compile with tracing.
Mark Mentovai 2009/08/20 01:44:34 Can we make this something like #ifndef ENABLE_TRA
+#define TRACE_EVENT_BEGIN(name, id, extra) ((void) 0)
+#define TRACE_EVENT_END(name, id, extra) ((void) 0)
+#define TRACE_EVENT_INSTANT(name, id, extra) ((void) 0)
+
+#else
// Use the following macros rather than using the TraceLog class directly as the
// underlying implementation may change in the future. Here's a sample usage:
// TRACE_EVENT_BEGIN("v8.run", documentId, scriptLocation);
@@ -63,6 +69,7 @@
extra, \
__FILE__, \
__LINE__)
+#endif
Mark Mentovai 2009/08/20 01:44:34 Put a comment saying what you're ending, whatever
namespace base {
class ProcessMetrics;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698