Why I Like D

Ola Fosheim Grøstad ola.fosheim.grostad at gmail.com
Thu Jan 13 16:28:42 UTC 2022


On Thursday, 13 January 2022 at 11:57:41 UTC, Araq wrote:
> But the time it takes depends on the number of threads it has 
> to stop and the amount of live memory of your heap. If it took 
> 4ms regardless of these factors it wouldn't be bad, but that's 
> not how D's GC works...

Sadly fast scanning is still bad, unless you are on an 
architecture where you can scan without touching the caches. If 
you burst through gigabytes of memory then you have a negative 
effect on real time threads that expect lookup tables to be in 
the caches. That means you need more headroom in real time 
threads, so you sacrifice the quality of work done by real time 
threads by saturating the memory data bus.

It would be better to have a concurrent collector that slowly 
crawls or just take the predicable overhead of ARC that is 
distributed fairly even in time (unless you do something silly).



More information about the Digitalmars-d-announce mailing list