This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: [Patch/RFC] tr1::shared_ptr<> removal of lock, choosing thread safety
Hi Paolo,
On 23/07/06, Paolo Carlini <pcarlini@suse.de> wrote:
apparently Benjamin also likes this approach, therefore, in general, I
would say let's go ahead for mainline and test it there on more arches:
in case of problems we have time to revert it for 4.2.0 and, in any
case, the "stability" requirements for tr1 are "special". Anyway, I just
tested it on 4-way ia64-linux too.
OK.
My only minor nit would be double (instead of triple) underscore for
__enable_shared_from_this; I would suggest renaming __lockless to
_S_lockfree and also __locks to _S_mutex and __unsafe to _S_single;
maybe _Locking_mode is better english than _Lock_mode (your call...)
Maybe Benjamin wants to help here (*)...
Ah, I remember now I wanted to ask about the
__enable_shared_from_this: there is already a function with the double
underscore name, and I figured that renaming the function and then
naming the template class with the double underscore was probably a
bad idea. What should I go with here, and to what do I rename it?
I'll rename the enum (members).
Of course, before the final approval, please post a ChangeLog entry
(have a look to ChangeLog about the style. You can certainly group
functions which are only renamed).
OK, will do.
I'll make an equivalent lock-based test case as suggested.
Thanks,
~phil