These APIs allow programmers to create, terminate, and synchronize threads within a process. The threads library may also contain a scheduler for user threads. Thus, if an application is running on an operating system that supports kernel threads, each thread within the process may run on a different processor because the kernel is capable of scheduling them individually. Kernel threads are created by the threads library using thread system calls. These system calls allow the threads library to create, terminate, and synchronize kernel threads.
Kernel threads are visible to the kernel as well as to the threads library.
The kernel schedules and manages these for its own needs and on behalf of user threads in need of kernel services. There are two forms of kernel threads, and thus two definitions. In the 131 model, there is one kernel thread for every user thread on the system. In this model, threads, not processes, are the schedulable entities, and each thread within a process may be scheduled on a different processor. The M3N model supports one kernel thread for every user thread, multiple user threads multiplexed on top of a single kernel thread, or any number of combinations.