On 6/7/16 4:05 AM, Russel Winder via Digitalmars-d wrote:
On Mon, 2016-06-06 at 16:56 +0000, Wyatt via Digitalmars-d wrote:
On Monday, 6 June 2016 at 14:27:52 UTC, Steven Schveighoffer
wrote:
I agree. It's telling that nearly all real-world examples we've
seen (sociomantic, remedy games, etc.) use D without GC or with
specialized handling of GC.

I doubt either of the two you named would change, but I wonder
how different the tenor of conversation would be in general if
D's GC wasn't a ponderous relic?

So instead of debating this endlessly, I think this is about the tenth
time this has come up in the last two years, why doesn't a group of
people who know about GC algorithms get together and write a new one?

People have. Reiner wrote a precise scanning GC. Leandro wrote a forking GC that is used in Sociomantic's software. Martin has made some huge improvements to the existing GC for performance.

I think there is some difficulty taking a new GC and putting it into druntime. We druntime developers take for granted many times how the GC is implemented, without considering the ability to swap it out.

Let's also not forget that the GC is a super-integral part of the runtime, and it deals with one of the most difficult-to-debug aspects - memory allocation. If you replace the GC, you better have it perfect.

From my experience replacing the D array runtime, it is a very very difficult thing to debug and get right, the bugs are disastrous and difficult to trace and reproduce.

Not to say we shouldn't do it, I think we should at LEAST have it optional (like with globally recognized runtime parameters: --usegc myfavoritegc). But I don't want to act like GC improvement is something nobody has ever looked at.

My opinion, the first optional one to include is the forking GC, since it has been in production for years for one company. We may even find some bugs in it to help out Sociomantic, since they have discovered and helped fix so many problems with D :)

If we have the ability to swap out GCs, then it makes it easier to define how the GC API must work.

-Steve

Reply via email to