Very modern programmer should know something about parallel programming, and we Delphi programmers are no exception. The programs we write and maintain are getting more and more complex, while our customers expect them to keep performing swiftly and without blocking the user interface. A lot of times, we can only satisfy such requirements by introducing parallelism into our software.
Getting parallel, however, is far from simple. When we introduce multiple threads of execution into our programs, we also introduce a big source of potential problems. Writing good parallel code means writing very ordered code that follows established patterns—even more so than that in a standard, single-threaded application.
The most important concept of multithreaded programs is data sharing. After all, no thread is an island and we must somehow make sure that all code in...