Chapter 5: Thread synchronization and classic problems
This chapter explains why shared data creates race conditions and uses classic concurrency problems to build a practical model for deciding when synchronization is necessary.
Topics covered
- Shared data, non-atomic operations, and race conditions.
- Classic problems such as deadlock, livelock, and starvation.
- When to use
lock,Monitor, mutexes, semaphores, and other synchronization mechanisms.
This chapter is part of the full edition. The free preview edition does not include its full text.