
Bulat Ziganshin wrote:
i don't know what value shows the -xc oprion, but memory usage in ghc-compiled program are increased because by default used "copying" garbage collection algorithm. using option "+RTS -c" will significantly reduce memory usage, which will make program faster if it currently needs swapping. you can also force, for example, using of compacting algorithm when memory usage grows more than 200 mb with options "+RTS -M1G -c20". see "4.14.2. RTS options to control the garbage collector" in ghc docs for details running the profilingbinary (that was compiled with -prof -auto-all) with the -c option resulted in;
top: showing a max of 161mb memory usage profiled-graph: showing a peak at a little more than 80mb i guess these results are more or less normal? It does however mean that my datastructures are pretty harsh on the garbage collector, doesnt it? Niels.