[Ecls-list] CVS HEAD threads and signal handling
Juan Jose Garcia-Ripoll
juanjose.garciaripoll at googlemail.com
Sun Oct 18 15:58:03 UTC 2009
On Sun, Oct 18, 2009 at 3:24 PM, Matthew Mondor
<mm_lists at pulsar-zone.net> wrote:
> - Thread killing works nicely
> - I can no longer reproduce the earlier mp:with-lock problems I
> occasionally had despite a previous fix attempt at this
> - Division by zero errors are indeed now reported correctly
> - Also reported correctly are the segfaults for (symbol-function nil)
Great to read this!
> However, an issue I still see is an endless loop when ECL receives a
> SIGINT (SIGTERM works fine and causes ECL to terminate).
Could you elaborate this a little bit, please? Is this via Ctrl-C, or
via "kill -SIGINT whatever..." Under which conditions is the loop
entered? Multithreaded code? Already something running in the
background?
I have been pondering some mechanism to implement signal handlers in
Lisp. Right now SIGSEGV, SIGFPE and SIGBUS are reinterpreted as
conditions, SIGINT is the only one which does create new handling
threads. Maybe we could use a global variable to denote one of the
following behaviors:
- A thread designator, denoting the thread that wants to receive the
signal reinterpreted as condition.
- A function that does the job.
- NIL to simply ignore.
- T to use the default behavior and enter the debugger.
I see this is needed when the user is blocking input in a way such
that the debugger can not create a toplevel. Maybe this is what is
happening in your case, but it something we have to consider for the
future.
Juanjo
--
Instituto de Física Fundamental, CSIC
c/ Serrano, 113b, Madrid 28006 (Spain)
http://juanjose.garciaripoll.googlepages.com
More information about the ecl-devel
mailing list