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

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

Issue 1083413002: Remove repaint's reliance on auto issuing marker feature of smoothness_controller (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 8 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 | tools/perf/measurements/repaint_unittest.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 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 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 telemetry.page import page_test 5 from telemetry.page import page_test
6 6
7 from measurements import smoothness_controller 7 from measurements import smoothness_controller
8 8
9 9
10 class Repaint(page_test.PageTest): 10 class Repaint(page_test.PageTest):
11 def __init__(self, mode='viewport', width=None, height=None): 11 def __init__(self, mode='viewport', width=None, height=None):
12 super(Repaint, self).__init__() 12 super(Repaint, self).__init__()
13 self._smoothness_controller = None 13 self._smoothness_controller = None
14 self._micro_benchmark_id = None 14 self._micro_benchmark_id = None
15 self._mode = mode 15 self._mode = mode
16 self._width = width 16 self._width = width
17 self._height = height 17 self._height = height
18 18
19 def CustomizeBrowserOptions(self, options): 19 def CustomizeBrowserOptions(self, options):
20 options.AppendExtraBrowserArgs([ 20 options.AppendExtraBrowserArgs([
21 '--enable-impl-side-painting', 21 '--enable-impl-side-painting',
22 '--enable-threaded-compositing', 22 '--enable-threaded-compositing',
23 '--enable-gpu-benchmarking' 23 '--enable-gpu-benchmarking'
24 ]) 24 ])
25 25
26 def WillRunActions(self, page, tab): 26 def WillRunActions(self, page, tab):
27 tab.WaitForDocumentReadyStateToBeComplete() 27 tab.WaitForDocumentReadyStateToBeComplete()
28 self._smoothness_controller = smoothness_controller.SmoothnessController() 28 self._smoothness_controller = smoothness_controller.SmoothnessController(
29 auto_issuing_marker=False)
29 self._smoothness_controller.SetUp(page, tab) 30 self._smoothness_controller.SetUp(page, tab)
30 self._smoothness_controller.Start(tab) 31 self._smoothness_controller.Start(tab)
31 # Rasterize only what's visible. 32 # Rasterize only what's visible.
32 tab.ExecuteJavaScript( 33 tab.ExecuteJavaScript(
33 'chrome.gpuBenchmarking.setRasterizeOnlyVisibleContent();') 34 'chrome.gpuBenchmarking.setRasterizeOnlyVisibleContent();')
34 35
35 args = {} 36 args = {}
36 args['mode'] = self._mode 37 args['mode'] = self._mode
37 if self._width: 38 if self._width:
38 args['width'] = self._width 39 args['width'] = self._width
(...skipping 25 matching lines...) Expand all
64 "notify_done": true 65 "notify_done": true
65 }); 66 });
66 """) 67 """)
67 self._smoothness_controller.Stop(tab) 68 self._smoothness_controller.Stop(tab)
68 69
69 def ValidateAndMeasurePage(self, page, tab, results): 70 def ValidateAndMeasurePage(self, page, tab, results):
70 self._smoothness_controller.AddResults(tab, results) 71 self._smoothness_controller.AddResults(tab, results)
71 72
72 def CleanUpAfterPage(self, _, tab): 73 def CleanUpAfterPage(self, _, tab):
73 self._smoothness_controller.CleanUp(tab) 74 self._smoothness_controller.CleanUp(tab)
OLDNEW
« no previous file with comments | « no previous file | tools/perf/measurements/repaint_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698