Pool allocators, the Next Generation

Stefan Olsson stefan@snon.net
Thu Feb 20 22:22:00 GMT 2003


Phil Edwards wrote:

>I've been threatening to rework the pool allocator for years now.  After I
>was snowed in last week, suffering from coder's block on my reflection
>project, I decided it was past time to turn the diagrams on my whiteboard
>into code.  And the first 90% is done.
>
Great! The more ideas/solutions the better!

>If you've read Alexandrescu's book, or have heard of the "policy classes"
>that feature so prominently in it, then you have an idea of what I want
>to accomplish.  A pool allocator is (in concept) extremely configurable;
>we currently have hardcoded decisons in many places, but we should be able
>to get a customized p.a. by "policy composition".  For example, my local
>patch has a declaration like
>
[ too bad - the bookshop is closed - have to wait til tomorrow ]

This sounds very interesting! Since the existing allocators has 
hardcoded values, we have done the same right now but being able to 
define max bytes (which translates into the number of power-of-2 bins in 
our allocator for instance) etc would be great.

>[*] MT Allocator That Doesn't Suck
>  
>
*lol*

Brgds

/Stefan

-- 
Experience is what you get when you were expecting something else.




More information about the Libstdc++ mailing list