On Fri, Jul 8, 2011 at 8:49 PM, Paul Davis <paul(a)linuxaudiosystems.com> wrote:
could be true enough, but i will be happy to fake
ignorance and say i
don't know for sure. but ...
I sure as heck don't know for sure :-)
the whole point single reader/single writer lock-free
FIFOs is that
*synchronization doesn't matter*.
At least on x86, where Intel was very careful to preserve the illusion
of coherence, it works... usually?
http://en.wikipedia.org/wiki/Non-blocking_algorithm seems to agree with you,
but
http://www.rossbencina.com/code/lockfree seems to agree with you
only on a uniprocessor system.
http://www.codeproject.com/KB/threads/LockFree.aspx has lots of interesting
links. In particular, it links to a couple articles by Herb Sutter,
http://drdobbs.com/cpp/210600279
http://drdobbs.com/high-performance-computing/211601363
He makes it sound like it's only possible using compare-and-swap
atomic primitives.
- Dan