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

Side by Side Diff: bench/MathBench.cpp

Issue 2041943002: SkLeanWindows.h: #include "Windows.h" fewer places (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2016-06-07 (Tuesday) 11:28:42 EDT Created 4 years, 6 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 | bench/nanobench.cpp » ('j') | 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 * Copyright 2015 Google Inc. 2 * Copyright 2015 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "Benchmark.h" 8 #include "Benchmark.h"
9 #include "SkColorPriv.h" 9 #include "SkColorPriv.h"
10 #include "SkFixed.h" 10 #include "SkFixed.h"
11 #include "SkMathPriv.h"
11 #include "SkMatrix.h" 12 #include "SkMatrix.h"
12 #include "SkPaint.h" 13 #include "SkPaint.h"
13 #include "SkRandom.h" 14 #include "SkRandom.h"
14 #include "SkString.h" 15 #include "SkString.h"
15 16
16 static float sk_fsel(float pred, float result_ge, float result_lt) { 17 static float sk_fsel(float pred, float result_ge, float result_lt) {
17 return pred >= 0 ? result_ge : result_lt; 18 return pred >= 0 ? result_ge : result_lt;
18 } 19 }
19 20
20 static float fast_floor(float x) { 21 static float fast_floor(float x) {
(...skipping 605 matching lines...) Expand 10 before | Expand all | Expand 10 after
626 627
627 void onDraw(int loops, SkCanvas*) override { 628 void onDraw(int loops, SkCanvas*) override {
628 while (loops --> 0) { 629 while (loops --> 0) {
629 for (int i = 0; i < N; i++) { 630 for (int i = 0; i < N; i++) {
630 fInts[i] = SkFloatToIntFloor(fFloats[i]); 631 fInts[i] = SkFloatToIntFloor(fFloats[i]);
631 } 632 }
632 } 633 }
633 } 634 }
634 }; 635 };
635 DEF_BENCH( return new FloatToIntBench; ) 636 DEF_BENCH( return new FloatToIntBench; )
OLDNEW
« no previous file with comments | « no previous file | bench/nanobench.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698