[Bug libgomp/51249] semaphore implemetation for linux leaves threads blocked
amodra at gmail dot com
gcc-bugzilla@gcc.gnu.org
Mon Nov 21 22:36:00 GMT 2011
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51249
--- Comment #3 from Alan Modra <amodra at gmail dot com> 2011-11-21 22:21:13 UTC ---
Sorry, I misread the code. Indeed, the mutex will be left at 2.
I'm chasing a frustratingly elusive locking bug. Symptoms are that one or two
libgomp tests fail each gcc testsuite run, not always the same test. log shows
a timeout, but I'm fairly certain it isn't a real timeout but one of the
threads blocking. This used to happen before rth's recent locking changes.
The difficulty is that I can't seem to reproduce the failure when running tests
by hand.
I have a rewrite of sem.c,h which adds a "wait" field to the struct and uses
atomics, and have rewritten a number of other files to use atomics rather than
the old __sync functions. I just haven't been game to post my changes until I
track down the problem.
More information about the Gcc-bugs
mailing list