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) |