Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(114)

Side by Side Diff: bench/Xfer4fBench.cpp

Issue 1653143004: increase inner-loop for xfer4 benches to reduce variance (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2016 Google Inc. 3 * Copyright 2016 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #include "Benchmark.h" 9 #include "Benchmark.h"
10 #include "SkString.h" 10 #include "SkString.h"
11 #include "SkXfermode.h" 11 #include "SkXfermode.h"
12 12
13 #define INNER_LOOPS 100 13 #define INNER_LOOPS 1000
14 14
15 // Benchmark that draws non-AA rects or AA text with an SkXfermode::Mode. 15 // Benchmark that draws non-AA rects or AA text with an SkXfermode::Mode.
16 class Xfer4fBench : public Benchmark { 16 class Xfer4fBench : public Benchmark {
17 public: 17 public:
18 Xfer4fBench(SkXfermode::Mode mode, const char name[], bool doN, uint32_t fla gs) 18 Xfer4fBench(SkXfermode::Mode mode, const char name[], bool doN, uint32_t fla gs)
19 : fDoN(doN) 19 : fDoN(doN)
20 , fFlags(flags) 20 , fFlags(flags)
21 { 21 {
22 fProc1 = SkXfermode::GetPM4fProc1(mode, flags); 22 fProc1 = SkXfermode::GetPM4fProc1(mode, flags);
23 fProcN = SkXfermode::GetPM4fProcN(mode, flags); 23 fProcN = SkXfermode::GetPM4fProcN(mode, flags);
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 72
73 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", false, F 10); ) 73 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", false, F 10); )
74 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", false, F 00); ) 74 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", false, F 00); )
75 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", false, F 11); ) 75 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", false, F 11); )
76 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", false, F 01); ) 76 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", false, F 01); )
77 77
78 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", true, F 10); ) 78 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", true, F 10); )
79 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", true, F 00); ) 79 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", true, F 00); )
80 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", true, F 11); ) 80 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", true, F 11); )
81 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", true, F 01); ) 81 DEF_BENCH( return new Xfer4fBench(SkXfermode::kSrcOver_Mode, "srcover", true, F 01); )
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698