Pthreads documents are as follows:
What is a thread, why do we need it? -- Linux Process and thread overview;
What is pthreads? Why pthreads? -- Pthreads overview;
How to create and cancel a pthreads thread? -- POSIX thread creation and cancellation-pthreads thread library instance note 1;
How to connect and separate the pthreads thread? -- POSIX thread connection and separation-pthreads thread library instance Note 2;
What is mutex? How is the mutex of the pthreads library used? -- Use of POSIX thread mutex -- pthreads thread library instance Note 3;
What is a condition variable? How is the condition variable of the pthreads library used? -- Use of POSIX thread library condition variables -- pthreads thread library instance note 4;
References:
POSIX Threads programming: https://computing.llnl.gov/tutorials/pthreads /;
POSIX Thread Programming Guide (1): http://www.ibm.com/?works/cn/linux/thread/posix_threadapi/part1 /;
POSIX thread details: http://www.ibm.com/?works/cn/linux/thread/posix_thread1 /;