-
Thread-safe singleton.
Hello, I'm currently trying to do some time multi-threaded cross-platform application with multiple cores. I need to use some high performance singletons but I haven't been able to find a good thread-safe singleton. Many people suggest using a double-checked locking singleton but I have found a paper http://www.aristeia.com/Papers/DDJ_J...04_revised.pdf which shows why that solution isn't reliable. Is there any high performance thread-safe singleton I can use or am I better just storing the pointer returned by singleton in each thread?
Thanks.
-
I remember this article mentioning something thready, but it might not be of any use, just thought I'd throw it at you while I've got a second :)
http://gethelp.devx.com/techtips/cpp.../10min0200.asp
-
That solution isn't thread-safe, thanks anyway.
-
consider loki
more better libraries remain private
Kuphryn