This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/51798] [4.7 regression] libstdc++ atomicity performance regression due to __sync_fetch_and_add
- From: "dje at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 25 Jan 2012 15:14:29 +0000
- Subject: [Bug libstdc++/51798] [4.7 regression] libstdc++ atomicity performance regression due to __sync_fetch_and_add
- Auto-submitted: auto-generated
- References: <bug-51798-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51798
--- Comment #8 from David Edelsohn <dje at gcc dot gnu.org> 2012-01-25 15:14:29 UTC ---
> At least at this point I'd feel much safer if libstdc++ used just acq_rel
> semantics for the all atomic_fetch_and_add places, instead of somewhere acq and
> somewhere rel semantics.
Can we at least apply the ACQ_REL patch using the new atomic intrinsics?
Unfortunately, without my patch, libstdc++ users of atomicity.h (basic_string,
shared_ptr) do not distinguish between ACQUIRE and RELEASE, so POWER cannot
provide its own atomicity.h with the improved implementation.