cvs commit: src/include pthread_np.h src/lib/libthr pthread.map
ad at netbsd.org
Thu Feb 7 12:19:09 PST 2008
> Add pthread_mutex_islocked_np(), a cheap way to verify that a mutex is
> locked. This is intended primarily to support the userland equivalent
> of the various *_ASSERT_LOCKED() macros we have in the kernel.
For what it's worth, NetBSD has the below. I found the names in FreeBSD
perforce using Google and used them in the hope of being compatible. :-)
I didn't find equivalents in other systems when I looked.
int pthread_mutex_held_np(pthread_mutex_t *);
int pthread_rwlock_held_np(pthread_rwlock_t *);
int pthread_rwlock_wrheld_np(pthread_rwlock_t *);
int pthread_rwlock_rdheld_np(pthread_rwlock_t *);
More information about the freebsd-threads