Boost logo

Boost :

From: Beman Dawes (bdawes_at_[hidden])
Date: 2002-04-30 15:08:21

At 02:53 PM 4/30/2002, Greg Colvin wrote:

>At 12:41 PM 04/28/2002, Beman wrote:
>>* LWG members are very concerned that "you don't have to pay for what
>don't use." This is particularly true of memory; increased memory use due
>to multiple inheritance or to accommodate weak_ptr, for example, is
>as a serious problem.
>I don't really think that is such a big issue, unless shared objects
>are hardly shared at all, and maybe not even then.
>The overhead for the weak pointer need be only one word per object, not
>per pointer, and the smart pointer itself need be only one or two words.

Well, the issue could be put to rest by providing sizeof() information for
a number of compilers. Test code should probably report sizeof()
routinely, since it is something that people do care about.

It isn't so much a concern for single smart pointers, but when you have a
vector of smart pointers, sizeof() each smart pointer gets important.


Boost list run by bdawes at, gregod at, cpdaniel at, john at