None of the command-line shells that I am aware of are multithreaded.  In particular, even those shells that support job control (Control-Z, bg, fg, etc) do so via facilities (namely, fork, exec, signals, pipes and PTYs) that predate Unix threads.Nor is Emacs multithreaded even though it is able to do many things at the same time.  (Again, it forks and execs external programs a lot and uses signals, pipes and PTYs to communicate with those external programs.)My question is, Does the dominant implementation of the X11 protocol (X.org) use Unix threads -- in either the server or any of the client libraries?If so, approximately when did it (or its ancestor, XFree86, or XFree86's ancestor) start doing so?
Is any part of the X.org software multithreaded?
x11;multithreading
$ ps -eLfUID        PID  PPID   LWP  C NLWP STIME TTY          TIME CMDroot         1     0     1  0    1 19:25 ?        00:00:00 init [4]...    root      1699     1  1699  0    1 19:25 ?        00:00:00 /usr/bin/kdmroot      1701  1699  1701  8    2 19:25 tty10    00:13:10 /usr/bin/X :1 vt10 ...root      1701  1699  1703  0    2 19:25 tty10    00:00:00 /usr/bin/X :1 vt10 ...root      1706  1699  1706  0    1 19:25 ?        00:00:00 -:1root      1707  1699  1707  0    2 19:25 tty9     00:00:02 /usr/bin/X :0 vt9 ...root      1707  1699  1710  0    2 19:25 tty9     00:00:00 /usr/bin/X :0 vt9 ...root      1713  1699  1713  0    1 19:25 ?        00:00:00 -:0....answers your question, I think.Nevertheless, the question seems to be mixing several things together - multithreading isn't about not using fork()/exec(). Threads share the same address space and if you want to run a different process you certainly don't want it to have access to the same address space. And if you decided not to use external programs (especially in the shell that since you mention it), you'd have to code all the functionality again.Multithreading isn't a cure for everything. It can mostly be a cure only for well parallelizable problems actually - check wiki page for a nice short overview. Making a program multithreaded doesn't make it better, in most cases it makes it worse due to the bugs in synchronization code (if present at all).