Add dyndebug flags backtrace_when_lost, sleep_when_lost
authorDavid Lichteblau <david@lichteblau.com>
Tue, 11 Sep 2012 11:37:21 +0000 (13:37 +0200)
committerDavid Lichteblau <david@lichteblau.com>
Tue, 11 Sep 2012 12:42:51 +0000 (14:42 +0200)
commit5cfc11977fc09cfb6a95f3d9d485deb147b8f7d3
tree76b4c709a3c4322906a768db7e4379edd6f46fe6
parentebb604b4422ba886e70ce2e531c1f4d28d44e721
Add dyndebug flags backtrace_when_lost, sleep_when_lost

Available when :SB-QSHOW is enabled, these settings can be enabled
through the SBCL_DYNDEBUG environment variable to customize SBCL's
behaviour prior to entry to ldb.

With backtrace_when_lost, lossage shows a backtrace before
continuing with the lossage handler as usual.  (Thanks to Dmitry
Kalyanov for this idea, here committed as a dyndebug option.)

With sleep_when_lost activated, the monitor is preempted, and SBCL
will instead cease to do anything except for a OS-level sleep call.
This behaviour has proven useful in preserving a failing thread's
current state until an external debugger can be attached.
src/runtime/interr.c
src/runtime/print.c
src/runtime/runtime.h