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

Side by Side Diff: tools/perf/benchmarks/battor.py

Issue 2344723003: [telemetry] Disable the CPU tracing agent for BattOr benchmarks (Closed)
Patch Set: Sync to head Created 4 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2016 The Chromium Authors. All rights reserved. 1 # Copyright 2016 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 from core import perf_benchmark 5 from core import perf_benchmark
6 from telemetry.timeline import chrome_trace_category_filter 6 from telemetry.timeline import chrome_trace_category_filter
7 from telemetry.web_perf import timeline_based_measurement 7 from telemetry.web_perf import timeline_based_measurement
8 import page_sets 8 import page_sets
9 from telemetry import benchmark 9 from telemetry import benchmark
10 10
11 11
12 # TODO(rnephew): Remove BattOr naming from all benchmarks once the BattOr tests 12 # TODO(rnephew): Remove BattOr naming from all benchmarks once the BattOr tests
13 # are the primary means of benchmarking power. 13 # are the primary means of benchmarking power.
14 class _BattOrBenchmark(perf_benchmark.PerfBenchmark): 14 class _BattOrBenchmark(perf_benchmark.PerfBenchmark):
15 15
16 def CreateTimelineBasedMeasurementOptions(self): 16 def CreateTimelineBasedMeasurementOptions(self):
17 category_filter = chrome_trace_category_filter.ChromeTraceCategoryFilter( 17 category_filter = chrome_trace_category_filter.ChromeTraceCategoryFilter(
18 filter_string='toplevel') 18 filter_string='toplevel')
19 options = timeline_based_measurement.Options(category_filter) 19 options = timeline_based_measurement.Options(category_filter)
20 options.config.chrome_trace_config.category_filter.AddFilterString('rail') 20 options.config.chrome_trace_config.category_filter.AddFilterString('rail')
21 # TODO(charliea): Reenable the CPU tracing agent once it no longer causes
22 # indefinite hangs on Windows.
23 # https://crbug.com/647443
21 options.config.enable_battor_trace = True 24 options.config.enable_battor_trace = True
22 options.config.enable_chrome_trace = True 25 options.config.enable_chrome_trace = True
23 options.config.enable_atrace_trace = True 26 options.config.enable_atrace_trace = True
24 options.config.atrace_config.categories = ['sched'] 27 options.config.atrace_config.categories = ['sched']
25 options.config.enable_cpu_trace = True
26 options.SetTimelineBasedMetrics( 28 options.SetTimelineBasedMetrics(
27 ['powerMetric', 'clockSyncLatencyMetric', 'cpuTimeMetric']) 29 ['powerMetric', 'clockSyncLatencyMetric', 'cpuTimeMetric'])
28 return options 30 return options
29 31
30 @classmethod 32 @classmethod
31 def ShouldDisable(cls, possible_browser): 33 def ShouldDisable(cls, possible_browser):
32 # Only run if BattOr is detected. 34 # Only run if BattOr is detected.
33 if not possible_browser.platform.HasBattOrConnected(): 35 if not possible_browser.platform.HasBattOrConnected():
34 return True 36 return True
35 37
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 @benchmark.Enabled('mac') 138 @benchmark.Enabled('mac')
137 class BattOrSteadyStatePages(_BattOrBenchmark): 139 class BattOrSteadyStatePages(_BattOrBenchmark):
138 140
139 def CreateStorySet(self, options): 141 def CreateStorySet(self, options):
140 # We want it to wait for 30 seconds to be comparable to legacy power tests. 142 # We want it to wait for 30 seconds to be comparable to legacy power tests.
141 return page_sets.IdleAfterLoadingStories(wait_in_seconds=30) 143 return page_sets.IdleAfterLoadingStories(wait_in_seconds=30)
142 144
143 @classmethod 145 @classmethod
144 def Name(cls): 146 def Name(cls):
145 return 'battor.steady_state' 147 return 'battor.steady_state'
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698