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: [PATCH][BZ #19329] Fix race between tls allocation at thread creation and dlopen


On Wed, 2016-01-20 at 15:09 -0500, Carlos O'Donell wrote:
> Everything we do should be incremental. At each step though we
> might ask ourselves: How do we solve the more global problem
> of getting rid of the load lock?

IMO we should ask that.  A better question would probably be to ask why
we need the load lock; the lock is just a tool to implement some
intended high-level synchronization scheme.  We want to agree on this
scheme early on, otherwise it will be hard to judge correctness.

Note that it can be a perfectly fine approach to simply want to
implement the atomicity and ordering provided by some critical sections
differently -- but in this specific case, it sounds as if we'd like to
have a lock-less scheme anyway, and the current scheme doesn't work or
is not implemented correctly.  Both hint that we should go up in layers
of abstraction and revisit what we actually want.


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