Garbage Collection tuning in Go for Microservices -- saved 70K Cores

Interesting article i just came across. Perhaps some insights relevant for Prolog GC tuning …

There are surely Prolog applications where GC is a major component. Fortunately not that many :slight_smile: There is actually a (undocumented) hook prolog:tune_gc/3 that is called if GC uses over 20% of the time. It is passed some stats over the recent GC calls and may decide to update the GC parameters. Next to the Prolog stack GC we have atom and clause garbage collectors. The atom-GC can be tuned on the number of atoms that could be garbage. Just tuning the number of garbage atoms is probably problematic if very long atoms are involved.

It is wise to keep an eye on these for slow tasks or heavily loaded server processes. Most of the relevant stats are accessible through statistics/2.