std.allocator ready for some abuse

Dejan Lekic dejan.lekic at gmail.com
Thu Nov 7 08:39:23 PST 2013


On Thursday, 24 October 2013 at 19:53:56 UTC, Andrei Alexandrescu 
wrote:
> Hello,
>
>
> I know it's been a long wait. Hopefully it was worth it. The 
> alpha release of untyped allocators is ready for tire-kicking 
> and a test drive.
>
> Code: 
> https://github.com/andralex/phobos/blob/allocator/std/allocator.d
>
> Dox: http://erdani.com/d/phobos-prerelease/std_allocator.html
>
> Warning: this is alpha quality. Unit tests are thin, and there 
> are no benchmarks. Both would be appreciated, particularly 
> benchmarks to validate the gains (which I speculate can be very 
> sizable) of custom-built, special-purpose allocators compared 
> to traditional allocators.
>
> I acknowledge I'm clearly in no position to evaluate this 
> design. I have been knocking around it for long enough to have 
> no idea how easy it is to get into it from the outside, or how 
> good it is. By all signs I could gather this feels like good 
> design, and one of the best I've ever put together. The 
> allocators defined have an archetypal feeling, are flexible 
> both statically and dynamically, and morph and combine in 
> infinite ways.
>
> CAllocator and CAllocatorImpl make the link between the static 
> and dynamic worlds. Once an allocator is assembled out of 
> pieces and finely tuned, wrapping it in a dynamic API is a snap.
>
> Please destroy! I've literally sweat as I'm sending this :o).
>
>
> Andrei

All I can say is - I can't wait to see it in the run-time 
library! I read about the jmalloc last year, and your work makes 
it possible to have something similar in D. Kudos! System 
developers will definitely like std.allocator, no doubt! :)


More information about the Digitalmars-d mailing list