The basic thread cluster data structure is MPTHD, which holds the context of the thread. Look at the MPTHD's structure declaration now at the bottom of mpthd.h. You will notice MPTHD contains several fields. Most important are the state field, which stores the current processor state when the thread is not executing, and the heap/stack ``field'' (it's really after the structure), which holds the thread's stack (local variables and function calls) and possibly a heap of variables the thread allocates dynamically3. For beginning the thread, mpsigstate holds the signal blocked/unblocked state when the thread was initialized so that it may be restored when the thread is first started. For executing the thread, mpthdfn holds the thread function to be executed repeatedly. For switching between threads, oldmpthd holds the thread executed prior to this one. Finally, for safety, stackoverflow detects (becomes non-zero) when the context has become invalid due to stack overflow (when the stack has grown over the heap and probably overwritten the thread fields).
It is assumed that the macro mpthdme() is defined to be a dedicated register of a processor so the processor can tell which thread it's running (In single-processor machines, this can be a global variable.).