X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fruntime%2Finterrupt.h;h=ff649ce11fa204093310393c52ad908bd90e95e6;hb=91e1d65670542ceb7c177423f25b53d250c9d9cb;hp=d26df2855c43510310922a23ad449ccbfd5eba8d;hpb=584bfdc4e1093e43e4eb328a418b012745935a29;p=sbcl.git diff --git a/src/runtime/interrupt.h b/src/runtime/interrupt.h index d26df28..ff649ce 100644 --- a/src/runtime/interrupt.h +++ b/src/runtime/interrupt.h @@ -38,12 +38,30 @@ sigcopyset(sigset_t *new, sigset_t *old) /* maximum signal nesting depth * - * Note: In CMU CL, this was 4096, but there was no explanation given, - * and it's hard to see why we'd need that many nested interrupts, so - * I've scaled it back (to 256) to see what happens. -- WHN 20000730 - - * Nothing happened, so let's creep it back a bit further -- dan 20030411 */ -#define MAX_INTERRUPTS 32 + * FIXME: In CMUCL this was 4096, and it was first scaled down to 256 + * and then 32, until finally Stumpwm broke: it is possible to receive + * interrupts in sufficiently quick succession that handler nesting + * can become preposterous. Scaling this back up to 1024 is a bandaid: + * for a real fix we should consider the following things: + * + * We should almost certainly always use + * arrange_return_to_lisp_function, though it needs to be thought + * about arguments, and it needs to be able to pass a frobbable + * context to the callee... + * + * There are cases when nesting handlers is exactly what we want: + * eg. SIGINT. + * + * There are cases when we probably want to drop duplicate signals + * on the floor if they arrive before the previous one has been handled. + * Eg. SIGPROF. + * + * There are cases when we probably want to handle duplicate signals + * after the previous handler has returned, not before. Eg. SIGALARM. + * + * -- NS 2007-01-29 + */ +#define MAX_INTERRUPTS 1024 union interrupt_handler { lispobj lisp;