This article is from the Threads Programming FAQ, by Bryan O'Sullivan email@example.com with numerous contributions by others.
If you are interested in how modern operating systems support threads
and multiprocessors, there are a few excellent books available that
may be of interest to you.
Curt Schimmel, "Unix Systems for Modern Architectures".
Addison-Wesley, ISBN 0-201-63338-8.
This book gives a lucid account of the work needed to get Unix
(or, for that matter, more or less anything else) working on a
modern system that incorporates multiple processors, each with
its own cache. While it has some overlap with the Vahalia book
(see below), it has a smaller scope, and thus deals with shared
topics in more detail.
Uresh Vahalia, "Unix Internals: the New Frontiers". Prentice Hall,
This is the best kernel internals book currently available. It
deals extensively with building multithreaded kernels,
implementing LWPs, and scheduling on multiprocessors. Given a
choice, I would buy "both" this and the Schimmel book.
Ben Catanzaro, "Multiprocessor System Architectures". SunSoft Press,
I don't know much about this book, but it deals with both the
hardware and software (kernel and user) architectures used to
put together modern multiprocessor systems.