Counting Semaphores
Let S be a shared integer semaphore initialized to some value.
wait( S) : Delays process until count in S > 0. Then decrement S (subtract 1) and proceed.
signal( S) : Increment count in S and proceed. Side effect is to allow processes waiting on S to proceed.