Boost logo

Boost :

Subject: Re: [boost] [shared_ptr] Design question about make_shared
From: Peter Dimov (pdimov_at_[hidden])
Date: 2011-06-16 06:11:06


Stephan T. Lavavej wrote:
> I don't look at Boost's implementation, but this makes me curious as to
> whether you implement the "we know where you live" optimization. On x86,
> for a 4-byte Foobar, how big is your reference count control block for
> make_shared<Foobar>()? Mine is 16 bytes.

Yes, you're right, I'm not eliminating the pointer at the moment. (I wasn't
sure to which optimization you refer.)


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