From: Greg Colvin (gcolvin_at_[hidden])
Date: 1999-08-15 12:16:38
From: Reid Sweatman <reids_at_[hidden]>
> I can see benefits to going either way, so I wonder whether you couldn't
> combine them. That is, use the registry method, but don't physically remove
> the pointer, even when its count goes to zero; that way, you'd get a (small)
> win by simply reassigning the nulled pointer, rather than having to
> reallocate it. Don't know if this would be enough of a win to matter,
> though. If not, I think I'd personally prefer deferred. Or perhaps combine
> the two by maintaining a simple linked list of nulled pointers still in the
> map, sort of an available allocation pool. I've written schemes like that
> often enough to appreciate having them built in.
I think an std::map of my weak_ptr, combined with a function to sweep out
null pointers, might provided such a deferred map.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk