Page MenuHomeFreeBSD

libc: Reassociate pointer arithmetic in __libc_tls_get_addr
ClosedPublic

Authored by jrtc27 on May 7 2025, 2:59 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Oct 18, 5:19 AM
Unknown Object (File)
Sat, Oct 17, 7:47 PM
Unknown Object (File)
Fri, Oct 16, 1:50 PM
Unknown Object (File)
Fri, Oct 16, 1:31 PM
Unknown Object (File)
Fri, Oct 16, 7:43 AM
Unknown Object (File)
Wed, Oct 14, 4:18 PM
Unknown Object (File)
Mon, Oct 12, 10:23 AM
Unknown Object (File)
Mon, Oct 12, 2:50 AM
Subscribers

Details

Summary

Rather than compute a biased pointer only to then un-bias it again, un-bias
the offset before adding it to the DTV entry.

This mirrors rtld-elf commit d71c97026366 ("rtld-elf: Push
TLS_DTV_OFFSET into tls_get_addr_common's arguments")

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 63975
Build 60859: arc lint + arc unit