[PD-dev] threads

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


It's the implementation used by libpd for passing messages between the audio thread to the various hooks. It is also used in the libpd Obj-C PdAudioUnit for buffering samples sample rate conversion is happening and the buffer size is inconsistent. If it was broken in some way, we would have heard about it over the last 10+ years or so. I trust the guy who wrote it (Peter Brinkmann) but it is admittedly older code now and I only updated to C atomics in a cursory manner via the macros. If y'all have thoughts/suggestions on improvement, please open an issue (or better a PR) on the libpd Github repo.

> On Apr 11, 2024, at 12:00 PM, pd-dev-request at lists.iem.at wrote:
> 
> As an aside: is the code in z_ringbuffer.{c,h} considered trustworthy? I
> note that the other code in PD appears to use the sys_ringbuffer* API,
> which seems to be built on the PA ringbuffer. I ask because I had some
> problems with z_ringbuffer.c and after a code read, there are some bits
> which look sketchy enough to me that I decided to stop using it.

--------
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/6d3a3df7/attachment.htm>


More information about the Pd-dev mailing list