turning off garbage collection
Bernard Pope
bjpop at cs.mu.OZ.AU
Wed Jul 27 21:33:08 EDT 2005
On Wed, 2005-07-27 at 10:25 +0100, Simon Marlow wrote:
> On 27 July 2005 05:48, Bernard Pope wrote:
>
> > I'm fairly sure this has been asked before (and recently too), but I
> > can't seem to find it in the archives. Sorry for the repetition.
> >
> > Is there a way I can turn garbage collection off in GHC? I'm happy to
> > hack the runtime and comment out code if that is the only way. I just
> > don't know which code.
> >
> > I want to see what effect GC is having on programs that run under
> > buddha. I suspect it is costing me a lot in time traversing large
> > amounts of data that the debugger is hanging on to.
>
> You can always see the proportion of GC time by using +RTS -sstderr.
> You can also set a gigantic allocation area with +RTS -A1G.
Good idea. Thanks.
> Really disabling GC would entail just allocating more and more memory in
> the allocation area, and the RTS doesn't know how to do that at the
> moment (the alloc area is more or less fixed between GCs).
Ok.
> Also, you'd
> very quickly eat all the swap in your system, so perhaps this isn't what
> you want.
That's what I wanted to test. How fast the swap gets eaten and if there
is any thrashing. I don't actually want to use this idea in a real
system.
Thanks again for the tips.
Bernie.
More information about the Glasgow-haskell-users
mailing list