Bug 1354842 - Back out
bug 1255911 because the subprocess marker time adjustment is now done in perf.html. r?mconley
MozReview-Commit-ID: 5AhYa4axOJX
--- a/testing/talos/talos/profiler/symbolication.py
+++ b/testing/talos/talos/profiler/symbolication.py
@@ -122,17 +122,16 @@ class LinuxSymbolDumper:
class ProfileSymbolicator:
def __init__(self, options):
self.options = options
self.sym_file_manager = SymFileManager(self.options)
self.symbol_dumper = self.get_symbol_dumper()
- self.main_start_time = None
def get_symbol_dumper(self):
try:
if platform.system() == "Darwin":
return OSXSymbolDumper()
elif platform.system() == "Linux":
return LinuxSymbolDumper()
except SymbolError:
@@ -257,40 +256,21 @@ class ProfileSymbolicator:
shared_libraries = profile_json["libs"]
addresses = self._find_addresses(profile_json)
symbols_to_resolve = self._assign_symbols_to_libraries(
addresses, shared_libraries)
symbolication_table = self._resolve_symbols(symbols_to_resolve)
self._substitute_symbols(profile_json, symbolication_table)
- profile_start_time = profile_json["meta"].get("startTime", 0)
- delta_time = 0
-
- # The profile in the main process will have the startTime that
- # we'll offset our markers by, and also happens to be the one
- # we'll see first when recursively symbolicating, so we'll stash
- # it in main_start_time.
- if self.main_start_time is None:
- self.main_start_time = profile_start_time
- else:
- # We're a subprocess, so our markers will need to be offset
- # by the difference between the parent process start time
- # and this process's start time.
- delta_time = profile_start_time - self.main_start_time
-
for i, thread in enumerate(profile_json["threads"]):
if isinstance(thread, basestring):
thread_json = json.loads(thread)
self.symbolicate_profile(thread_json)
profile_json["threads"][i] = json.dumps(thread_json)
- else:
- for marker in thread["markers"]["data"]:
- if marker[1]:
- marker[1] += delta_time
def _find_addresses(self, profile_json):
addresses = set()
for thread in profile_json["threads"]:
if isinstance(thread, basestring):
continue
for s in thread["stringTable"]:
if s[0:2] == "0x":