Subj : Re: posix and lock-free algorithms To : comp.programming.threads From : David Schwartz Date : Thu Aug 04 2005 11:22 am "John Doug Reynolds" wrote in message news:1123158538.643009.66240@z14g2000cwz.googlegroups.com... > void memory_barrier() { mutex m; m.lock(); m.unlock(); } > > does not work for that purpose. According to David Schwartz, > > "In principle, that could be optimized by a sufficiently smart > implementation to nothing." I was wrong about that. According to POSIX, these functions fully synchronize memory. DS .