This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [BZ#17090/17620/17621]: fix DTV race, assert, and DTV_SURPLUS Static TLS limit


On 17/03/15 04:34, Alexandre Oliva wrote:
> On Mar 16, 2015, Richard Henderson <rth@twiddle.net> wrote:
>> The patch looks good to me.  (And success with aarch64-linux-gnu!)
> 
> Thanks.  Here's what I've just pushed to master, after adjusting the
> patch for changed context in NEWS and nptl_db/td_symbol_list.c.
> 
> 
> Fix DTV race, assert, DTV_SURPLUS Static TLS limit, and nptl_db garbage
> 

this is still not a complete fix
i can see races on aarch64 and x86_64 with the same test

i described what i think the problem is on

https://sourceware.org/bugzilla/show_bug.cgi?id=17918

i think the _rtld* members that are accessed without holding
the rtld lock should only be accessed using atomics (at least
_dl_tls_generation and _dl_tls_max_dtv_idx are affected)

and may be they should be volatile too to tell the compiler
not to add spurious load/store to these accesses (since
glibc does not use c11 atomics yet)



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]