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: Async-signal-safe access to __thread variables from dlopen()ed libraries?


On Tue, Sep 24, 2013 at 02:40:13PM -0700, Andrew Hunter wrote:
> FYI, on my recent-ish Intel system, a mask/unmask pair is under 350
> nanoseconds.  The block times aren't likely to be much longer; the
> most expensive thing done there is (at most) two small mmaps (if we
> don't override with a better malloc.)  mmap'ing a page and populating
> it costs <2 microseconds on my system.  I would be very surprised,
> other than in very large TLS arrays or very strange circumstances, if
> tls_get_addr() took more than a millisecond on CPU.

I would be surprised if it ever took more than 5 microseconds. For
what it's worth, millisecond latency is serious and could be
considered a problem for many realtime uses. Microsecond, not so much.

Rich


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