Subj : Re: A question about atomic_ptr To : comp.programming.threads From : Alexander Terekhov Date : Thu Apr 14 2005 07:54 pm Alexander Terekhov wrote: > > Chris Thomasson wrote: > > > > > Does it try to access (via stwcx) reclaimed memory or not? > > > > http://groups.google.ca/groups?hl=en&lr=&selm=7I0Ea.854894%24OV.808546%40rwcrnsc54 > > Grr. CAS64 aside for a moment, Joe says (in that "refcount in object" It can go boom on LL/LR step too. > thread) "... decrement refcount to zero, and then destroy object. If > it's after the load locked, the reservation is lost." Reservation is > lost, that for sure. However, store-conditional can raise all sorts > of "bad" exceptions (if the EA is "not good" by that time) even if > reservation is lost. It's implementation-defined on Power, IIRC. Ok, Joe said that "It needs the virtual storage to always be valid so the load locked won't segfault." Not sexy. regards, alexander. .