[Lldb-commits] [PATCH] D60001: Allow partial UUID matching in Minidump core file plug-in

Greg Clayton via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Fri Mar 29 11:03:49 PDT 2019


clayborg created this revision.
clayborg added reviewers: labath, zturner.
Herald added a subscriber: javed.absar.

Breakpad had bugs in earlier versions where it would take a 20 byte ELF build ID and put it into the minidump file as a 16 byte PDB70 UUID with an age of zero. This would make it impossible to do postmortem debugging with one of these older minidump files.

This fix allows partial matching of UUIDs. To do this we first try and match with the full UUID value, and then fall back to removing the original directory path from the module specification and we remove the UUID requirement, and then manually do the matching ourselves. This allows scripts to find symbols files using a symbol server, place them all in a directory, use the "setting set target.exec-search-paths" setting to specify the directory, and then load the core file. The Target::GetSharedModule() can then find the correct file without doing any other matching and load it.

Tests were added to cover a partial UUID match where the breakpad file has a 16 byte UUID and the actual file on disk has a 20 byte UUID, both where the first 16 bytes match, and don't match.


https://reviews.llvm.org/D60001

Files:
  packages/Python/lldbsuite/test/functionalities/postmortem/minidump-new/TestMiniDumpUUID.py
  packages/Python/lldbsuite/test/functionalities/postmortem/minidump-new/libuuidmatch.so
  packages/Python/lldbsuite/test/functionalities/postmortem/minidump-new/libuuidmismatch.so
  packages/Python/lldbsuite/test/functionalities/postmortem/minidump-new/linux-arm-partial-uuids-match.dmp
  packages/Python/lldbsuite/test/functionalities/postmortem/minidump-new/linux-arm-partial-uuids-mismatch.dmp
  source/Plugins/Process/minidump/ProcessMinidump.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D60001.192868.patch
Type: text/x-patch
Size: 7365 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20190329/a3f3eb32/attachment.bin>


More information about the lldb-commits mailing list