(defun thread-state (thread)
(let ((state
- (sb!kernel:make-lisp-obj
- (sb!sys:sap-int
- (sb!sys:sap-ref-sap (thread-%sap thread)
- (* sb!vm::thread-state-slot
- sb!vm::n-word-bytes))))))
+ (sb!sys:sap-int
+ (sb!sys:sap-ref-sap (thread-%sap thread)
+ (* sb!vm::thread-state-slot
+ sb!vm::n-word-bytes)))))
(ecase state
- (0 :starting)
- (1 :running)
- (2 :suspended)
- (3 :dead))))
+ (#.(sb!vm:fixnumize 0) :starting)
+ (#.(sb!vm:fixnumize 1) :running)
+ (#.(sb!vm:fixnumize 2) :suspended)
+ (#.(sb!vm:fixnumize 3) :dead))))
(defun %set-thread-state (thread state)
(setf (sb!sys:sap-ref-sap (thread-%sap thread)
(* sb!vm::thread-state-slot
sb!vm::n-word-bytes))
(sb!sys:int-sap
- (sb!kernel:get-lisp-obj-address
- (ecase state
- (:starting 0)
- (:running 1)
- (:suspended 2)
- (:dead 3))))))
+ (ecase state
+ (:starting #.(sb!vm:fixnumize 0))
+ (:running #.(sb!vm:fixnumize 1))
+ (:suspended #.(sb!vm:fixnumize 2))
+ (:dead #.(sb!vm:fixnumize 3))))))
(defun thread-alive-p (thread)
(not (eq :dead (thread-state thread))))
extern struct interrupt_data * global_interrupt_data;
extern int linux_no_threads_p;
+#ifdef LISP_FEATURE_SB_THREAD
/* When trying to get all_threads_lock one should make sure that
* sig_stop_for_gc is not blocked. Else there would be a possible
* deadlock: gc locks it, other thread blocks signals, gc sends stop
release_spinlock(&all_threads_lock); \
thread_sigmask(SIG_SETMASK,&_oldset,0); \
}
+#endif
int
initial_thread_trampoline(struct thread *th)
;;; checkins which aren't released. (And occasionally for internal
;;; versions, especially for internal versions off the main CVS
;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".)
-"0.9.2.13"
+"0.9.2.14"