GCs in the news

Abdulhaq via Digitalmars-d digitalmars-d at puremagic.com
Thu Jul 17 11:14:42 PDT 2014


On Thursday, 17 July 2014 at 16:56:56 UTC, Vic wrote:
> On Thursday, 17 July 2014 at 13:29:18 UTC, John wrote:
> <snip>
>>
>> If D came without GC, it would have replaced C++ a long time 
>> ago!
>
> Agree +1000.
>
> If GC is so good, why not make it an option, have a base lib 
> w/o GC.
>
> If I want GC, I got me JRE. It seems that some in D want to 
> write a better JRE, and that just won't happen ever.
>
> Cheers,
> Vic

I can't think of anyone posting here, to be honest, who wants to 
write a better JRE. The JRE is a virtual machine, and java 
compiles to bytecode that is run on the JVM. On the contrary, and 
in accordance with the core principle that D is a systems 
programming language, D compiles to native and (hopefully) highly 
optimised native machine code. There does exist something of a 
'culture clash' where, by the very nature of GCs, there can be 
not-insignificant pauses in the running of the program that would 
be inimicable to real-time software such as high res complex 
games, operating systems, drivers etc.

The response to this in the forums is either to improve the GC so 
that it doesn't ever pause for more than a certain amount of time 
(e.g. concurrent GCs, remove the global lock so other threads can 
continue to run), or to offer alternative memory management 
approaches such as ARC, which can also have pauses, but at other 
inflections as the program runs.

Personally I'm a bit disappointed that the good work that has 
been done on GCs so far doesn't seem to be being picked up and 
run with, and nor do I see any reasons given as to why that is 
the case. Adnrei was threatening to start another GC an one point 
but unfortunately I haven't seen any more of that and we all know 
how short of time every one seems to be these days.

Also on a personal note, I see some slightly snarky comments 
about D targeting C# and Java. Well from my perspective I'm 
extremely happy with the fact that D is a better C# and a better 
Java. I just wish it had Qt (I must finish my bindings for Qt) 
and/or ran on Android! The GC issues are irrelevant for me.


More information about the Digitalmars-d mailing list