What's the go with the GC these days?

Reimer Behrends behrends at gmail.com
Mon Jan 7 09:31:57 UTC 2019


On Monday, 7 January 2019 at 06:52:40 UTC, H. S. Teoh wrote:
> I've experienced a similar effect in Firefox, and though I 
> cannot say for sure it isn't a GC problem, I notice that it 
> causes a long spike of intensive I/O, and appears to be 
> correlated with occasional segfaults and signs of memory 
> corruption / memory leak, and generally happens only after 
> significant usage over a prolonged timeframe, generally ending 
> up in a state of extreme memory usage (several GBs in resident 
> set size for just a small number of persistent tabs) that reset 
> to more reasonable levels upon restarting and restoring exactly 
> the same tabs.

Firefox/Thunderbird are written mostly in C/C++/Rust. 
SpiderMonkey (the JS engine) does have a GC, but that one is 
incremental and generational and limited to JS memory. So I think 
it's unlikely that GC is the culprit.

There are any number of reasons why Firefox/Thunderbird might 
freeze, from synchronous JavaScript to inefficient or misplaced 
[1] SQLite queries.

[1] E.g. https://bugzilla.mozilla.org/show_bug.cgi?id=1266829


More information about the Digitalmars-d mailing list