This is an archive of the discontinued LLVM Phabricator instance.

Add support for ARM and ARM64 breakpad generated minidump files (version 2).
ClosedPublic

Authored by clayborg on Aug 6 2018, 8:13 AM.

Details

Summary

In this patch I add support for ARM and ARM64 break pad files. There are two flavors of ARM: Apple where FP is R7, and non Apple where FP is R11. Added minimal tests that load up ARM64 and the two flavors or ARM core files with a single thread and known register values in each register. Each register is checked for the exact value.

This is a fixed version of: https://reviews.llvm.org/D49750

The changes from D49750 are:

  • Don't init the m_arch in the Initialize call as a system info isn't required. This keeps the thread list, module list and other tests from failing
  • Added -Wextended-offsetof to Xcode project so we catch use extended usages of offsetof before submission
  • Fixed any extended offset of warnings

Diff Detail

Repository
rL LLVM

Event Timeline

clayborg created this revision.Aug 6 2018, 8:13 AM

Did you see my comments on the first round about how the CMake build didn’t
work? Because I don’t see any changes to CMakeLists.txt here, which means
it still won’t work.

The easiest way to make sure you get all the fixes that may have gone in
after your initial commit is to revert the revert and build your
modifications on top of that. Then, for example, the fixes to
CMakeLists.txt would already be here.

labath accepted this revision.Aug 6 2018, 8:22 AM

This should be fine once the cmake thing is addressed.

This revision is now accepted and ready to land.Aug 6 2018, 8:22 AM
clayborg updated this revision to Diff 159324.Aug 6 2018, 9:54 AM

Added CMakeList.txt changes, tested on linux, and removed unused "log" variable.

This revision was automatically updated to reflect the committed changes.
This revision was automatically updated to reflect the committed changes.

Fixed offsetof issues with:

$ svn commit
Sending source/Plugins/Process/minidump/RegisterContextMinidump_ARM.cpp
Sending source/Plugins/Process/minidump/RegisterContextMinidump_ARM64.cpp
Transmitting file data ..done
Committing transaction...
Committed revision 339033.

Passing patches between linux and mac the offsetof fixes got lost. When binary files are involved, patches are trickier to pass between to machines.

More offsetof issues:

$ svn commit
Sending source/Plugins/Process/minidump/RegisterContextMinidump_ARM.cpp
Transmitting file data .done
Committing transaction...
Committed revision 339034.