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

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

Issue 2162283002: [telemetry] Trace config should be used to disable periodic dumps (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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 | « tools/perf/benchmarks/oortonline.py ('k') | tools/perf/benchmarks/v8.py » ('j') | 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 import re 5 import re
6 6
7 from core import perf_benchmark 7 from core import perf_benchmark
8 from telemetry import benchmark 8 from telemetry import benchmark
9 from telemetry.timeline import chrome_trace_category_filter 9 from telemetry.timeline import chrome_trace_category_filter
10 from telemetry.timeline import chrome_trace_config
10 from telemetry.web_perf import timeline_based_measurement 11 from telemetry.web_perf import timeline_based_measurement
11 import page_sets 12 import page_sets
12 13
13 14
14 # See tr.v.Numeric.getSummarizedScalarNumericsWithNames() 15 # See tr.v.Numeric.getSummarizedScalarNumericsWithNames()
15 # https://github.com/catapult-project/catapult/blob/master/tracing/tracing/value /numeric.html#L323 16 # https://github.com/catapult-project/catapult/blob/master/tracing/tracing/value /numeric.html#L323
16 _IGNORED_STATS_RE = re.compile(r'_(std|count|max|min|sum|pct_\d{4}(_\d+)?)$') 17 _IGNORED_STATS_RE = re.compile(r'_(std|count|max|min|sum|pct_\d{4}(_\d+)?)$')
17 18
18 19
19 class _SystemHealthBenchmark(perf_benchmark.PerfBenchmark): 20 class _SystemHealthBenchmark(perf_benchmark.PerfBenchmark):
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 def Name(cls): 57 def Name(cls):
57 return 'system_health.key_mobile_sites' 58 return 'system_health.key_mobile_sites'
58 59
59 60
60 class _MemorySystemHealthBenchmark(perf_benchmark.PerfBenchmark): 61 class _MemorySystemHealthBenchmark(perf_benchmark.PerfBenchmark):
61 """Chrome Memory System Health Benchmark. 62 """Chrome Memory System Health Benchmark.
62 63
63 https://goo.gl/Jek2NL. 64 https://goo.gl/Jek2NL.
64 """ 65 """
65 66
66 def SetExtraBrowserOptions(self, options):
67 options.AppendExtraBrowserArgs([
68 # TODO(perezju): Temporary workaround to disable periodic memory dumps.
69 # See: http://crbug.com/513692
70 '--enable-memory-benchmarking',
71 ])
72
73 def CreateTimelineBasedMeasurementOptions(self): 67 def CreateTimelineBasedMeasurementOptions(self):
74 options = timeline_based_measurement.Options( 68 options = timeline_based_measurement.Options(
75 chrome_trace_category_filter.ChromeTraceCategoryFilter( 69 chrome_trace_category_filter.ChromeTraceCategoryFilter(
76 '-*,disabled-by-default-memory-infra')) 70 '-*,disabled-by-default-memory-infra'))
77 options.config.enable_android_graphics_memtrack = True 71 options.config.enable_android_graphics_memtrack = True
78 options.SetTimelineBasedMetrics(['memoryMetric']) 72 options.SetTimelineBasedMetrics(['memoryMetric'])
73 # Setting an empty memory dump config disables periodic dumps.
74 options.config.chrome_trace_config.SetMemoryDumpConfig(
75 chrome_trace_config.MemoryDumpConfig())
79 return options 76 return options
80 77
81 def CreateStorySet(self, options): 78 def CreateStorySet(self, options):
82 return page_sets.SystemHealthStorySet(platform=self.PLATFORM, 79 return page_sets.SystemHealthStorySet(platform=self.PLATFORM,
83 take_memory_measurement=True) 80 take_memory_measurement=True)
84 81
85 @classmethod 82 @classmethod
86 def Name(cls): 83 def Name(cls):
87 return 'system_health.memory_%s' % cls.PLATFORM 84 return 'system_health.memory_%s' % cls.PLATFORM
88 85
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 options.config.atrace_config.app_name = 'org.chromium.webview_shell' 134 options.config.atrace_config.app_name = 'org.chromium.webview_shell'
138 return options 135 return options
139 136
140 @classmethod 137 @classmethod
141 def ShouldTearDownStateAfterEachStoryRun(cls): 138 def ShouldTearDownStateAfterEachStoryRun(cls):
142 return True 139 return True
143 140
144 @classmethod 141 @classmethod
145 def Name(cls): 142 def Name(cls):
146 return 'system_health.webview_startup' 143 return 'system_health.webview_startup'
OLDNEW
« no previous file with comments | « tools/perf/benchmarks/oortonline.py ('k') | tools/perf/benchmarks/v8.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698