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

Unified Diff: tools/bench_pictures_main.cpp

Issue 306483010: Revert of PictureBenchmark JSON logging (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 7 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 | « tools/PictureResultsWriter.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/bench_pictures_main.cpp
diff --git a/tools/bench_pictures_main.cpp b/tools/bench_pictures_main.cpp
index b79dfedff230f1eb0f799c3db1e51fce6d3ac3d8..5ff519c8c5e67e9aa6aef4ce47e3637f7197518f 100644
--- a/tools/bench_pictures_main.cpp
+++ b/tools/bench_pictures_main.cpp
@@ -12,7 +12,6 @@
#include "PictureRenderingFlags.h"
#include "SkBenchLogger.h"
#include "SkCommandLineFlags.h"
-#include "SkData.h"
#include "SkDiscardableMemoryPool.h"
#include "SkGraphics.h"
#include "SkImageDecoder.h"
@@ -21,11 +20,8 @@
#include "SkPicture.h"
#include "SkStream.h"
#include "picture_utils.h"
-#include "PictureResultsWriter.h"
SkBenchLogger gLogger;
-PictureResultsLoggerWriter gLogWriter(&gLogger);
-PictureResultsMultiWriter gWriter;
// Flags used by this file, in alphabetical order.
DEFINE_bool(countRAM, false, "Count the RAM used for bitmap pixels in each skp file");
@@ -39,9 +35,6 @@
"Specific flags are listed above.");
DEFINE_string(logFile, "", "Destination for writing log output, in addition to stdout.");
DEFINE_bool(logPerIter, false, "Log each repeat timer instead of mean.");
-#ifdef SK_BUILD_JSON_WRITER
-DEFINE_string(jsonLog, "", "Destination for writing JSON data.");
-#endif
DEFINE_bool(min, false, "Print the minimum times (instead of average).");
DECLARE_int32(multi);
DECLARE_string(readPath);
@@ -194,7 +187,10 @@
SkString filename;
sk_tools::get_basename(&filename, inputPath);
- gWriter.bench(filename.c_str(), picture->width(), picture->height());
+ SkString result;
+ result.printf("running bench [%i %i] %s ", picture->width(), picture->height(),
+ filename.c_str());
+ gLogger.logProgress(result);
benchmark.run(picture);
@@ -364,7 +360,7 @@
}
benchmark->setRenderer(renderer);
benchmark->setRepeats(FLAGS_repeat);
- benchmark->setWriter(&gWriter);
+ benchmark->setLogger(&gLogger);
}
static int process_input(const char* input,
@@ -421,16 +417,6 @@
}
}
-#ifdef SK_BUILD_JSON_WRITER
- SkAutoTDelete<PictureJSONResultsWriter> jsonWriter;
- if (FLAGS_jsonLog.count() == 1) {
- jsonWriter.reset(SkNEW(PictureJSONResultsWriter(FLAGS_jsonLog[0])));
- gWriter.add(jsonWriter.get());
- }
-
-#endif
- gWriter.add(&gLogWriter);
-
#if SK_ENABLE_INST_COUNT
gPrintInstCount = true;
@@ -458,7 +444,6 @@
(double) gTotalCacheHits / (gTotalCacheHits + gTotalCacheMisses));
}
#endif
- gWriter.end();
return 0;
}
« no previous file with comments | « tools/PictureResultsWriter.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698