| Index: tools/render_pictures_main.cpp
|
| diff --git a/tools/render_pictures_main.cpp b/tools/render_pictures_main.cpp
|
| index 4fb83521c8c3e05e6661463aaf2d9172430dcf78..d7a213cb47e74650db2885c7c75b96b3c04205a9 100644
|
| --- a/tools/render_pictures_main.cpp
|
| +++ b/tools/render_pictures_main.cpp
|
| @@ -36,6 +36,10 @@ DEFINE_int32(maxComponentDiff, 256, "Maximum diff on a component, 0 - 256. Compo
|
| "Requires --validate.");
|
| DEFINE_string(mismatchPath, "", "Write images for tests that failed due to "
|
| "pixel mismatches into this directory.");
|
| +#if GR_GPU_STATS
|
| +DEFINE_bool(gpuStats, false, "Only meaningful with gpu configurations. "
|
| + "Report some GPU call statistics.");
|
| +#endif
|
| DEFINE_bool(preprocess, false, "If true, perform device specific preprocessing before rendering.");
|
| DEFINE_string(readJsonSummaryPath, "", "JSON file to read image expectations from.");
|
| DECLARE_string(readPath);
|
| @@ -496,6 +500,13 @@ int tool_main(int argc, char** argv) {
|
| #endif
|
| }
|
| #endif
|
| +#if GR_GPU_STATS
|
| + if (FLAGS_gpuStats && renderer->isUsingGpuDevice()) {
|
| + GrContext* ctx = renderer->getGrContext();
|
| + SkDebugf("RenderTarget Binds: %d\n", ctx->gpuStats()->renderTargetBinds());
|
| + SkDebugf("Shader Compilations: %d\n", ctx->gpuStats()->shaderCompilations());
|
| + }
|
| +#endif
|
| #endif
|
| if (FLAGS_writeJsonSummaryPath.count() == 1) {
|
| // If there were any descriptions on the command line, insert them now.
|
|
|