July 2015
Intermediate to advanced
558 pages
13h 31m
English
All threads in a process have access to the same global memory, so the results of computations performed in one thread are relatively easy to share with other threads. Concurrent read-only operations on shared memory do not require any coordination, but any write to shared memory requires synchronization with any read or write. Threads that share mutable data and other resources need mechanisms to arbitrate access to shared data and signal each other about events and state changes. In this section, we explore the mechanisms for coordination between multiple threads.
Consider a program that generates the difference between two text files à la the Unix diff utility. You need to read two ...
Read now
Unlock full access