<div dir="ltr">On 13 April 2013 00:01, Regan Heath <span dir="ltr"><<a href="mailto:regan@netmail.co.nz" target="_blank">regan@netmail.co.nz</a>></span> wrote:<br><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div class=""><div class="h5">On Fri, 12 Apr 2013 14:25:22 +0100, Dmitry Olshansky <<a href="mailto:dmitry.olsh@gmail.com" target="_blank">dmitry.olsh@gmail.com</a>> wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
12-Apr-2013 17:20, Dicebot пишет:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
On Friday, 12 April 2013 at 13:09:19 UTC, Lars T. Kyllingstad wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
On Friday, 12 April 2013 at 13:00:36 UTC, Robert wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
I would suggest, instead of writing your own std.process, that you<br>
simply provide a pull request to the now to be approved one, this way<br>
you can prove your point that it is easy by already improving a part of<br>
the standard library.<br>
</blockquote>
<br>
Actually, Manu (or anyone) could do this for *any* part of Phobos.<br>
And considering that std.process is probably the module that would<br>
benefit the least from it, maybe he should start somewhere else?<br>
std.string, perhaps, or std.algorithm?<br>
</blockquote>
<br>
Or probably druntime. This rise again and again - until standard global<br>
allocators are not here it is all a premature and useless optimization.<br>
It makes no sense to try to workaround a fundamental issue. That will be<br>
a lot of effort for no real gain.<br>
<br>
Allocators are a blocker for almost any memory-related issue in both<br>
druntime and phobos.<br>
</blockquote>
<br>
Same here - trying to get out of your way to avoid GC right now is both painful and useless in the long run. More then that it's limited as you can't have the default allocation scheme that fits all nor use some scheme that would require change of API (so that later it's broken again once allocators come).<br>

</blockquote>
<br></div></div>
My impression is that there is some low hanging fruit here.  My impression (pls correct me if I'm wrong) is that Manu is not trying to avoid the GC, but to avoid allocations (and presumably collections) at the wrong moment in time.<br>

<br>
So...<br>
<br>
If the GC were to have a hook function for allocation and for free, and if when these were in use it would not itself trigger collection.<br>
<br>
Then...<br>
<br>
Manu could supply hook functions, use the alloc function to supply pre-allocated memory, and trigger collection as/when convenient.<br></blockquote><div><br></div><div>Believe it or not, I'm not actually a fan of over-complexity. And I'm focusing here on totally unnecessary allocations.</div>
<div>Isn't using the stack where applicable just a whole low easier? That's what it's there for.</div><div style><br></div><div style>There are of course plenty of functions that do allocate by design, and in many cases, allocators would assist with those. But I'm not arguing for that right now, since allocators still seem to be a way off.</div>
<div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
For collection itself some upper bound time would also be desireable.<br></blockquote><div><br></div><div style>Absolutely. Is it possible for collection to run like a coroutine? Can it run a fragmented collection process, each time picking up where it left off?</div>
<div style><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
These ideas are nowhere near as complex as a full blown allocator proposal/idea.</blockquote><div><br></div></div></div></div>