std::string & multithreading
Radu Marginean
radu_marg@yahoo.com
Fri Feb 26 11:16:00 GMT 2010
Hi,
Currently std::string cannot be safely used in a multithreaded environment due to features like copy on write and reference counting. Even programs that access two unrelated different string objects in a multicore machine may suffer random crashes.
Rogue Wave for example has a compiler option which allows linking with a version of the STL library that can be safely used in a multithreaded application. Is there any such option available for gcc? If not are there plans to introduce one?
Thank you,
Radu
More information about the Libstdc++
mailing list