tools/mac/symbolicate_crash.py
def Symbolicate(self, symbol_path):
    """Symbolicates a crash report stack trace."""
    # In order to be efficient, collect all the offsets that will be passed to
    # atos by the image name.
    offsets_by_image = self._CollectAddressesForImages(SYMBOL_IMAGE_MAP.keys())

    # For each image, run atos with the list of addresses.
    for image_name, addresses in offsets_by_image.items():
      # If this image was not loaded or is in no stacks, skip.
      if image_name not in self._binary_images or not len(addresses):
        continue

      # Combine the |image_name| and |symbol_path| into the path of the dSYM.
      dsym_file = self._GetDSymPath(symbol_path, image_name)

      # From the list of 2-Tuples of (frame, address), create a list of just
      # addresses.
      address_list = map(lambda x: x[1], addresses)

      # Look up the load address of the image.
      binary_base = self._binary_images[image_name][0]

      # This returns a list of just symbols. The indices will match up with the
      # list of |addresses|.
      symbol_names = self._RunAtos(binary_base, dsym_file, address_list)
      if not symbol_names:
        print('Error loading symbols for ' + image_name)
        continue

      # Attaches a list of symbol names to stack frames. This assumes that the
      # order of |addresses| has stayed the same as |symbol_names|.
      self._AddSymbolsToFrames(symbol_names, addresses)
Symbolicates a crash report stack trace.
Symbolicates a crash report stack trace.
Symbolicates a crash report stack trace .
def Symbolicate(self, symbol_path):
    offsets_by_image = self._CollectAddressesForImages(SYMBOL_IMAGE_MAP.keys())
    for image_name, addresses in offsets_by_image.items():
      if image_name not in self._binary_images or not len(addresses):
        continue
      dsym_file = self._GetDSymPath(symbol_path, image_name)
      address_list = map(lambda x: x[1], addresses)
      binary_base = self._binary_images[image_name][0]
      symbol_names = self._RunAtos(binary_base, dsym_file, address_list)
      if not symbol_names:
        print('Error loading symbols for ' + image_name)
        continue
      self._AddSymbolsToFrames(symbol_names, addresses)
def Symbolicate ( self , symbol_path ) : offsets_by_image = self . _CollectAddressesForImages ( SYMBOL_IMAGE_MAP . keys ( ) ) for image_name , addresses in offsets_by_image . items ( ) : if image_name not in self . _binary_images or not len ( addresses ) : continue dsym_file = self . _GetDSymPath ( symbol_path , image_name ) address_list = map ( lambda x : x [ 1 ] , addresses ) binary_base = self . _binary_images [ image_name ] [ 0 ] symbol_names = self . _RunAtos ( binary_base , dsym_file , address_list ) if not symbol_names : print ( 'Error loading symbols for ' + image_name ) continue self . _AddSymbolsToFrames ( symbol_names , addresses )
Symbolicates a crash report stack trace.
Symbolicates a crash report stack trace .
"""Symbolicates a crash report stack trace.""" # In order to be efficient, collect all the offsets that will be passed to # atos by the image name. # For each image, run atos with the list of addresses. # If this image was not loaded or is in no stacks, skip. # Combine the |image_name| and |symbol_path| into the path of the dSYM. # From the list of 2-Tuples of (frame, address), create a list of just # addresses. # Look up the load address of the image. # This returns a list of just symbols. The indices will match up with the # list of |addresses|. # Attaches a list of symbol names to stack frames. This assumes that the # order of |addresses| has stayed the same as |symbol_names|.
self
symbol_path