diff options
author | Ryan Prichard <rprichard@google.com> | 2019-08-16 17:25:43 -0700 |
---|---|---|
committer | Ryan Prichard <rprichard@google.com> | 2019-08-22 12:43:17 -0700 |
commit | a2e83ab34845759f0999d0ec88f4cdf558c0a9f5 (patch) | |
tree | 94c0adb62490e467936aae54b501c0fb577a122e /libc/malloc_hooks/tests/malloc_hooks_tests.cpp | |
parent | 3952113d90dd91adc67ce60899d4997bb5f63d0d (diff) |
Add additional dl_phdr_info fields
Previously, Bionic's dl_phdr_info only included the first four
dl_iterate_phdr fields. Several other libc's have these additional fields:
unsigned long long dlpi_adds -- incremented when a library is loaded
unsigned long long dlpi_subs -- incremented when a library is unloaded
size_t dlpi_tls_modid -- TLS module ID
void* dlpi_tls_data -- pointer to current thread's TLS block or NULL
These extra fields are also exposed by glibc, musl, and FreeBSD. The
unwinder in libgcc.a, linked into shipping Android DSOs, has a
PC->eh_frame cache that activates if dl_phdr_info has the dlpi_adds and
dlpi_subs fields (indicated at run-time by a sufficiently-large size
argument to the callback).
Bug: https://github.com/android-ndk/ndk/issues/1062
Test: bionic unit tests
Change-Id: I6f0bab548cf8c828af2ddab9eb01c5c6d70cd81f
Diffstat (limited to 'libc/malloc_hooks/tests/malloc_hooks_tests.cpp')
0 files changed, 0 insertions, 0 deletions