April 06, 2012 Standard Library (Phobos) Garbage Collection | ||||
|---|---|---|---|---|
| ||||
Hi All, First off.. I am not against garbage collection :) With mobile platforms becoming more prevalent. The battery power is the most essential asset that we need to use frugally. IOS shines in this category and Android's VM approach does not give us that much juice. D is a great step towards having both, productivity and performance for our dinner. I feel a standard library which does not use GC by default, provides an option of managing the code manually (good for mobile development). By providing this option, programmers can use std library always and the option of going manual or GC totally depends upon them. Any thoughts are much appreciated. -Adam | ||||
April 06, 2012 Re: Standard Library (Phobos) Garbage Collection | ||||
|---|---|---|---|---|
| ||||
Posted in reply to crudbug | On Friday, April 06, 2012 05:20:35 crudbug wrote:
> Hi All,
>
> First off.. I am not against garbage collection :)
>
> With mobile platforms becoming more prevalent. The battery power is the most essential asset that we need to use frugally. IOS shines in this category and Android's VM approach does not give us that much juice.
>
> D is a great step towards having both, productivity and performance for our dinner. I feel a standard library which does not use GC by default, provides an option of managing the code manually (good for mobile development). By providing this option, programmers can use std library always and the option of going manual or GC totally depends upon them.
>
> Any thoughts are much appreciated.
The main place that Phobos uses the GC is with arrays. And arrays are so crippled without the GC that it's not even funny (particularly with regards to slices). There's no way that Phobos isn't going to use the GC.
Now, outside of arrays, I believe that its GC usage is fairly light. The main other issue is containers, and we're going to have custom allocators to solve that. So, GC usage and containers shouldn't be an issue in the long run.
- Jonathan M Davis
| |||
Copyright © 1999-2021 by the D Language Foundation
Permalink
Reply