Boost logo

Boost :

Subject: Re: [boost] [function] new implementation
From: Domagoj Saric (domagoj.saric_at_[hidden])
Date: 2010-11-03 10:26:04


"Domagoj Saric" <dsaritz_at_[hidden]> wrote in message
news:iand2f$2na$1_at_dough.gmane.org...
> ...this resulted in the largest binary size reduction...

Speaking of binary size, if you have not already run your testing you might
want to update, I've refactored the (copy) construction and destruction code
to avoid creating unnecessary EH states (and related bloat).
With the new code,
    bjam variant=release link=shared runtime-link=shared signals
gives:
- gcc 4.0.1:
    sizeof( libboost_signals.dylib, official b.function ) = 126.076 bytes
    sizeof( libboost_signals.dylib, new b.function ) = 109.676 bytes
- clang 2.8
    sizeof( libboost_signals.dylib, official b.function ) = 98.960 bytes
    sizeof( libboost_signals.dylib, new b.function ) = 85.604 bytes

That's about 15% less with a simple recompilation...also note that (as far
as I could tell from skimming through signals source), boost::signals use
only a single boost::function instantiation...

ps. When it comes to binary size MSVC is still way ahead of the GNU tools,
producing a DLL half the size of the Clang 2.8 result and the difference
between the old and new function builds is very small with VC10...

-- 
"What Huxley teaches is that in the age of advanced technology, spiritual
devastation is more likely to come from an enemy with a smiling face than
from one whose countenance exudes suspicion and hate."
Neil Postman 

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