Due to enhancements in the dynamic linker, this interface is no longer
It is deprecated and will be removed from future releases.
In current releases it still exists, but only as a stub which does nothing.
Threads packages can call
at initialization time to register locking functions for the dynamic
linker to use.
This enables the dynamic linker to prevent multiple
threads from entering its critical sections simultaneously.
argument specifies an opaque context for creating locks.
dynamic linker will pass it to the
function when creating the locks it needs.
When the dynamic linker
is permanently finished using the locking functions (e.g., if the
program makes a subsequent call to
to register new locking functions) it will call
to destroy the context.
argument specifies a function for creating a read/write lock.
must return a pointer to the new lock.
arguments specify functions which lock a lock for reading or
argument specifies a function which unlocks a lock.
Each of these
functions is passed a pointer to the lock.
argument specifies a function to destroy a lock.
It may be
if locks do not need to be destroyed.
argument specifies a function to destroy the context.
It may be
if the context does not need to be destroyed.
is called, the dynamic linker protects its critical sections using
a default locking mechanism which works by blocking the
This is sufficient for many application level threads
packages, which typically use one of these signals to implement
An application which has registered its own locking
can restore the default locking by calling
with all arguments