Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

4
  • "Mutexes take a relatively large amount of RAM to implement on my system." -- really? How much? For how many signals? Commented Oct 7, 2021 at 21:52
  • Look at volatile, compare & swap, spinlock, atomics. You'll find something that will help you manage concurrently shared data structures without mutexs, especially if you are willing to put some limits on their operations. Commented Oct 7, 2021 at 22:16
  • I understand the need to lock when adding or removing. Why do you think a lock is needed when emitting? Commented Oct 7, 2021 at 22:42
  • There's likely no reason to invoke observers that installed as a result triggering, they're probably waiting for the next trigger, so just need to be able to differentiate between observers that should be run in response to this trigger, and which ones are added new. That can be done a number of ways (and depending on whether the observers are meant to be kept or released on triggering). Commented Oct 8, 2021 at 0:05