Part 1. Foundations

 

How can we write instructions so that some actions are performed at the same time as others? In part 1 of this book, we’ll explore the basics of how we can model concurrency in our programming. We’ll see how modeling and executing concurrent programs require help from the hardware, the operating system, and the programming language.

When we develop concurrent programs, we encounter a ne w set of programming errors that are not present in sequential code. Known as race conditions, these errors can be some of the most difficult to identify and fix. A huge part of concurrent programming involves learning how to prevent these types of bugs in our code. In this part of the book, we’ll learn about race conditions and then discuss various techniques for avoiding them.