Trace texture upload always with Android framework

Test: Built on Android
Bug: b/142426387
Change-Id: I7ca32ffedd8896cbb105872cd1b3c746ff8ffe9d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/282837
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Stan Iliev <stani@google.com>
This commit is contained in:
Stan Iliev 2020-04-10 00:58:52 -04:00 committed by Skia Commit-Bot
parent 96bfeff55c
commit 1db4d14e59
2 changed files with 2 additions and 1 deletions

View File

@ -136,7 +136,7 @@ public:
};
#define ATRACE_ANDROID_FRAMEWORK(fmt, ...) SkAndroidFrameworkTraceUtil __trace(true, fmt, ##__VA_ARGS__)
#define ATRACE_ANDROID_FRAMEWORK_ALWAYS(fmt, ...) SkAndroidFrameworkTraceUtilAlways __trace(fmt, ##__VA_ARGS__)
#define ATRACE_ANDROID_FRAMEWORK_ALWAYS(fmt, ...) SkAndroidFrameworkTraceUtilAlways __trace_always(fmt, ##__VA_ARGS__)
// Records a pair of begin and end events called "name" for the current scope, with 0, 1 or 2
// associated arguments. In the framework, the arguments are ignored.

View File

@ -446,6 +446,7 @@ bool GrGpu::writePixels(GrSurface* surface, int left, int top, int width, int he
GrColorType surfaceColorType, GrColorType srcColorType,
const GrMipLevel texels[], int mipLevelCount, bool prepForTexSampling) {
TRACE_EVENT0("skia.gpu", TRACE_FUNC);
ATRACE_ANDROID_FRAMEWORK_ALWAYS("texture_upload");
SkASSERT(surface);
SkASSERT(!surface->framebufferOnly());