Somehow I feel that the "mutex vs semaphore" distinction would have been nice to have from the start this way the question "why are semaphores still being used at all?" would never arise at all. I'd like to notice that one use of a semaphore as of a "fifo for token-like objects", that is, the one where the initial value is usually 0 and where one side initiating pushes causes another side to initiate the same amount of pops is not mentioned in this article at all, while e.g. for me it was always the primary use for semaphores (when I had dedicated mutex primitives for handling mutual exclusions, that is).
Copyright © 2018, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds