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

Side by Side Diff: bench/nanobench.cpp

Issue 2074103004: Revert of More removal of SkColorProfileType... (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 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 | dm/DM.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 2014 Google Inc. 2 * Copyright 2014 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 <ctype.h> 8 #include <ctype.h>
9 9
10 #include "nanobench.h" 10 #include "nanobench.h"
(...skipping 1007 matching lines...) Expand 10 before | Expand all | Expand 10 after
1018 sleep(kSec); 1018 sleep(kSec);
1019 #endif 1019 #endif
1020 SkDebugf("\nBenchmarks still running...\n"); 1020 SkDebugf("\nBenchmarks still running...\n");
1021 } 1021 }
1022 } 1022 }
1023 }; 1023 };
1024 static SkThread* intentionallyLeaked = new SkThread(Loop::forever); 1024 static SkThread* intentionallyLeaked = new SkThread(Loop::forever);
1025 intentionallyLeaked->start(); 1025 intentionallyLeaked->start();
1026 } 1026 }
1027 1027
1028 extern bool gDefaultProfileIsSRGB;
1029
1028 int nanobench_main(); 1030 int nanobench_main();
1029 int nanobench_main() { 1031 int nanobench_main() {
1030 SetupCrashHandler(); 1032 SetupCrashHandler();
1031 SkAutoGraphics ag; 1033 SkAutoGraphics ag;
1032 SkTaskGroup::Enabler enabled(FLAGS_threads); 1034 SkTaskGroup::Enabler enabled(FLAGS_threads);
1033 1035
1034 #if SK_SUPPORT_GPU 1036 #if SK_SUPPORT_GPU
1035 GrContextOptions grContextOpts; 1037 GrContextOptions grContextOpts;
1036 gGrFactory.reset(new GrContextFactory(grContextOpts)); 1038 gGrFactory.reset(new GrContextFactory(grContextOpts));
1037 #endif 1039 #endif
1038 1040
1041 if (FLAGS_forceSRGB) {
1042 gDefaultProfileIsSRGB = true;
1043 }
1044
1039 if (FLAGS_veryVerbose) { 1045 if (FLAGS_veryVerbose) {
1040 FLAGS_verbose = true; 1046 FLAGS_verbose = true;
1041 } 1047 }
1042 1048
1043 if (kAutoTuneLoops != FLAGS_loops) { 1049 if (kAutoTuneLoops != FLAGS_loops) {
1044 FLAGS_samples = 1; 1050 FLAGS_samples = 1;
1045 FLAGS_gpuFrameLag = 0; 1051 FLAGS_gpuFrameLag = 0;
1046 } 1052 }
1047 1053
1048 if (!FLAGS_writePath.isEmpty()) { 1054 if (!FLAGS_writePath.isEmpty()) {
(...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after
1282 1288
1283 return 0; 1289 return 0;
1284 } 1290 }
1285 1291
1286 #if !defined SK_BUILD_FOR_IOS 1292 #if !defined SK_BUILD_FOR_IOS
1287 int main(int argc, char** argv) { 1293 int main(int argc, char** argv) {
1288 SkCommandLineFlags::Parse(argc, argv); 1294 SkCommandLineFlags::Parse(argc, argv);
1289 return nanobench_main(); 1295 return nanobench_main();
1290 } 1296 }
1291 #endif 1297 #endif
OLDNEW
« no previous file with comments | « no previous file | dm/DM.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698