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

Unified Diff: dm/DM.cpp

Issue 531653002: SkThreadPool ~~> SkTaskGroup (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Lazy and leaky -> proactive and clean. 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | dm/DMQuiltTask.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dm/DM.cpp
diff --git a/dm/DM.cpp b/dm/DM.cpp
index 09f0ce8f268cd0b15e0cd16a3012fd4e19148741..b330445186444d7fd6d93292013ad1a7b2c85691 100644
--- a/dm/DM.cpp
+++ b/dm/DM.cpp
@@ -8,6 +8,7 @@
#include "SkGraphics.h"
#include "SkPicture.h"
#include "SkString.h"
+#include "SkTaskGroup.h"
#include "Test.h"
#include "gm.h"
#include "sk_tool_utils.h"
@@ -41,7 +42,6 @@ using skiatest::TestRegistry;
static const char kGpuAPINameGL[] = "gl";
static const char kGpuAPINameGLES[] = "gles";
-DEFINE_int32(gpuThreads, 1, "Threads for GPU work.");
DEFINE_string2(expectations, r, "",
"If a directory, compare generated images against images under this path. "
"If a file, compare generated images against JSON expectations at this path."
@@ -192,6 +192,7 @@ int dm_main();
int dm_main() {
SetupCrashHandler();
SkAutoGraphics ag;
+ SkTaskGroup::Enabler enabled(FLAGS_threads);
if (FLAGS_dryRun) {
FLAGS_verbose = true;
@@ -233,7 +234,8 @@ int dm_main() {
SkDebugf("%d GMs x %d configs, %d tests, %d pictures\n",
gms.count(), configs.count(), tests.count(), skps.count());
DM::Reporter reporter;
- DM::TaskRunner tasks(FLAGS_threads, FLAGS_gpuThreads);
+
+ DM::TaskRunner tasks;
kick_off_tests(tests, &reporter, &tasks);
kick_off_gms(gms, configs, gpuAPI, *expectations, &reporter, &tasks);
kick_off_skps(skps, &reporter, &tasks);
« no previous file with comments | « no previous file | dm/DMQuiltTask.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698