mit-scheme-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MIT-Scheme-devel] non-recursive mutexes


From: Arthur A. Gleckler
Subject: Re: [MIT-Scheme-devel] non-recursive mutexes
Date: Mon, 8 Jun 2015 22:02:59 -0700

On Monday, June 8, 2015, Taylor R Campbell <address@hidden> wrote:
 
   Saying "don't rely on it, it's not documented" in reference to an
   essential service is basically saying "our system is an unfinished
   toy, we're sorry you decided to use it".

That is basically true of the thread system at least.

Yes, that's fair.
 
I've reverted the change, and added a WITH-THREAD-MUTEX-LOCK that is
just a dynamic-wind of LOCK-THREAD-MUTEX/UNLOCK-THREAD-MUTEX, which
already rejected recursion.

(The revert could conceivably be cherry-picked into the release-9.2
branch for a 9.2.1 release.)

Thanks.

I'm actually running tip-of-tree, so this is just fine for me.
 
I still strongly advise designing your locks to avoid recursion: in
almost all cases it will make reasoning about and understanding your
program easier; in the few cases that remain you probably need other
semantics anyway.

I still intend to look over the code to see what I can do cleanly. 

reply via email to

[Prev in Thread] Current Thread [Next in Thread]