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

Side by Side Diff: tools/perf/measurements/record_per_area.py

Issue 1169193003: [SP] Enable Slimming Paint by default in Chromium and Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merge changes. Created 5 years, 6 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/metrics/histograms/histograms.xml ('k') | 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 2013 The Chromium Authors. All rights reserved. 1 # Copyright 2013 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 time 5 import time
6 6
7 from telemetry.page import page_test 7 from telemetry.page import page_test
8 from telemetry.value import scalar 8 from telemetry.value import scalar
9 9
10 from measurements import smoothness 10 from measurements import smoothness
11 11
12 12
13 class RecordPerArea(page_test.PageTest): 13 class RecordPerArea(page_test.PageTest):
14 def __init__(self, start_wait_time=2): 14 def __init__(self, start_wait_time=2):
15 super(RecordPerArea, self).__init__( 15 super(RecordPerArea, self).__init__(
16 needs_browser_restart_after_each_page=True) 16 needs_browser_restart_after_each_page=True)
17 self._start_wait_time = start_wait_time 17 self._start_wait_time = start_wait_time
18 18
19 def CustomizeBrowserOptions(self, options): 19 def CustomizeBrowserOptions(self, options):
20 smoothness.Smoothness.CustomizeBrowserOptions(options) 20 smoothness.Smoothness.CustomizeBrowserOptions(options)
21 options.AppendExtraBrowserArgs([ 21 options.AppendExtraBrowserArgs([
22 '--enable-impl-side-painting', 22 '--enable-impl-side-painting',
23 '--enable-threaded-compositing', 23 '--enable-threaded-compositing',
24 '--enable-gpu-benchmarking' 24 '--enable-gpu-benchmarking',
25 # TODO(wkorman): Remove slimming paint disablement once we've sorted
26 # alternate testing. http://crbug.com/498936
27 '--disable-slimming-paint'
aiolos (Not reviewing) 2015/06/11 19:49:11 Two questions: 1) What are you trying to do with
25 ]) 28 ])
26 29
27 def ValidateAndMeasurePage(self, page, tab, results): 30 def ValidateAndMeasurePage(self, page, tab, results):
28 # Wait until the page has loaded and come to a somewhat steady state. 31 # Wait until the page has loaded and come to a somewhat steady state.
29 # Needs to be adjusted for every device (~2 seconds for workstation). 32 # Needs to be adjusted for every device (~2 seconds for workstation).
30 time.sleep(self._start_wait_time) 33 time.sleep(self._start_wait_time)
31 34
32 # Enqueue benchmark 35 # Enqueue benchmark
33 tab.ExecuteJavaScript(""" 36 tab.ExecuteJavaScript("""
34 window.benchmark_results = {}; 37 window.benchmark_results = {};
(...skipping 17 matching lines...) Expand all
52 all_data = tab.EvaluateJavaScript('window.benchmark_results.results') 55 all_data = tab.EvaluateJavaScript('window.benchmark_results.results')
53 for data in all_data: 56 for data in all_data:
54 width = data['width'] 57 width = data['width']
55 height = data['height'] 58 height = data['height']
56 area = width * height 59 area = width * height
57 time_ms = data['time_ms'] 60 time_ms = data['time_ms']
58 61
59 results.AddValue(scalar.ScalarValue( 62 results.AddValue(scalar.ScalarValue(
60 results.current_page, 'area_%07d_%dx%d' % (area, width, height), 63 results.current_page, 'area_%07d_%dx%d' % (area, width, height),
61 'ms', time_ms)) 64 'ms', time_ms))
OLDNEW
« no previous file with comments | « tools/metrics/histograms/histograms.xml ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698