Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 11 Jan 2019 17:46:13 +0000
From:      bugzilla-noreply@freebsd.org
To:        threads@FreeBSD.org
Subject:   [Bug 234805] pthread_*_destroy doesn't handle locked objects consistently
Message-ID:  <bug-234805-13406-wJ0AxaEzGD@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-234805-13406@https.bugs.freebsd.org/bugzilla/>
References:  <bug-234805-13406@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D234805

--- Comment #3 from Konstantin Belousov <kib@FreeBSD.org> ---
(In reply to Mark Johnston from comment #2)
My thought when I answered was that you do want to lock umtx queue lock bef=
ore
looking into the queue.  If you are fine with the race described, so be it.

The difference between mtx/rw and cv there is that most often case of
destroying locked mutex and rwlock is when the thread that owns the lock
destroys it, which makes the check relatively sane.  For cv, thread which d=
oes
destroy cannot sleep obviously so the check is always racy.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-234805-13406-wJ0AxaEzGD>