[Ardour-Dev] Hello, some tech talk, etc.

Paul Davis paul at linuxaudiosystems.com
Tue Jul 3 10:55:31 PDT 2012

On Tue, Jul 3, 2012 at 8:42 PM, Razvan Cojocaru <razvanco at gmx.net> wrote:

> > 1) recursive mutexes are not acceptable. google around for decades-old
> > criticisms and the story of how they came to be part of pthreads.
> Yes, I am quite aware of that, thank you.
> My point is that _if_ there's a deadlock issue (which does produce
> undefined behaviour), there are two choices: A) switch to recursive
> mutexes and be done with it (small performance hit, the other caveats,
> and all)

we tried this. it was a disaster. not all pthreads implementations are
created equal. not all Glib wrappers of pthreads are created equal.

> , or B) try to guess how GTK+ behaves now and will behave in the
> future and be purists about it.

there is never a good reason to use a recursive mutex except for lack of
time or willingness to correctly understand the threading design. never.
not in ardour, not anywhere else. its a band aid that can very very easily
lead to much worse problems further down the road. this is the perspective
even of the guy who first implemented them (mostly as a joke).

one of the virtues of an open source project is that we don't have our
engineering standards decided by marketing geeks. if a problem appears to
be solvable with a recursive mutex, then the real message is that more time
needs to be spent coming with the real solution. pragmatic? maybe not in
the short term, but definitely in the long term.

>  I did, and can always reproduce the one about zooming into
> a new, empty tape track.

they are not necessarily the same (clearly ::)

> You see, this is what I was asking about on IRC: having some sort of
> system for requesting to work on a bug would have helped me not to go
> digging where those more knowledgeable of the project have spent time
> and decided it's not something to dig into (at least for the moment).

you've just discovered it :) IRC works too, most of the time.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ardour.org/pipermail/ardour-dev-ardour.org/attachments/20120703/8aaf362d/attachment-0002.htm>

More information about the Ardour-Dev mailing list