Extract an interface from the perf results logger.
The new interface is called PerfTestResultWriter and is currently
implemented by PerfResultsLogger (renamed PerfTestGraphJsonWriter).
I plan to introduce a second implementation of the perf logger that
uses the new Histogram C++ API. I add a flag that chooses
between the two implementations so I can try it out (perhaps by
setting up a second, limited run of webrtc_perf_tests on the perf
bots that uses the new implementation). The histogram C++
implementation will come in the next patch.
As a side effect, I disentangled the plottable counter printer from
the perf result printer so it will work for both implementations.
The only thing they had in common was that both wrote JSON anyway.
See the bug for details on the new API.
Bug: chromium:1029452
Change-Id: Icb21b25ced08ea73aeecd221e9d51f2adf3dab1b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/165389
Reviewed-by: Artem Titov <titovartem@webrtc.org>
Commit-Queue: Patrik Höglund <phoglund@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#30243}
diff --git a/PRESUBMIT.py b/PRESUBMIT.py
index c200609..08e6024 100755
--- a/PRESUBMIT.py
+++ b/PRESUBMIT.py
@@ -502,7 +502,10 @@
is_test = any(file_path.endswith(x) for x in ['_test.cc', '_tests.cc',
'_unittest.cc',
'_unittests.cc'])
- return file_path.startswith('examples') or is_test
+ return (file_path.startswith('examples') or
+ file_path.startswith('test') or
+ is_test)
+
for f in input_api.AffectedSourceFiles(file_filter):
# Usage of stringstream is allowed under examples/ and in tests.