This introduces the low-level system threading support. It also adds
commit14b3dc5e4f2cdefde1ba04ddd3525115e7ca7dce
authorTom Tromey <tromey@redhat.com>
Wed, 15 Aug 2012 19:03:17 +0000 (15 13:03 -0600)
committerTom Tromey <tromey@redhat.com>
Wed, 15 Aug 2012 19:03:17 +0000 (15 13:03 -0600)
treeaf04882e838fea858d9672dac6c19eab374505b9
parent2d525b793f1b0fd2b6f66881310bec8684bceffe
This introduces the low-level system threading support.  It also adds
the global lock.  The low-level support is a bit over-eager, in that
even at the end of the present series, it will not all be used.  I
think thiat is ok since I plan to use it all eventually -- in
particular for the emacs lisp mutex implementation.

I've only implemented the pthreads-based version.  I think it should
be relatively clear how to port this to other systems, though.

I'd also like to do a "no threads" port that will turn most things
into no-ops, and have thread-creation fail.  I was thinking perhaps
I'd make a future (provide 'threads) conditional on threads actually
working.

One other minor enhancement available here is to make it possible to
set the name of the new thread at the OS layer.  That way gdb, e.g.,
could display thread names.
src/Makefile.in
src/emacs.c
src/lisp.h
src/systhread.c [new file with mode: 0644]
src/systhread.h [new file with mode: 0644]
src/thread.c
src/thread.h