The Little Book of SEMAPHORES (2nd Edition): The Ins and Outs of Concurrency Control and Common Mistakes

Category: Computer Science
Author: Allen B. Downey


by anonymous   2018-05-21
You can use a `Semaphore` as a substitute for a `Lock`, but that doesn't mean that a semaphore is a kind of lock. Semaphores are abstract objects that you can use in [a variety of different ways]( to coordinate the activities of two or more different threads. In some useful semaphore-based patterns, the semaphore permits will be released in one thread and acquired in another.