http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54172
--- Comment #12 from Benjamin Kosnik <bkoz at gcc dot gnu.org> 2012-09-06 20:31:13 UTC --- Author: bkoz Date: Thu Sep 6 20:31:08 2012 New Revision: 191042 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=191042 Log: 2012-09-06 Thiago Macieira <thiago.macie...@intel.com> PR libstdc++/54172 * libsupc++/guard.cc (__cxa_guard_acquire): Exit the loop earlier if we detect that another thread has had success. Don't compare_exchange from a finished state back to a waiting state. Comment. Modified: trunk/libstdc++-v3/ChangeLog trunk/libstdc++-v3/libsupc++/guard.cc