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

Unified Diff: tools/perf/benchmarks/page_cycler_v2.py

Issue 2534243002: [tools/perf] Enable loading metrics for common system health benchmarks (Closed)
Patch Set: Fix loading.cluster_telemetry Created 4 years, 1 month 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/perf/benchmarks/loading.py ('k') | tools/perf/benchmarks/system_health.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/perf/benchmarks/page_cycler_v2.py
diff --git a/tools/perf/benchmarks/page_cycler_v2.py b/tools/perf/benchmarks/page_cycler_v2.py
index 0aaae403d834bd995b3b08ae574cc8f9736be02c..4e5b4aa5474f8e198fa903c2fe722056ff2d2a41 100644
--- a/tools/perf/benchmarks/page_cycler_v2.py
+++ b/tools/perf/benchmarks/page_cycler_v2.py
@@ -13,12 +13,11 @@ import page_sets
from telemetry import benchmark
from telemetry.page import cache_temperature
-from telemetry.timeline import chrome_trace_category_filter
from telemetry.web_perf import timeline_based_measurement
-def TimelineBasedMeasurementOptionsForLoadingMetric():
- cat_filter = chrome_trace_category_filter.ChromeTraceCategoryFilter()
+def AugmentOptionsForLoadingMetrics(tbm_options):
+ cat_filter = tbm_options.config.chrome_trace_config.category_filter
# "blink.console" is used for marking ranges in
# cache_temperature.MarkTelemetryInternal.
@@ -36,9 +35,7 @@ def TimelineBasedMeasurementOptionsForLoadingMetric():
# necessary to compute time-to-interactive.
cat_filter.AddIncludedCategory('toplevel')
- tbm_options = timeline_based_measurement.Options(
- overhead_level=cat_filter)
- tbm_options.SetTimelineBasedMetrics(['loadingMetric'])
+ tbm_options.AddTimelineBasedMetric('loadingMetric')
return tbm_options
@@ -46,7 +43,9 @@ class _PageCyclerV2(perf_benchmark.PerfBenchmark):
options = {'pageset_repeat': 2}
def CreateTimelineBasedMeasurementOptions(self):
- return TimelineBasedMeasurementOptionsForLoadingMetric()
+ tbm_options = timeline_based_measurement.Options()
+ AugmentOptionsForLoadingMetrics(tbm_options)
+ return tbm_options
@classmethod
def ShouldDisable(cls, possible_browser):
« no previous file with comments | « tools/perf/benchmarks/loading.py ('k') | tools/perf/benchmarks/system_health.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698