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

Side by Side Diff: tools/perf/perf_tools/page_cycler.py

Issue 12278015: [Telemetry] Reorganize everything. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Re-add shebangs. Created 7 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « tools/perf/perf_tools/octane.py ('k') | tools/perf/perf_tools/robohornetpro.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 (c) 2012 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2012 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 from telemetry.core import util
5 from telemetry import multi_page_benchmark 5 from telemetry.page import multi_page_benchmark
6 from telemetry import util
7 6
8 MEMORY_HISTOGRAMS = [ 7 MEMORY_HISTOGRAMS = [
9 {'name': 'V8.MemoryExternalFragmentationTotal', 'units': 'percent'}, 8 {'name': 'V8.MemoryExternalFragmentationTotal', 'units': 'percent'},
10 {'name': 'V8.MemoryHeapSampleTotalCommitted', 'units': 'kb'}, 9 {'name': 'V8.MemoryHeapSampleTotalCommitted', 'units': 'kb'},
11 {'name': 'V8.MemoryHeapSampleTotalUsed', 'units': 'kb'}] 10 {'name': 'V8.MemoryHeapSampleTotalUsed', 'units': 'kb'}]
12 11
13 class PageCycler(multi_page_benchmark.MultiPageBenchmark): 12 class PageCycler(multi_page_benchmark.MultiPageBenchmark):
14 def CustomizeBrowserOptions(self, options): 13 def CustomizeBrowserOptions(self, options):
15 options.AppendExtraBrowserArg('--dom-automation') 14 options.AppendExtraBrowserArg('--dom-automation')
16 options.AppendExtraBrowserArg('--js-flags=--expose_gc') 15 options.AppendExtraBrowserArg('--js-flags=--expose_gc')
(...skipping 12 matching lines...) Expand all
29 'window.domAutomationController.getHistogram("%s")' % name) 28 'window.domAutomationController.getHistogram("%s")' % name)
30 results.Add(name, histogram['units'], data, data_type='histogram') 29 results.Add(name, histogram['units'], data, data_type='histogram')
31 30
32 def _IsNavigatedToReport(): 31 def _IsNavigatedToReport():
33 return tab.GetCookieByName('__navigated_to_report') == '1' 32 return tab.GetCookieByName('__navigated_to_report') == '1'
34 util.WaitFor(_IsNavigatedToReport, 60, poll_interval=5) 33 util.WaitFor(_IsNavigatedToReport, 60, poll_interval=5)
35 timings = tab.EvaluateJavaScript('__get_timings()').split(',') 34 timings = tab.EvaluateJavaScript('__get_timings()').split(',')
36 results.Add('t', 'ms', [int(t) for t in timings], chart_name='times') 35 results.Add('t', 'ms', [int(t) for t in timings], chart_name='times')
37 36
38 # TODO(tonyg): Add version that runs with extension profile. 37 # TODO(tonyg): Add version that runs with extension profile.
OLDNEW
« no previous file with comments | « tools/perf/perf_tools/octane.py ('k') | tools/perf/perf_tools/robohornetpro.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698