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

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

Issue 1647513002: Delete tools/telemetry. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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/internal/platform/profiler/v8_profiler.py
diff --git a/tools/telemetry/telemetry/internal/platform/profiler/v8_profiler.py b/tools/telemetry/telemetry/internal/platform/profiler/v8_profiler.py
deleted file mode 100644
index b40ad1903b938afb66418901e7b2f3d6e8ccfdbd..0000000000000000000000000000000000000000
--- a/tools/telemetry/telemetry/internal/platform/profiler/v8_profiler.py
+++ /dev/null
@@ -1,54 +0,0 @@
-# Copyright 2013 The Chromium Authors. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-import logging
-import re
-import tempfile
-
-from telemetry.internal.platform import profiler
-
-
-class V8Profiler(profiler.Profiler):
-
- _V8_ARG = '--js-flags=--logfile=%s --prof --log-timer-events'
-
- @classmethod
- def name(cls):
- return 'v8'
-
- @classmethod
- def is_supported(cls, browser_type):
- return not browser_type.startswith('cros')
-
- @classmethod
- def CustomizeBrowserOptions(cls, browser_type, options):
- if browser_type.startswith('android'):
- dump_file = '/data/local/tmp/v8-profile.log'
- else:
- dump_file = tempfile.mkstemp()[1]
- options.AppendExtraBrowserArgs([cls._V8_ARG % dump_file, '--no-sandbox'])
-
- def CollectProfile(self):
- # Find output filename from browser argument.
- for i in self._browser_backend.browser_options.extra_browser_args:
- match = re.match(self._V8_ARG % r'(\S+)', i)
- if match:
- output_file = match.groups(0)[0]
- assert output_file
- # On Android pull the output file to the host.
- if self._platform_backend.GetOSName() == 'android':
- host_output_file = '%s.log' % self._output_path
- try:
- self._browser_backend.device.PullFile(
- output_file, host_output_file)
- except:
- logging.exception('New exception caused by DeviceUtils conversion')
- raise
- # Clean the device
- self._browser_backend.device.RunShellCommand('rm %s' % output_file)
- output_file = host_output_file
- print 'V8 profile saved as %s' % output_file
- print 'To view, open in ' \
- 'http://v8.googlecode.com/svn/trunk/tools/tick-processor.html'
- return [output_file]

Powered by Google App Engine
This is Rietveld 408576698