(defvar *interrupts-enabled* t)
(defvar *interrupt-pending* nil)
+#!+sb-thruption (defvar *thruption-pending* nil)
(defvar *allow-with-interrupts* t)
;;; This is to support signal handlers that want to return to the
;;; interrupted context without leaving anything extra on the stack. A
(lambda () (with-local-interrupts ...)))
"
(with-unique-names (outer-allow-with-interrupts without-interrupts-body)
- `(flet ((,without-interrupts-body ()
+ `(dx-flet ((,without-interrupts-body ()
(declare (disable-package-locks allow-with-interrupts
with-local-interrupts))
(macrolet
(setq *unblock-deferrables-on-enabling-interrupts-p*
nil)
(sb!unix::unblock-deferrable-signals))
- (when *interrupt-pending*
+ (when (or *interrupt-pending*
+ #!+sb-thruption *thruption-pending*)
(receive-pending-interrupt)))
(locally ,@with-forms))))
(let ((*interrupts-enabled* nil)
;; another WITHOUT-INTERRUPTS, the pending interrupt will be
;; handled immediately upon exit from said
;; WITHOUT-INTERRUPTS, so it is as if nothing has happened.
- (when *interrupt-pending*
+ (when (or *interrupt-pending*
+ #!+sb-thruption *thruption-pending*)
(receive-pending-interrupt)))
(,without-interrupts-body)))))
(when *unblock-deferrables-on-enabling-interrupts-p*
(setq *unblock-deferrables-on-enabling-interrupts-p* nil)
(sb!unix::unblock-deferrable-signals))
- (when *interrupt-pending*
+ (when (or *interrupt-pending*
+ #!+sb-thruption *thruption-pending*)
(receive-pending-interrupt)))
(locally ,@body))))
(defun %check-interrupts ()
;; Here we check for pending interrupts first, because reading a
;; special is faster then binding it!
- (when *interrupt-pending*
+ (when (or *interrupt-pending* #!+sb-thruption *thruption-pending*)
(let ((*interrupts-enabled* t))
(receive-pending-interrupt))))