Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2003-05-06 14:50:10


Darren Cook <darren_at_[hidden]> writes:

> I've been comparing boost:pool to normal new/delete, and a couple of
> other algorithms. My results are shown below - not a very good profile
> test as it is too short and too general (and the pooling is only
> applied to one class), but good enough to show a trend.
>
> MemoryPool1 is based on Item 10 of Effective C++ by Scott
> Meyers. MemoryPool2 is similar but uses a vector of pointers insted of
> a union.
>
> Is Boost::Pool doing something time-consuming that not all
> applications need? E.g. my two MemoryPool classes require the block
> size to be specified as a template parameter. Also there is no
> allowance for getting a pointer to more than one object.
>
> Is there interest in a "SimplePool" class that is quicker and less flexible?

You might look at boost/detail/quick_allocator.hpp

-- 
Dave Abrahams
Boost Consulting
www.boost-consulting.com

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