| OLD | NEW |
| 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 "Benchmark.h" | 10 #include "Benchmark.h" |
| (...skipping 582 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 593 int fCurrentRecording; | 593 int fCurrentRecording; |
| 594 int fCurrentScale; | 594 int fCurrentScale; |
| 595 int fCurrentSKP; | 595 int fCurrentSKP; |
| 596 int fCurrentUseMPD; | 596 int fCurrentUseMPD; |
| 597 }; | 597 }; |
| 598 | 598 |
| 599 int nanobench_main(); | 599 int nanobench_main(); |
| 600 int nanobench_main() { | 600 int nanobench_main() { |
| 601 SetupCrashHandler(); | 601 SetupCrashHandler(); |
| 602 SkAutoGraphics ag; | 602 SkAutoGraphics ag; |
| 603 // Multithreading is disabled pending resolution of skia:3149 | 603 SkTaskGroup::Enabler enabled; |
| 604 //SkTaskGroup::Enabler enabled; | |
| 605 | 604 |
| 606 #if SK_SUPPORT_GPU | 605 #if SK_SUPPORT_GPU |
| 607 GrContext::Options grContextOpts; | 606 GrContext::Options grContextOpts; |
| 608 grContextOpts.fDrawPathToCompressedTexture = FLAGS_gpuCompressAlphaMasks; | 607 grContextOpts.fDrawPathToCompressedTexture = FLAGS_gpuCompressAlphaMasks; |
| 609 gGrFactory.reset(SkNEW_ARGS(GrContextFactory, (grContextOpts))); | 608 gGrFactory.reset(SkNEW_ARGS(GrContextFactory, (grContextOpts))); |
| 610 #endif | 609 #endif |
| 611 | 610 |
| 612 if (FLAGS_veryVerbose) { | 611 if (FLAGS_veryVerbose) { |
| 613 FLAGS_verbose = true; | 612 FLAGS_verbose = true; |
| 614 } | 613 } |
| (...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 787 | 786 |
| 788 return 0; | 787 return 0; |
| 789 } | 788 } |
| 790 | 789 |
| 791 #if !defined SK_BUILD_FOR_IOS | 790 #if !defined SK_BUILD_FOR_IOS |
| 792 int main(int argc, char** argv) { | 791 int main(int argc, char** argv) { |
| 793 SkCommandLineFlags::Parse(argc, argv); | 792 SkCommandLineFlags::Parse(argc, argv); |
| 794 return nanobench_main(); | 793 return nanobench_main(); |
| 795 } | 794 } |
| 796 #endif | 795 #endif |
| OLD | NEW |