From 3ef21ac719daf07573afda0c63cb5ef944787587 Mon Sep 17 00:00:00 2001 From: Lars Karlslund Date: Thu, 19 Dec 2024 13:10:22 +0100 Subject: [PATCH] Added GC runs between each stage of loading and processing --- modules/engine/run.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/modules/engine/run.go b/modules/engine/run.go index 063dd70..41e1bee 100644 --- a/modules/engine/run.go +++ b/modules/engine/run.go @@ -86,6 +86,7 @@ func Run(paths ...string) (*Objects, error) { } preprocessWG.Wait() + runtime.GC() overallprogress.Add(1) // Merging @@ -95,10 +96,12 @@ func Run(paths ...string) (*Objects, error) { } ao, err := Merge(objs) + runtime.GC() overallprogress.Add(1) for priority := AfterMergeLow; priority <= AfterMergeFinal; priority++ { PostProcess(ao, priority) + runtime.GC() overallprogress.Add(1) }