[LAD] a *simple* ring buffer, comments pls?

Dan Muresan danmbox at gmail.com
Fri Jul 8 23:03:34 UTC 2011


> Better to just follow the recommendations of the respective ABIs,
> and put in the memory barriers for those platforms that need them,
> like PortAudio, the linux kernel, and most other implementations

The apps already need to do some type of synchronization internally.
For example a player's disk thread, when its ringbuffer is full, needs
to wait for the process thread to consume some data and thus free up
some space.

So I think it would be better to drop the volatile's, and leave safety
to the app level. There's no point in duplicating synchronization at
the library and at the app level.


--  Dan



More information about the Linux-audio-dev mailing list