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

Unified Diff: src/gpu/GrTracing.h

Issue 1579193002: Convert GrAuditTrail to use scoped frames (Closed) Base URL: https://skia.googlesource.com/skia.git@audittrail-2-wireupbatchnames-andbounds
Patch Set: typo Created 4 years, 11 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
« include/private/GrAuditTrail.h ('K') | « src/gpu/GrAuditTrail.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrTracing.h
diff --git a/src/gpu/GrTracing.h b/src/gpu/GrTracing.h
index 4cdcace6ff409f969266ad8576139d869e038122..3dbc0ef17e0296f71a754e691a29d35418d188e1 100644
--- a/src/gpu/GrTracing.h
+++ b/src/gpu/GrTracing.h
@@ -58,7 +58,7 @@ private:
/**
* GR_CREATE_TRACE_MARKER will place begin and end trace markers for both
* cpu and gpu (if gpu tracing enabled) for the current scope.
- * marker is of type const char* and target is of type GrDrawTarget*
+ * name is of type const char* and target is of type GrDrawTarget*
*/
#define GR_CREATE_TRACE_MARKER(name, target) \
/* Chromium tracing */ \
@@ -86,6 +86,10 @@ private:
GrGpuTraceMarkerGenerator SK_MACRO_APPEND_LINE(TMG)(target); \
SK_MACRO_APPEND_LINE(TMG).initialize(name, &name_counter); \
+/**
+ * Context level GrTracing macros, classname and op are const char*, context is GrContext
+ * TODO can we just have one set of macros? Probably.
+ */
#define GR_CREATE_TRACE_MARKER_CONTEXT(classname, op, context) \
/* Chromium tracing */ \
static int SK_MACRO_APPEND_LINE(name_counter) = 0; \
@@ -96,7 +100,7 @@ private:
INTERNAL_GR_CREATE_TRACE_MARKER_SCOPED_C(classname "::" op, \
SK_MACRO_APPEND_LINE(name_counter), context) \
} \
- GR_AUDIT_TRAIL_ADDOP(context->getAuditTrail(), SkString(op)); \
+ GR_AUDIT_TRAIL_AUTO_FRAME(context->getAuditTrail(), classname "::" op); \
INTERNAL_TRACE_EVENT_ADD_SCOPED(TRACE_DISABLED_BY_DEFAULT("skia.gpu"), classname "::" op, \
"id", SK_MACRO_APPEND_LINE(name_counter));
« include/private/GrAuditTrail.h ('K') | « src/gpu/GrAuditTrail.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698