[PD-dev] threads

Dan Wilcox danomatika at gmail.com
Fri Apr 12 01:31:23 CEST 2024


> I work with PD when I want to make music more than I want to do advanced CS. And then there's the question of the marginal utility of PD having its own implementation of a ringbuffer, but I will leave that for all of you who have dedicated far more time than I to the maintenance of this project.


...please don't let that stop you. I want to dedicate more time to making music myself!

> To be more specific: the libpd ringbuffer uses atomic read-modify-write
> operations (with dummy arguments) instead of atomic loads and stores.
> Again, these are hacks from pre-C11 times. Unfortunately, the C11
> version follows this pattern instead of using the more appropriate
> atomic_load[_explicit] and atomic_store_[explicit] functions. Also, it
> implicitly uses the default memory ordering (memory_order_seq_cst) for
> all atomic operations, which is much stronger than what we actually need.

That's my fault. I did not have much time when I did that update, so I just found the equivalent functions without changing anything to be conservative. If you have suggestions for improvement, I am open to it. We can also ping Peter.

--------
Dan Wilcox
danomatika.com <http://danomatika.com/>
robotcowboy.com <http://robotcowboy.com/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-dev/attachments/20240412/eff220a1/attachment.htm>


More information about the Pd-dev mailing list