This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/13684] local static object variable constructed once but ctors and dtors called multiple times on same memory when called in multiple threads
- From: "adah at netstd dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 5 Sep 2004 03:19:31 -0000
- Subject: [Bug c++/13684] local static object variable constructed once but ctors and dtors called multiple times on same memory when called in multiple threads
- References: <20040114172507.13684.evijaykumar@yahoo.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From adah at netstd dot com 2004-09-05 03:19 -------
I myself have had headaches about this problem (unsafe DLCP) too. Indeed, I do
not have problems with DLCP, since I have access only to IA-32 platforms, but I
really like to make my code more portable.
Currently there is no known way to make memory barriers portable. So I guess
it might be a good idea that GCC provide built-in functions to do the job. On
IA-32 platforms it is a just a null operation, but on other systems it might
really do significant stuff.
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |adah at netstd dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13684