Skip to content
  • Joshua Peraza's avatar
    Added classes to support reading unloaded module lists in minidumps. · c2d969cb
    Joshua Peraza authored
    The implementations of Module/UnloadedModule and
    ModuleList/UnloadedModuleList are very similar. They have been made
    separate classes because they operate on different structs, complicating
    factoring code into a base class and have sufficiently different
    implementation that templates would not be suitable.
    
    When unloaded modules have partially overlapping ranges, the module
    shrink down feature is used to move the start of the higher range to the
    end of the lower range. If two unloaded modules overlap identically, the
    second module will not be added to the range map and the failure
    ignored.
    
    Places where MinidumpUnloadedModule differs from MinidumpModule:
      code_identifier: the android/linux case is deleted since cv_records
        never exist.
      debug_file/debug_identifier/version: always return empty strings.
      Read: an expected size is provided as opposed to MD_MODULE_SIZE. A
        seek is used if there are extra, unused bytes.
    
    Places where MinidumpUnloadedModuleList differs from
      MinidumpModuleList:
      Read: entry and header size is provided in the header in
        addition to count. This changes the checks and handling of padding.
        Failures from StoreRange are ignored.
      GetMainModule: always returns NULL.
    
    BUG=
    
    Change-Id: I52e93d3ccc38483f50a6418fede8b506ec879aaa
    Reviewed-on: https://chromium-review.googlesource.com/421566
    
    
    Reviewed-by: default avatarJoshua Peraza <jperaza@chromium.org>
    c2d969cb