It should, but according to “speculative register promotion” and others “Out-Of-Thin-Air Stores” it seems not a compiler guarantee.
I do not want to frightened you ; i did a quick test on my macbook with agressive optimization and everything looks correct (assembly test joined) and my question is more to speculate (and i’m not an expert) that to solve issues…
…but i do not use ATOMIC anymore for this kind off synchronization as i consider mutex much more safe and i do not think speed matters for that as i do nothing RT like DSP callback.
My 2 cents.
Guru’s opinion ?
Jul 30, 2012 at 9:41am #229903