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

Side by Side Diff: tools/profile_chrome/chrome_startup_controller.py

Issue 1332603002: [Android] Move perf utilities into devil. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: redirections for v8 Created 5 years, 3 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 | « build/android/pylib/perf/thermal_throttle.py ('k') | tools/profile_chrome/perf_controller.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 2015 The Chromium Authors. All rights reserved. 1 # Copyright 2015 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 os 5 import os
6 import re 6 import re
7 import time 7 import time
8 8
9 from devil.android.perf import cache_control
10 from devil.android.sdk import intent
9 from pylib import flag_changer 11 from pylib import flag_changer
10 from pylib.device import intent
11 from pylib.perf import cache_control
12 12
13 from profile_chrome import controllers 13 from profile_chrome import controllers
14 14
15 class ChromeStartupTracingController(controllers.BaseController): 15 class ChromeStartupTracingController(controllers.BaseController):
16 def __init__(self, device, package_info, cold, url): 16 def __init__(self, device, package_info, cold, url):
17 self._device = device 17 self._device = device
18 self._package_info = package_info 18 self._package_info = package_info
19 self._cold = cold 19 self._cold = cold
20 self._logcat_monitor = self._device.GetLogcatMonitor() 20 self._logcat_monitor = self._device.GetLogcatMonitor()
21 self._url = url 21 self._url = url
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 finally: 65 finally:
66 self._TearDownTracing() 66 self._TearDownTracing()
67 67
68 def PullTrace(self): 68 def PullTrace(self):
69 # Wait a bit for the browser to finish writing the trace file. 69 # Wait a bit for the browser to finish writing the trace file.
70 time.sleep(3) 70 time.sleep(3)
71 trace_file = self._trace_file.replace('/storage/emulated/0/', '/sdcard/') 71 trace_file = self._trace_file.replace('/storage/emulated/0/', '/sdcard/')
72 host_file = os.path.join(os.path.curdir, os.path.basename(trace_file)) 72 host_file = os.path.join(os.path.curdir, os.path.basename(trace_file))
73 self._device.PullFile(trace_file, host_file) 73 self._device.PullFile(trace_file, host_file)
74 return host_file 74 return host_file
OLDNEW
« no previous file with comments | « build/android/pylib/perf/thermal_throttle.py ('k') | tools/profile_chrome/perf_controller.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698