blob: 6a8ded7bbe8a36fae7e48e48cf08a13ae67e11cc [file] [log] [blame]
commit-bot@chromium.org2a05de02014-03-25 15:17:32 +00001/*
2 * Copyright 2014 Google Inc.
3 *
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
6 */
7
8#ifndef GrTracing_DEFINED
9#define GrTracing_DEFINED
10
commit-bot@chromium.org2a05de02014-03-25 15:17:32 +000011#include "SkTraceEvent.h"
12
Robert Phillips646e4292017-06-13 12:44:56 -040013class GrContext;
14
commit-bot@chromium.org2a05de02014-03-25 15:17:32 +000015/**
joshualitt87a721b2016-01-12 12:59:28 -080016 * Context level GrTracing macros, classname and op are const char*, context is GrContext
joshualitt87a721b2016-01-12 12:59:28 -080017 */
Brian Osmanb4d18732017-07-27 14:58:18 -040018#define GR_CREATE_TRACE_MARKER_CONTEXT(classname, op, context) \
Robert Phillips0c4b7b12018-03-06 08:20:37 -050019 GR_AUDIT_TRAIL_AUTO_FRAME(context->contextPriv().getAuditTrail(), classname "::" op); \
Derek Sollenbergeredf3dc02017-08-16 10:35:28 -040020 TRACE_EVENT0("skia.gpu", classname "::" op);
egdaniel93a37bc2014-07-21 13:47:57 -070021
commit-bot@chromium.org2a05de02014-03-25 15:17:32 +000022#endif