This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] Add the __libc_single_threaded variable
- From: Florian Weimer <fweimer at redhat dot com>
- To: libc-alpha at sourceware dot org
- Date: Fri, 04 Oct 2019 11:59:02 +0200
- Subject: Re: [PATCH] Add the __libc_single_threaded variable
- References: <87blwpyo45.fsf@oldenburg2.str.redhat.com>
* Florian Weimer:
> This version is based on the earlier feedback that a simple global
> variable should be used instead
>
> <https://sourceware.org/ml/libc-alpha/2019-02/msg00073.html>
>
> and the benchmarking results suggesting that this is feasible:
>
> <https://sourceware.org/ml/libc-alpha/2019-06/msg00954.html>
>
> The implementation is somewhat complicated by copy relocations, which
> are not applied to the inner namespace.
>
> This is probably the simplest possible implementation. It does not
> attempt to reset the variable if there is only one thread left.
I'm going to post an implementation based on the early-init work for the
rseq addition. This way, we can keep the variable in libc.so instead of
the loader, which is somewhat cleaner conceptually.
Thanks,
Florian