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

Side by Side Diff: build/android/pylib/perf/surface_stats_collector.py

Issue 1314313004: [Android][telemetry] Update pylib imports for modules that moved into devil. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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/setup.py ('k') | build/android/pylib/perf/test_runner.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 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 Queue 5 import Queue
6 import datetime 6 import datetime
7 import logging 7 import logging
8 import re 8 import re
9 import threading 9 import threading
10 from pylib.device import device_utils 10
11 from devil.android import device_utils
11 12
12 13
13 # Log marker containing SurfaceTexture timestamps. 14 # Log marker containing SurfaceTexture timestamps.
14 _SURFACE_TEXTURE_TIMESTAMPS_MESSAGE = 'SurfaceTexture update timestamps' 15 _SURFACE_TEXTURE_TIMESTAMPS_MESSAGE = 'SurfaceTexture update timestamps'
15 _SURFACE_TEXTURE_TIMESTAMP_RE = r'\d+' 16 _SURFACE_TEXTURE_TIMESTAMP_RE = r'\d+'
16 17
17 18
18 class SurfaceStatsCollector(object): 19 class SurfaceStatsCollector(object):
19 """Collects surface stats for a SurfaceView from the output of SurfaceFlinger. 20 """Collects surface stats for a SurfaceView from the output of SurfaceFlinger.
20 21
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 fields = line.split() 179 fields = line.split()
179 if len(fields) != 3: 180 if len(fields) != 3:
180 continue 181 continue
181 timestamp = long(fields[1]) 182 timestamp = long(fields[1])
182 if timestamp == pending_fence_timestamp: 183 if timestamp == pending_fence_timestamp:
183 continue 184 continue
184 timestamp /= nanoseconds_per_millisecond 185 timestamp /= nanoseconds_per_millisecond
185 timestamps.append(timestamp) 186 timestamps.append(timestamp)
186 187
187 return (refresh_period, timestamps) 188 return (refresh_period, timestamps)
OLDNEW
« no previous file with comments | « build/android/pylib/perf/setup.py ('k') | build/android/pylib/perf/test_runner.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698