Index: build/android/pylib/perf_tests_helper.py |
diff --git a/build/android/pylib/perf_tests_helper.py b/build/android/pylib/perf_tests_helper.py |
index bec92a20d2a1bcb308322ba658d08b5c7e304692..942c617226d2d83ed5c7209c7fb0780e46b75955 100644 |
--- a/build/android/pylib/perf_tests_helper.py |
+++ b/build/android/pylib/perf_tests_helper.py |
@@ -23,6 +23,9 @@ def _EscapePerfResult(s): |
def GeomMeanAndStdDevFromHistogram(histogram_json): |
histogram = json.loads(histogram_json) |
+ # Handle empty histograms gracefully. |
+ if not 'buckets' in histogram: |
+ return 0.0, 0.0 |
count = 0 |
sum_of_logs = 0 |
for bucket in histogram['buckets']: |