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

Unified Diff: apps/benchmark/run_args.cc

Issue 1394963002: Adds a couple more measures to the benchmarking app (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Format Created 5 years, 2 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
Index: apps/benchmark/run_args.cc
diff --git a/apps/benchmark/run_args.cc b/apps/benchmark/run_args.cc
index 8921a96137596001f453a2fb6bead5c47180975f..d36b444cd1f15af4aa3f008506752781e075d3bb 100644
--- a/apps/benchmark/run_args.cc
+++ b/apps/benchmark/run_args.cc
@@ -53,6 +53,16 @@ bool GetMeasurement(const std::string& measurement_spec, Measurement* result) {
return false;
*result = Measurement(MeasurementType::AVG_DURATION,
EventSpec(parts[2], parts[1]));
+ } else if (parts[0] == "median_duration") {
+ if (!CheckMeasurementFormat(parts[0], 3, parts.size()))
+ return false;
+ *result = Measurement(MeasurementType::MEDIAN_DURATION,
+ EventSpec(parts[2], parts[1]));
+ } else if (parts[0] == "dist_duration") {
+ if (!CheckMeasurementFormat(parts[0], 3, parts.size()))
+ return false;
+ *result = Measurement(MeasurementType::DIST_DURATION,
+ EventSpec(parts[2], parts[1]));
} else {
LOG(ERROR) << "Could not recognize the measurement type: " << parts[0];
return false;

Powered by Google App Engine
This is Rietveld 408576698