On Sat, Jun 18, 2022 at 8:52 AM Lars Ingebrigtsen wrote: > Stefan Monnier writes: > > As far as I know, we never actually release back cons space to the OS > anyway -- even if we could. (Because glibc's malloc implementation > doesn't do that unless we call that trim function, which we don't.) So > I'm not sure that makes much difference -- especially in a batch process. > > Does this mean that, once the heap size of the process has been increased by a large gc threshold, every subsequent gc will be proportional to the largest heap size ever required, regardless of whether some of it could be permanently freed? So, if the process terminates before collection, then it will run faster, but if it keeps running, the gc "pause" time will be permanently longer for each subsequent gc?