This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libstdc++/24704] __gnu_cxx::__exchange_and_add is called even for single threaded applications



------- Comment #11 from pcarlini at suse dot de  2005-11-08 10:53 -------
(In reply to comment #10)
> An easy solution might be to check for __gthread_active_p() in
> bits/basic_string before calling __exchange_and_add, and to do this locally and
> non-atomically otherwise.

Yes, this solution can work. Actually, I'm hoping for something a bit cleaner.
Remember that we want a single clean solution for *all* the places where the
atomics are used and most are inside the built *.so.


-- 

pcarlini at suse dot de changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.0.3                       |4.2.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24704


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]