Boost logo

Boost :

From: Philippe A. Bouchard (philippeb_at_[hidden])
Date: 2002-09-04 08:33:16


Larry Evans wrote:

[...]

> 1) These, let's call them "root" pointers (to avoid deciding
> whether to call them stack of static), must be stored in some container in
> available to the collector in order to do the collection.
> The root pointer must also be removed from
> same when m_stacked becomes 0. If map is used, that's a big time hit
> when many
> short-lived shared_ptrs are used (as is often the case). Greg had a faster
> method.

Sounds good.

> 2) m_stacked will not be incremented for each placed_ptr in, e.g.:
>
> vector<placed_ptr<T> > x1;
> vector<vector<placed_ptr<T> > > x2;
> ...
>
> because the "real" root pointers are those starting the vectors.

I was thinking about doing it, but how? and what about the required time?
... I'll try Greg's and come back at the end of the week. Thanks.

-- 
Philippe A. Bouchard

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk