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

Side by Side Diff: dm/DMTestTask.cpp

Issue 531653002: SkThreadPool ~~> SkTaskGroup (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: cleanup allowThreaded() Created 6 years, 3 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
OLDNEW
1 #include "DMTestTask.h" 1 #include "DMTestTask.h"
2 #include "DMUtil.h" 2 #include "DMUtil.h"
3 #include "SkCommandLineFlags.h" 3 #include "SkCommandLineFlags.h"
4 #include "SkCommonFlags.h" 4 #include "SkCommonFlags.h"
5 5
6 // When PathOps threaded tests get going, they're briefly a big consumer of lots of RAM. 6 DEFINE_bool2(pathOpsExtended, x, false, "Run extended pathOps tests.");
7 // We disable the internal threading there by default on 32-bit builds.
8 static const bool is32Bit = sizeof(void*) == 4;
9
10 DEFINE_bool2(pathOpsExtended, x, false, "Run extended pathOps tests.");
11 DEFINE_bool2(pathOpsSingleThread, z, is32Bit, "Disallow pathOps tests from using threads.");
12 7
13 namespace DM { 8 namespace DM {
14 9
15 bool TestReporter::allowExtendedTest() const { return FLAGS_pathOpsExtended; } 10 bool TestReporter::allowExtendedTest() const { return FLAGS_pathOpsExtended; }
16 bool TestReporter::allowThreaded() const { return !FLAGS_pathOpsSingleThread ; }
17 bool TestReporter::verbose() const { return FLAGS_veryVerbose; } 11 bool TestReporter::verbose() const { return FLAGS_veryVerbose; }
18 12
19 static SkString test_name(const char* name) { 13 static SkString test_name(const char* name) {
20 SkString result("test "); 14 SkString result("test ");
21 result.append(name); 15 result.append(name);
22 return result; 16 return result;
23 } 17 }
24 18
25 CpuTestTask::CpuTestTask(Reporter* reporter, 19 CpuTestTask::CpuTestTask(Reporter* reporter,
26 TaskRunner* taskRunner, 20 TaskRunner* taskRunner,
(...skipping 25 matching lines...) Expand all
52 if (!fTest->passed()) { 46 if (!fTest->passed()) {
53 this->fail(fTestReporter.failure()); 47 this->fail(fTestReporter.failure());
54 } 48 }
55 } 49 }
56 50
57 bool GpuTestTask::shouldSkip() const { 51 bool GpuTestTask::shouldSkip() const {
58 return kGPUDisabled; 52 return kGPUDisabled;
59 } 53 }
60 54
61 } // namespace DM 55 } // namespace DM
OLDNEW
« no previous file with comments | « dm/DMTestTask.h ('k') | gyp/dm.gypi » ('j') | src/utils/SkRunnable.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698