This is the mail archive of the
mailing list for the pthreas-win32 project.
Re: Still having deadlock problems ?
- From: Ross Johnson <rpj at ise dot canberra dot edu dot au>
- To: Pietrobon Marcello <teiffel at attglobal dot net>
- Cc: Pthreads Developers List <pthreads-win32 at sourceware dot cygnus dot com>
- Date: Fri, 15 Feb 2002 19:00:15 +1100
- Subject: Re: Still having deadlock problems ?
- Organization: University of Canberra, Information Sciences and Engineering
- References: <Pine.LNX.firstname.lastname@example.org> <3C6CA5A2.F2F6FA87@attglobal.net>
Pietrobon Marcello wrote:
> At the end of the page http://sources.redhat.com/pthreads-win32/
> there is a link to an important article of Johnson M. Hart with title
> "Experiments with the Open Source Pthreads Library and Some Comments"
> In the middle of that article he talks really well about Open Source POSIX
> Threads for Win32, but he also says:
> "Furthermore, the Open Source code contains at least one comment about a
> possible deadlock; this comment is not very reassuring."
> What is talking about. Is still that problem existing ?
I think he's refering to a comment in mutex.c in the function
* The mutex isn't held by another thread but we could still
* be too late invalidating the mutex below since another
* may already have entered mutex_lock and the check for a
* *mutex != NULL.
NULL is used to indicate an invalid mutex. It still exists,
probably because to fix it would slow mutexes down with
This is the only known race condition in the code, and many
keen eyes have looked through it. If there were others
they would have been commented too.
> It is very important to me to be able to trust completely Pthread-Win32, so
> I cannot use it if I don't know when this problem appears.
To the extent that you can trust any library completely, you
can trust pthreads-win32 to do an excellent job.
Having said that, please check the Conformance section
of the ANNOUNCE file before you make your final decision.
If you decide to use it, there will be a new snapshot
out soon with a few bug fixes and enhancements. You can
grab the very latest development sources from the CVS
repository by following the instructions on the
pthreads-win32 web page.