aboutsummaryrefslogtreecommitdiffhomepage
path: root/bench/SkRasterPipelineBench.cpp
diff options
context:
space:
mode:
authorGravatar Mike Klein <mtklein@chromium.org>2016-09-27 12:08:10 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2016-09-27 17:46:54 +0000
commit1f4a874addd7c039fb8b434181040cd6a8a35339 (patch)
tree26f3970305a83bb3305e566e12444f973cf5eef5 /bench/SkRasterPipelineBench.cpp
parent3ba96c8cecd86e34b09471f3114aab2434ff702e (diff)
SkRasterPipeline: add last() and docs.
Today if you use the simple SK_RASTER_STAGE interface to build a pipeline, each stage you add calls into a next stage. The last stage you add calls into a special backstop stage JustReturn that, well, just returns, ending the pipeline. This adds last(), which cuts that last stage off the pipeline. Instead, the stage you add using last() returns directly, ending the pipeline itself without jumping into JustReturn. This reduces the overhead of using the pipelined version of SkRasterPipelineBench from ~25% to ~20% on my desktop. Also, add docs. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2713 Change-Id: I11469378e2765c6e34db52eb3eef648d6612da3f Reviewed-on: https://skia-review.googlesource.com/2713 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org>
Diffstat (limited to 'bench/SkRasterPipelineBench.cpp')
-rw-r--r--bench/SkRasterPipelineBench.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/bench/SkRasterPipelineBench.cpp b/bench/SkRasterPipelineBench.cpp
index a5263d770f..5ef64ce603 100644
--- a/bench/SkRasterPipelineBench.cpp
+++ b/bench/SkRasterPipelineBench.cpp
@@ -174,7 +174,7 @@ public:
p.append< scale_u8, scale_u8_tail>(mask);
p.append<load_d_srgb, load_d_srgb_tail>( dst);
p.append<srcover>();
- p.append< store_srgb, store_srgb_tail>( dst);
+ p.last< store_srgb, store_srgb_tail>( dst);
p.run(N);
}