Subj : Re: Can C++ local static objects be made thread safe? To : comp.programming.threads From : Casper H.S. Dik Date : Wed Feb 16 2005 10:39 am "David Schwartz" writes: >"Alexander Terekhov" wrote in message >news:42131205.B72DB5C2@web.de... >> David Schwartz wrote: >> [...] >>> Thread-local objects are not supposed to be shared. >> >> Sez who? > I am saying that. That is what makes them thread local. Ah, but you're now also claiming that a thread cannot give another thread access to a thread local variable? Surely you can construct a proof that __thread variables must be shared in a common address space? Or are you saying that you cannot assign __thread * variables to ordinary pointer variables? > In any event, many implementations have at least one page that is not >shared by all the threads. This is a common way to, for example, tell which >thread you are. But many do not (I'm blissfully unaware of most thread implementation so I only know for a fact that the Solaris implementation has no unshared bits) Casper -- Expressed in this posting are my opinions. They are in no way related to opinions held by my employer, Sun Microsystems. Statements on Sun products included here are not gospel and may be fiction rather than truth. .