Phobos for Review: std.buffer.scopebuffer

Lars T. Kyllingstad public at kyllingen.net
Fri Feb 7 02:02:30 PST 2014


On Friday, 7 February 2014 at 09:38:56 UTC, Walter Bright wrote:
> I picked on buildPath() for a reason. The program I was writing 
> did a lot of searching for files along a path, and by a lot I 
> mean tens of thousands of times (!).
>
> That one little 'ole allocation was murdering performance and 
> generating vast amounts of garbage.

I don't understand.  Even if your workspace is stack-based or 
malloc-ed, you still need that one GC allocation for the return 
value, no?

Lars


More information about the Digitalmars-d mailing list