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

Paul Davis paul at linuxaudiosystems.com
Mon Jul 11 20:58:12 UTC 2011


On Mon, Jul 11, 2011 at 4:50 PM, Chris Cannam
<cannam at all-day-breakfast.com> wrote:
> On 11 July 2011 21:32, James Morris <jwm.art.net at gmail.com> wrote:
>> I've ended up going back to Fons's pragmatism. If
>> non-blocking/lock-free programming is so impossibly difficult,
>> requiring intimate hardware knowledge of numerous different
>> architectures then there's only one solution available to people like
>> me, and that's to code for AMD64/Intel and use the existing ringbuffer
>> implementations.
>
> Perhaps the pragmatic solution is to _lock_ the shared buffer?

no, the pragmatic solution is to use memory barriers liberally applied.



More information about the Linux-audio-dev mailing list