1 Introduction
A concurrent program contains two or more threads that execute concurrently and work together to perform some task. Using multiple threads, a.k.a. multithreading, can increase computational efficiency. For instance, while one thread is waiting for user input, another thread can perform computational tasks in the background. In addition, many problem domains are, by nature, concurrent and can be solved more naturally by creating multiple threads. As an example, a Web server typically creates separate threads to service incoming client requests. Some languages, such as Java and Ada, provide built-in support for concurrent programming. The POSIX Pthreads library can be used to write concurrent programs in other languages such as C and C++.