http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17886
--- Comment #25 from Andi Kleen <andi-gcc at firstfloor dot org> 2013-01-14 22:32:59 UTC --- Also i need to look more closely, but most likely the C++ atomic code should be changed to avoid this situation. This would give much better code on x86 in any case even without elision.