Linus with some good observations on garbage collection
dsimcha
dsimcha at yahoo.com
Sat Apr 23 07:40:29 PDT 2011
On 4/23/2011 10:24 AM, bearophile wrote:
> dsimcha:
>
>> Right. This is exactly the kind of thing TempAlloc was meant to solve.
>
> I think TempAlloc is meant for larger allocations. D-VLAs are meant to allocate little arrays (like 1 KB or less) on the normal stack very quickly.
>
> Bye,
> bearophile
Why would TempAlloc not work for this? It's slightly slower than VLAs,
but the difference is negligible since it's still almost never a
threading bottleneck and you still have to do something with the array
you allocated.
More information about the Digitalmars-d
mailing list