diff options
author | Rich Felker <dalias@aerifal.cx> | 2012-10-06 01:22:51 -0400 |
---|---|---|
committer | Rich Felker <dalias@aerifal.cx> | 2012-10-06 01:22:51 -0400 |
commit | cf3fd3d002c728ed0ef5d3aef856ff3e1d418da0 (patch) | |
tree | 9fe4aebad93aba1704dc82220aab22efaa5538e8 /src/env/__init_tls.c | |
parent | f4f77c068f1058d202a976678fce2617d59c0ff6 (diff) | |
download | musl-cf3fd3d002c728ed0ef5d3aef856ff3e1d418da0.tar.gz musl-cf3fd3d002c728ed0ef5d3aef856ff3e1d418da0.tar.xz musl-cf3fd3d002c728ed0ef5d3aef856ff3e1d418da0.zip |
TLS fixes, mainly alignment handling
compute offsets from the thread pointer statically when loading the library, rather than repeating the logic on each thread creation. not only is the latter less efficient at runtime; it also fails to provide solid guarantees that the offsets will remain the same when the initial alignment of memory is different. the new alignment handling is both more rigorous and simpler. the old code was also clobbering TLS bss with random image data in some cases due to using tls_size (size of TLS segment) instead of tls_len (length of the TLS data image).
Diffstat (limited to 'src/env/__init_tls.c')
0 files changed, 0 insertions, 0 deletions