This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: libpthread removal project
On 07/10/19 1:27 pm, Florian Weimer wrote:
> This is what __libc_single_threaded is about. It's a variable, not a
> function, to avoid the function call overhead.
Variable is fine too, but I suggest we publish it as a supported API and
not an internal __libc_* detail.
> As far as thread counts go, only the value 1 is special. A general
> thread count does not seem useful to me because it's not stable (for any
> value above 1), and libraries do not know what the count means. For
> example, half of the threads could be parked on some rarely-occurring
> condition, so for pretty much all practical purposes, they do not count.
I'm thinking more about user applications and not just libraries; ideas
like scaling/throttling of thread counts.
Siddhesh