diff --git a/bench/BitmapBench.cpp b/bench/BitmapBench.cpp index a9b10f466..982c917c0 100644 --- a/bench/BitmapBench.cpp +++ b/bench/BitmapBench.cpp @@ -363,7 +363,6 @@ DEF_BENCH( return new BitmapBench(true, SkBitmap::kIndex8_Config); ) DEF_BENCH( return new BitmapBench(true, SkBitmap::kARGB_8888_Config, true, true); ) DEF_BENCH( return new BitmapBench(true, SkBitmap::kARGB_8888_Config, true, false); ) -/* TODO(mtklein): figure out why these are broken (suspect caching is interfering) and restore // scale filter -> S32_opaque_D32_filter_DX_{SSE2,SSSE3} and Fact9 is also for S32_D16_filter_DX_SSE2 DEF_BENCH( return new FilterBitmapBench(false, SkBitmap::kARGB_8888_Config, false, false, kScale_Flag | kBilerp_Flag); ) DEF_BENCH( return new FilterBitmapBench(true, SkBitmap::kARGB_8888_Config, false, false, kScale_Flag | kBilerp_Flag); ) @@ -378,7 +377,6 @@ DEF_BENCH( return new FilterBitmapBench(true, SkBitmap::kARGB_8888_Config, true, DEF_BENCH( return new FilterBitmapBench(false, SkBitmap::kARGB_8888_Config, false, false, kScale_Flag | kBilerp_Flag | kBicubic_Flag); ) DEF_BENCH( return new FilterBitmapBench(false, SkBitmap::kARGB_8888_Config, false, false, kScale_Flag | kRotate_Flag | kBilerp_Flag | kBicubic_Flag); ) -*/ // source alpha tests -> S32A_Opaque_BlitRow32_{arm,neon} DEF_BENCH( return new SourceAlphaBitmapBench(SourceAlphaBitmapBench::kOpaque_SourceAlpha, SkBitmap::kARGB_8888_Config); ) diff --git a/bench/benchmain.cpp b/bench/benchmain.cpp index b970d09bc..6b5250816 100644 --- a/bench/benchmain.cpp +++ b/bench/benchmain.cpp @@ -593,15 +593,14 @@ int tool_main(int argc, char** argv) { } timer.start(); - if (NULL != canvas) { - canvas->save(); - } - // Inner loop that allows us to break the run into smaller // chunks (e.g. frames). This is especially useful for the GPU // as we can flush and/or swap buffers to keep the GPU from // queuing up too much work. for (int loopCount = loopsPerIter; loopCount > 0; ) { + if (NULL != canvas) { + canvas->save(); + } if (frameIntervalComputed && loopCount > loopsPerFrame) { bench->setLoops(loopsPerFrame); loopCount -= loopsPerFrame; @@ -629,11 +628,11 @@ int tool_main(int argc, char** argv) { glContext->swapBuffers(); } #endif + if (NULL != canvas) { + canvas->restore(); + } } - if (NULL != canvas) { - canvas->restore(); - } // Stop truncated timers before GL calls complete, and stop the full timers after.