This is the mail archive of the guile@sourceware.cygnus.com mailing list for the Guile project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Making GC aware of overall allocation?


Lars Arvestad <arve@nada.kth.se> writes:

> That is what I have done, but since my datastructures are very large
> (depends on input (which depends on my test setup), but a typical size 
> is 20 MB) and I run hundreds of tests, each generating three
> datastructures, "eventually" is not good enough. I run out of swap
> space before Guile decides to do a GC. 

Well, you can also lie to Guile. From your glue code (SMOB
constructor) call scm_done_malloc with fixed ammount (say 100,000),
and return the same ammount from smob free. It doesn't matter how much
you register and return, just make sure the numbers are the same.

-- 
How to eff the ineffable?

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]