HomeFreeBSD

rtld: implement _dl_iterate_phdr_locked

Description

rtld: implement _dl_iterate_phdr_locked

Some sanitizers need to be able to use dl_iterate_phdr() after stopping
the rest of the process, but it's very hard to do so reliably as a
non-participant in the main logic of the program.

Introduce _dl_iterate_phdr_locked to bypass the locking that's normally
required for dl_iterate_phdr() and slap some scary warning on it. It
will remain undocumented and probably shouldn't be used for anything
else.

Reviewed by: kib
Differential Revision: https://reviews.freebsd.org/D47558

Details

Provenance
kevansAuthored on Thu, Nov 14, 1:33 AM
Reviewer
kib
Differential Revision
D47558: rtld: implement _dl_iterate_phdr_locked
Parents
rG4b202f4faf40: libthr: allow very early atfork registration
Branches
Unknown
Tags
Unknown