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

Unified Diff: dm/DM.cpp

Issue 1158263004: Add prelog flag to DM (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | 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 62d5cfbf0440b4be743209aa8751314bc2160ee2..55563fef08997dcf08f941c733577e51d3103ff6 100644
--- a/dm/DM.cpp
+++ b/dm/DM.cpp
@@ -48,6 +48,7 @@ DEFINE_string(uninterestingHashesFile, "",
DEFINE_int32(shards, 1, "We're splitting source data into this many shards.");
DEFINE_int32(shard, 0, "Which shard do I run?");
+DEFINE_bool2(pre_log, p, false, "Log before running each test. May be incomprehensible when threading");
__SK_FORCE_IMAGE_DECODER_LINKING;
using namespace DM;
@@ -466,6 +467,9 @@ struct Task {
if (!FLAGS_dryRun && whyBlacklisted.isEmpty()) {
SkBitmap bitmap;
SkDynamicMemoryWStream stream;
+ if (FLAGS_pre_log) {
+ SkDebugf("\nRunning %s->%s", name.c_str(), task->sink.tag);
+ }
start(task->sink.tag, task->src.tag, task->src.options, name.c_str());
Error err = task->sink->draw(*task->src, &bitmap, &stream, &log);
if (!err.isEmpty()) {
@@ -657,6 +661,9 @@ static void run_test(skiatest::Test* test) {
if (!FLAGS_dryRun) {
start("unit", "test", "", test->name);
GrContextFactory factory;
+ if (FLAGS_pre_log) {
+ SkDebugf("\nRunning test %s", test->name);
+ }
test->proc(&reporter, &factory);
}
timer.end();
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698