cvs commit: src/lib/libpthread/thread thr_mutex.c

Dag-Erling Smørgrav des at des.no
Mon Nov 1 14:24:24 PST 2004


Daniel Eischen <deischen at freebsd.org> writes:
> We use error check mutexes by default, which is allowed by the
> spec, because they come at no cost [...]

They come at considerable cost.  They make it impossible to use the
Boehm garbage collector in threaded programs, for instance, because
pthread_mutex_init() calls malloc() which tries to use a mutex.  There
is probably a significant performance penalty as well.

DES
-- 
Dag-Erling Smørgrav - des at des.no


More information about the cvs-all mailing list