Subject: Re: Pthreads, libc, and the future
To: Bill Sommerfeld <>
From: Michael Graff <>
List: tech-userlevel
Date: 12/11/1999 09:36:37
Bill Sommerfeld <> writes:

> Perhaps _REENTRANT libc locking could be coded to a run-time
> replaceable interface, and ports of various threading packages to run
> with the reentrant libc could supply a vector of
> lock/unlock/... operations.  Not the most efficient, but it doesn't
> prematurely commit us to one particular threading package..

"static initializers"

Right now, libc uses a lot of them (if you turn on _REENT as well as
_REENTRANT when building it.)

I don't see how we can:

	Keep locks as actual objects, not pointers, so locking cannot
	fail due to low memory or other strange situations,, and

	do static initializers

without picking a threading package and deciding it is what we will

Remember, this is what will be put in lib/libpthread, so it isn't like
a totally foreign threading package from pkgsrc or the like is needed
to make libc build thread-safe.