June 12, 2015 Phobos addition formal review: std.experimental.allocator | ||||
---|---|---|---|---|
| ||||
The legendary allocator package by Andrei Alexandrescu has arrived at your doorsteps and kindly asks to let it into Phobos http://wiki.dlang.org/Review/std.experimental.allocator Docs: http://erdani.com/d/phobos-prerelease/std_experimental_allocator.html Code: https://github.com/andralex/phobos/tree/allocator/std/experimental/allocator This proposal will undergo the review/inclusion process similar to std.experimental.logger : 1. 2 week review/discussion period 2. if proposal author feels confident, 2 week voting period for accepting into sts.experimental 3. once enough field trial feedback has been accumulated, vote for moving into std mainline during the upcoming release beta period If reviewing find some fundamental issues or voting will fail, the whole process will repeats again per proposal authors request. Please start destruction, review period ends on 26.06 (23.59 +0 Greenwich) |
June 12, 2015 Re: Phobos addition formal review: std.experimental.allocator | ||||
---|---|---|---|---|
| ||||
Posted in reply to Dicebot | Small tip for reviewers: there are quite many modules in proposed package but majority is actual allocator implementation. I'd suggest to start investigating sources/documentation starting from http://erdani.com/d/phobos-prerelease/std_experimental_allocator.html and http://erdani.com/d/phobos-prerelease/std_experimental_allocator_building_blocks.html while using http://erdani.com/d/phobos-prerelease/std_experimental_allocator_showcase.html as reference for "highlight" examples. |
June 12, 2015 Re: Phobos addition formal review: std.experimental.allocator | ||||
---|---|---|---|---|
| ||||
Posted in reply to Dicebot | Also wanted to apologize for authors of any other Phobos proposals - I did intend to step down from review manager role but this specific package is of huge personal interest to me, thus the exception has been made. |
June 12, 2015 Re: Phobos addition formal review: std.experimental.allocator | ||||
---|---|---|---|---|
| ||||
Posted in reply to Dicebot | On Friday, 12 June 2015 at 11:06:43 UTC, Dicebot wrote:
> The legendary allocator package by Andrei Alexandrescu has arrived at your doorsteps and kindly asks to let it into Phobos
>
> http://wiki.dlang.org/Review/std.experimental.allocator
>
> Docs: http://erdani.com/d/phobos-prerelease/std_experimental_allocator.html
> Code: https://github.com/andralex/phobos/tree/allocator/std/experimental/allocator
>
> This proposal will undergo the review/inclusion process similar to std.experimental.logger :
>
> 1. 2 week review/discussion period
> 2. if proposal author feels confident, 2 week voting period for accepting into sts.experimental
> 3. once enough field trial feedback has been accumulated, vote for moving into std mainline during the upcoming release beta period
>
> If reviewing find some fundamental issues or voting will fail, the whole process will repeats again per proposal authors request.
>
> Please start destruction, review period ends on 26.06 (23.59 +0 Greenwich)
Great work :)
It would be nice if someone could write some tests/benchmarks in order to show for each allocator where it works well over others.
|
June 12, 2015 Re: Phobos addition formal review: std.experimental.allocator | ||||
---|---|---|---|---|
| ||||
Posted in reply to Dicebot | On 2015-06-12 13:06, Dicebot wrote: > The legendary allocator package by Andrei Alexandrescu has arrived at > your doorsteps and kindly asks to let it into Phobos > > http://wiki.dlang.org/Review/std.experimental.allocator > > Docs: http://erdani.com/d/phobos-prerelease/std_experimental_allocator.html > Code: > https://github.com/andralex/phobos/tree/allocator/std/experimental/allocator As I said in the other thread: * Andrei's ODBC code seems to be in the same branch * Some code is commented in std.math and std.traits * What is std.typed_allocator? It doesn't seem to have anything related to allocators, some leftover code? -- /Jacob Carlborg |
June 12, 2015 Re: Phobos addition formal review: std.experimental.allocator | ||||
---|---|---|---|---|
| ||||
Posted in reply to Jacob Carlborg | On 6/12/15 7:31 AM, Jacob Carlborg wrote: > On 2015-06-12 13:06, Dicebot wrote: >> The legendary allocator package by Andrei Alexandrescu has arrived at >> your doorsteps and kindly asks to let it into Phobos >> >> http://wiki.dlang.org/Review/std.experimental.allocator >> >> Docs: >> http://erdani.com/d/phobos-prerelease/std_experimental_allocator.html >> Code: >> https://github.com/andralex/phobos/tree/allocator/std/experimental/allocator >> > > As I said in the other thread: > > * Andrei's ODBC code seems to be in the same branch > * Some code is commented in std.math and std.traits > * What is std.typed_allocator? It doesn't seem to have anything related > to allocators, some leftover code? Sorry about that. I now created a pull request with that stuff taken care of: https://github.com/D-Programming-Language/phobos/pull/3405 Andrei |
June 12, 2015 Re: Phobos addition formal review: std.experimental.allocator | ||||
---|---|---|---|---|
| ||||
Posted in reply to Dicebot | On 6/12/15 4:08 AM, Dicebot wrote: > Small tip for reviewers: there are quite many modules in proposed > package but majority is actual allocator implementation. I'd suggest to > start investigating sources/documentation starting from > http://erdani.com/d/phobos-prerelease/std_experimental_allocator.html > and > http://erdani.com/d/phobos-prerelease/std_experimental_allocator_building_blocks.html > while using > http://erdani.com/d/phobos-prerelease/std_experimental_allocator_showcase.html > as reference for "highlight" examples. A few more words on that: Think of std.experimental.allocator as a three-layered cake: * An untyped layer, dealing exclusively in void[], and where all action is happening. That's where work is getting done, and also where assembly of various custom allocators happens. Best entry point for that is http://erdani.com/d/phobos-prerelease/std_experimental_allocator_building_blocks.html, which describes this layer's design and links to all untyped components. * A statically-typed layer, which takes types from the user and gives back typed memory. There are two good entry points here: http://erdani.com/d/phobos-prerelease/std_experimental_allocator.html contains generic routines for creating and destroying typed objects using any untyped allocator: make, dispose, etc. There is also assembly at this level, i.e. deciding to use different heaps for shared vs. unshared data: http://erdani.com/d/phobos-prerelease/std_experimental_allocator_typed.html (this is particularly beautiful or awful, depending). * A dynamicaly-typed layer that allows the user to swap allocators at runtime. This is embodied in IAllocator, CAllocatorImpl, theAllocator, and processAllocator. Thanks in advance for reviewing this! Andrei |
June 12, 2015 Re: Phobos addition formal review: std.experimental.allocator | ||||
---|---|---|---|---|
| ||||
Posted in reply to Andrei Alexandrescu | On 6/12/15 8:54 AM, Andrei Alexandrescu wrote: > * A dynamicaly-typed layer that allows the user to swap allocators at > runtime. This is embodied in IAllocator, CAllocatorImpl, theAllocator, > and processAllocator. Forgot to mention - the entry point for this layer is also http://erdani.com/d/phobos-prerelease/std_experimental_allocator.html. Andrei |
June 12, 2015 Re: Phobos addition formal review: std.experimental.allocator | ||||
---|---|---|---|---|
| ||||
Posted in reply to Dicebot | On Friday, 12 June 2015 at 11:09:01 UTC, Dicebot wrote: > Small tip for reviewers: there are quite many modules in proposed package but majority is actual allocator implementation. I'd suggest to start investigating sources/documentation starting from http://erdani.com/d/phobos-prerelease/std_experimental_allocator.html and http://erdani.com/d/phobos-prerelease/std_experimental_allocator_building_blocks.html while using http://erdani.com/d/phobos-prerelease/std_experimental_allocator_showcase.html as reference for "highlight" examples. while building the package as a static lic library, i've found that _showcase.d_ is not usable under Windows because MmapAllocator is Posix only: https://github.com/andralex/phobos/blob/allocator/std/experimental/allocator/showcase.d#L66 https://github.com/andralex/phobos/blob/allocator/std/experimental/allocator/mmap_allocator.d#L14 |
June 12, 2015 Re: Phobos addition formal review: std.experimental.allocator | ||||
---|---|---|---|---|
| ||||
Posted in reply to Baz | On 6/12/15 11:23 AM, Baz wrote:
> On Friday, 12 June 2015 at 11:09:01 UTC, Dicebot wrote:
>> Small tip for reviewers: there are quite many modules in proposed
>> package but majority is actual allocator implementation. I'd suggest
>> to start investigating sources/documentation starting from
>> http://erdani.com/d/phobos-prerelease/std_experimental_allocator.html
>> and
>> http://erdani.com/d/phobos-prerelease/std_experimental_allocator_building_blocks.html
>> while using
>> http://erdani.com/d/phobos-prerelease/std_experimental_allocator_showcase.html
>> as reference for "highlight" examples.
>
> while building the package as a static lic library, i've found that
> _showcase.d_ is not usable under Windows because MmapAllocator is Posix
> only:
>
> https://github.com/andralex/phobos/blob/allocator/std/experimental/allocator/showcase.d#L66
>
> https://github.com/andralex/phobos/blob/allocator/std/experimental/allocator/mmap_allocator.d#L14
I've asked this a while ago as well - could anyone with a Windows rig contribute a MmapAllocator for Windows? Thanks! -- Andrei
|
Copyright © 1999-2021 by the D Language Foundation