0.9.2.9: thread objects
authorGabor Melis <mega@hotpop.com>
Fri, 1 Jul 2005 08:48:08 +0000 (08:48 +0000)
committerGabor Melis <mega@hotpop.com>
Fri, 1 Jul 2005 08:48:08 +0000 (08:48 +0000)
commit94ea2b2082deaa0331dfb66fa6af6ca12dd8dc83
tree402ad9ca69a43134db75f04b46d580c125988f5d
parenta6831e56ae6c27cab9b5efe157d087e261447d72
0.9.2.9: thread objects
  * Public interface changes
    ** proper thread objects instead of thread ids
    ** (MAKE-THREAD FN &KEY NAME) => THREAD
    ** (THREAD-NAME THREAD): threads have names (useful for debugging,
    logging)
    ** (THREAD-ALIVE-P THREAD)
    ** *CURRENT-THREAD* special is bound in each thread
    ** (LIST-ALL-THREADS) returns a list of all active threads
  * Notes
    ** thread-init moved earlier in cold-init and reinit
    ** the lisp side does not ever use os_thread_t (it was problematic due
       to pthread_t being opaque) but struct thread *
    ** threads are reaped (i.e. the thread is pthread_joined and struct
       thread* is freed) by the thread object's finalizer. This makes
       it easy to implement resetting threads. Running threads are kept
       in sb-thread::*all-threads*.
    ** threads block all blockable signals when going down:
       interrupt-thread and others cannot catch it at an inappropriate
       moment, for instance calling quit outside the catch %end-of-the-world
    ** target-thread.lisp renamed target-multithread.lisp,
       target-thread.lisp now contains the generic thread support
    ** new file early-thread.lisp: define *current-thread*
    ** removed thread state STOPPING that was only used for assertions and
       complicated matters
    ** renumbered thread states
    ** sb-thread::release-spinlock now releases the locks with
       non-fixnum value, but is no longer safe to call multiple times
    ** much simplified locking for threads and gc
    ** fixed deadlocking bugs introduced by the pthread merge
31 files changed:
NEWS
build-order.lisp-expr
contrib/sb-aclrepl/repl.lisp
doc/manual/threading.texinfo
package-data-list.lisp-expr
src/code/cold-init.lisp
src/code/debug.lisp
src/code/early-impl.lisp
src/code/early-thread.lisp [new file with mode: 0644]
src/code/exhaust.lisp
src/code/gc.lisp
src/code/target-multithread.lisp [new file with mode: 0644]
src/code/target-signal.lisp
src/code/target-thread.lisp
src/code/target-unithread.lisp
src/code/thread.lisp
src/compiler/generic/genesis.lisp
src/compiler/generic/objdef.lisp
src/compiler/x86-64/parms.lisp
src/compiler/x86/parms.lisp
src/pcl/low.lisp
src/runtime/gencgc.c
src/runtime/interrupt.c
src/runtime/thread.c
src/runtime/thread.h
src/runtime/validate.c
src/runtime/validate.h
src/runtime/x86-arch.h
src/runtime/x86-linux-os.c
tests/threads.impure.lisp
version.lisp-expr