This is the mail archive of the
gdb-testers@sourceware.org
mailing list for the GDB project.
[binutils-gdb] Add a helper function to resolve TLS variable addresses for FreeBSD.
- From: sergiodj+buildbot at sergiodj dot net
- To: gdb-testers at sourceware dot org
- Date: Tue, 12 Mar 2019 18:34:19 -0400
- Subject: [binutils-gdb] Add a helper function to resolve TLS variable addresses for FreeBSD.
*** TEST RESULTS FOR COMMIT 945f3901b5889e57edf5a2ee25acb51f0078a719 ***
Author: John Baldwin <jhb@FreeBSD.org>
Branch: master
Commit: 945f3901b5889e57edf5a2ee25acb51f0078a719
Add a helper function to resolve TLS variable addresses for FreeBSD.
The fbsd_get_thread_local_address function accepts the base address of
a thread's DTV array and the base address of an object file's link map
and uses this to compute a TLS variable's address. FreeBSD
architectures use an architecture-specific method to determine the
address of the DTV array pointer and call this helper function to
perform the rest of the address calculation.
* fbsd-tdep.c (fbsd_pspace_data_handle): New variable.
(struct fbsd_pspace_data): New type.
(get_fbsd_pspace_data, fbsd_pspace_data_cleanup)
(fbsd_read_integer_by_name, fbsd_fetch_rtld_offsets)
(fbsd_get_tls_index, fbsd_get_thread_local_address): New function.
(_initialize_fbsd_tdep): Initialize 'fbsd_pspace_data_handle'.
* fbsd-tdep.c (fbsd_get_thread_local_address): New prototype.