Fix try-lock-thread-mutex to work when there is no current thread.
authorMatt Birkholz <puck@birchwood-abbey.net>
Sun, 31 Jan 2016 01:10:37 +0000 (18:10 -0700)
committerMatt Birkholz <puck@birchwood-abbey.net>
Wed, 3 Feb 2016 00:08:15 +0000 (17:08 -0700)
commiteb547ca67c6ab282ba805fbb7e19826d32f940a7
treef1b8b72e3929e046335c92708940a108ece15ec9
parent6af9d70324e289a57d8cf6fed19cb269d37c3c19
Fix try-lock-thread-mutex to work when there is no current thread.

GC daemons need to run when there is no current thread.  Try-lock-
thread-mutex was intended for their use.  They do not mind
occasionally skipping an opportunity to clean, including the rare
times when a GC interrupt occurs with no current thread -- in the
thread system of a quiescent world.

Try-lock-thread-mutex was signaling spurious deadlocks when GC daemons
ran with no current thread.  Free locks appeared to be owned by #F --
the current thread.
src/runtime/thread.scm