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

Unified Diff: tools/telemetry/telemetry/core/platform/profiler/perf_profiler.py

Issue 643973002: Add multi-architecture support in telemetry. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix trybot failure Created 6 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: tools/telemetry/telemetry/core/platform/profiler/perf_profiler.py
diff --git a/tools/telemetry/telemetry/core/platform/profiler/perf_profiler.py b/tools/telemetry/telemetry/core/platform/profiler/perf_profiler.py
index f41625fbb1b5deb9bf7d426b575993138b887d01..962e895ade5beb8c866d53f568d0b0bced85c6e2 100644
--- a/tools/telemetry/telemetry/core/platform/profiler/perf_profiler.py
+++ b/tools/telemetry/telemetry/core/platform/profiler/perf_profiler.py
@@ -58,7 +58,7 @@ def _InstallPerfHost():
host = platform.GetHostPlatform()
if not host.CanLaunchApplication(perfhost_name):
host.InstallApplication(perfhost_name)
- return support_binaries.FindPath(perfhost_name, 'linux')
+ return support_binaries.FindPath(perfhost_name, 'x86_64', 'linux')
class _SingleProcessPerfProfiler(object):
@@ -75,6 +75,7 @@ class _SingleProcessPerfProfiler(object):
self._output_file = output_file
self._tmp_output_file = tempfile.NamedTemporaryFile('w', 0)
self._is_android = platform_backend.GetOSName() == 'android'
+ self._perf_binary = perf_binary
self._perfhost_binary = perfhost_binary
cmd_prefix = []
perf_args = ['record', '--pid', str(pid)]
@@ -104,7 +105,8 @@ class _SingleProcessPerfProfiler(object):
if self._is_android:
device = self._browser_backend.adb.device()
try:
- device.KillAll('perf', signum=signal.SIGINT, blocking=True)
+ binary_name = os.path.basename(self._perf_binary)
+ device.KillAll(binary_name, signum=signal.SIGINT, blocking=True)
except device_errors.CommandFailedError:
logging.warning('The perf process could not be killed on the device.')
self._proc.send_signal(signal.SIGINT)

Powered by Google App Engine
This is Rietveld 408576698