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

Unified Diff: tools/telemetry/telemetry/core/backends/chrome/chrome_browser_backend.py

Issue 29423005: telemetry: Add GetRendererProcessFromTab to timeline model. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix smoothness_unittest.py. Created 7 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/backends/chrome/chrome_browser_backend.py
diff --git a/tools/telemetry/telemetry/core/backends/chrome/chrome_browser_backend.py b/tools/telemetry/telemetry/core/backends/chrome/chrome_browser_backend.py
index f8f620bc9d0fabe9d9b466d0b23d8827d656a4b2..169977c8d8eea9791a30d9b01688f243c4405672 100644
--- a/tools/telemetry/telemetry/core/backends/chrome/chrome_browser_backend.py
+++ b/tools/telemetry/telemetry/core/backends/chrome/chrome_browser_backend.py
@@ -252,7 +252,15 @@ class ChromeBrowserBackend(browser_backend.BrowserBackend):
"""
if self._tracing_backend is None:
self._tracing_backend = tracing_backend.TracingBackend(self._port)
- return self._tracing_backend.StartTracing(custom_categories, timeout)
+ first_nested_call = self._tracing_backend.StartTracing(
+ custom_categories, timeout)
+ for (i, debugger_url) in enumerate(self._browser.tabs):
nduca 2013/10/31 07:32:02 you need to make sure you close the inspector sess
ernstm 2013/11/05 00:25:05 I moved the iteration to StopTracing. Do you think
+ tab = self.tab_list_backend.Get(i, None)
+ if tab:
+ tab.ExecuteJavaScript('console.time("' + debugger_url + '")')
+ tab.ExecuteJavaScript('console.timeEnd("' + debugger_url + '")')
+ self._tracing_backend.AddTabToMarkerMapping(tab, debugger_url)
+ return first_nested_call
def StopTracing(self):
""" Stops tracing and returns the result as TraceResult object. """

Powered by Google App Engine
This is Rietveld 408576698