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

Unified Diff: tools/telemetry/telemetry/internal/platform/profiler/java_heap_profiler.py

Issue 1526743004: [Android] Remove all references to pylib from telemetry. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@devil-video-recorder
Patch Set: remove SetupPrebuiltTools patchers Created 5 years 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
« no previous file with comments | « tools/telemetry/telemetry/internal/platform/efficient_android_directory_copy.sh ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/telemetry/telemetry/internal/platform/profiler/java_heap_profiler.py
diff --git a/tools/telemetry/telemetry/internal/platform/profiler/java_heap_profiler.py b/tools/telemetry/telemetry/internal/platform/profiler/java_heap_profiler.py
index 49307cbea644ebe3fe77283da0857f0033ead417..5ca082a29357452ff113e6d55507b31d8f9d318e 100644
--- a/tools/telemetry/telemetry/internal/platform/profiler/java_heap_profiler.py
+++ b/tools/telemetry/telemetry/internal/platform/profiler/java_heap_profiler.py
@@ -7,15 +7,15 @@ import os
import subprocess
import threading
+from telemetry.core import platform
from telemetry.core import util
from telemetry.internal.backends.chrome import android_browser_finder
from telemetry.internal.platform import profiler
+from telemetry.internal.util import binary_manager
try:
from devil.android import device_errors # pylint: disable=import-error
- from pylib import constants # pylint: disable=import-error
except ImportError:
- constants = None
device_errors = None
@@ -61,8 +61,10 @@ class JavaHeapProfiler(profiler.Profiler):
if os.path.splitext(f)[1] == '.aprof':
input_file = os.path.join(self._output_path, f)
output_file = input_file.replace('.aprof', '.hprof')
- hprof_conv = os.path.join(constants.ANDROID_SDK_ROOT,
- 'tools', 'hprof-conv')
+ hprof_conv = binary_manager.FetchPath(
+ 'hprof-conv',
+ platform.GetHostPlatform().GetArchName(),
+ platform.GetHostPlatform().GetOSName())
subprocess.call([hprof_conv, input_file, output_file])
output_files.append(output_file)
return output_files
« no previous file with comments | « tools/telemetry/telemetry/internal/platform/efficient_android_directory_copy.sh ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698