platform_system_core/libunwindstack/include/unwindstack
Christopher Ferris 01040b10b2 Fix handling of ro segments for embedded libs.
When a shared library is loaded directly from an apk, the new way the
linker splits a shared library into a read-only and execute segment
broke unwinding. Modify the code to handle this case.

Other changes:
- Modify the algorithm for finding read-only map entries. Before, the code
  would search the entire map for the closest offset. Now it simply looks
  at the previous map. I did this because the old code was too lenient and
  might still work even if the linker changes. I want this to break if the
  linker behavior changes so that I can analyze the change.
- Update the tools to use PTRACE_SEIZE instead of PTRACE_ATTACH since
  PTRACE_ATTACH doesn't work in all cases.
- Small refactor of the GetFileMemory function.
- Add new unit test cases and new offline unwind test cases.

Bug: 120618231

Test: Ran new unit tests, ran original failing test.
Change-Id: I4bade55cf33220d52f1d5e9b0cbbbcc8419669d4
2018-12-11 19:16:29 -08:00
..
DexFiles.h Verify that the elf matches the expected arch. 2018-10-29 18:08:09 -07:00
DwarfError.h Add error propagation into Unwinder/Elf objects. 2018-01-24 17:50:46 -08:00
DwarfLocation.h Cache DWARF location rules for a given pc. 2018-03-29 14:47:13 +00:00
DwarfMemory.h Make the library usable as a library. 2017-07-14 12:20:23 -07:00
DwarfSection.h Refactor the DwarfSection classes. 2018-06-27 14:52:21 -07:00
DwarfStructs.h Make the library usable as a library. 2017-07-14 12:20:23 -07:00
Elf.h Read .note.gnu.build-id. 2018-12-05 14:13:30 +00:00
ElfInterface.h Read .note.gnu.build-id. 2018-12-05 14:13:30 +00:00
Error.h Add error propagation into Unwinder/Elf objects. 2018-01-24 17:50:46 -08:00
Global.h Verify that the elf matches the expected arch. 2018-10-29 18:08:09 -07:00
JitDebug.h Verify that the elf matches the expected arch. 2018-10-29 18:08:09 -07:00
LocalUnwinder.h Add a specialized LocalUnwinder object. 2018-05-23 20:02:30 -07:00
Log.h Make the library usable as a library. 2017-07-14 12:20:23 -07:00
MachineArm.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
MachineArm64.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
MachineMips.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
MachineMips64.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
MachineX86.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
MachineX86_64.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
MapInfo.h Fix handling of ro segments for embedded libs. 2018-12-11 19:16:29 -08:00
Maps.h Add a specialized LocalUnwinder object. 2018-05-23 20:02:30 -07:00
Memory.h Add support for caching small reads. 2018-11-28 13:04:58 -08:00
Regs.h libunwindstack: add Regs::Clone. 2018-04-20 13:23:20 -07:00
RegsArm.h libunwindstack: add Regs::Clone. 2018-04-20 13:23:20 -07:00
RegsArm64.h libunwindstack: add Regs::Clone. 2018-04-20 13:23:20 -07:00
RegsGetLocal.h Allow to get raw register data on all platforms. 2018-08-08 11:19:41 +01:00
RegsMips.h libunwindstack: add Regs::Clone. 2018-04-20 13:23:20 -07:00
RegsMips64.h libunwindstack: add Regs::Clone. 2018-04-20 13:23:20 -07:00
RegsX86.h libunwindstack: add Regs::Clone. 2018-04-20 13:23:20 -07:00
RegsX86_64.h libunwindstack: add Regs::Clone. 2018-04-20 13:23:20 -07:00
UcontextArm.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
UcontextArm64.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
UcontextMips.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
UcontextMips64.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
UcontextX86.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
UcontextX86_64.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
Unwinder.h Change the GetAdjustedRelPc to GetPcAdjustment. 2018-02-21 20:16:39 -08:00
UserArm.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
UserArm64.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
UserMips.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
UserMips64.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
UserX86.h Expose per arch headers. 2018-02-08 19:29:08 -08:00
UserX86_64.h Expose per arch headers. 2018-02-08 19:29:08 -08:00