Trace events in backend texture APIs and GrDataUtils
Bug: chromium:919885
Change-Id: I517afb5817d29ff8082cee63b8cce18f34a8ceac
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/223339
Auto-Submit: Brian Salomon <bsalomon@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
diff --git a/src/gpu/GrDataUtils.cpp b/src/gpu/GrDataUtils.cpp
index faf921a..ae9c7d1 100644
--- a/src/gpu/GrDataUtils.cpp
+++ b/src/gpu/GrDataUtils.cpp
@@ -8,6 +8,7 @@
#include "src/gpu/GrDataUtils.h"
#include "src/core/SkColorSpaceXformSteps.h"
#include "src/core/SkTLazy.h"
+#include "src/core/SkTraceEvent.h"
#include "src/core/SkUtils.h"
#include "src/gpu/GrColor.h"
@@ -358,6 +359,7 @@
int baseWidth, int baseHeight,
const SkTArray<size_t>& individualMipOffsets, char* dstPixels,
const SkColor4f& colorf) {
+ TRACE_EVENT0("skia.gpu", TRACE_FUNC);
int mipLevels = individualMipOffsets.count();
@@ -484,6 +486,8 @@
bool GrConvertPixels(const GrPixelInfo& dstInfo, void* dst, const GrPixelInfo& srcInfo,
const void* src, GrSwizzle swizzle) {
+ TRACE_EVENT0("skia.gpu", TRACE_FUNC);
+
if (dstInfo.fWidth != srcInfo.fWidth || srcInfo.fHeight != dstInfo.fHeight) {
return false;
}