[Mono-devel-list] Limiting Memory Allocation

Jim Purbrick jimpurbrick at yahoo.co.uk
Mon May 2 11:16:54 EDT 2005


--- Ben Maurer <bmaurer at ximian.com> wrote: 
> It is quite possible to intercept each allocation
> with our profiling api. However, you can't
"disallow" 
> an allocation. I guess you could hack
> the runtime to allow you to throw an OOM exception.

I've got the allocation tracking working with the
profiling API, can work out how much memory a script
has allocated and throw an exception from there when
the limit is reached (admitedly after the allocation
which breaks the limit). Is there a way to track how
much of a scripts memory is freed so I can work out
the current allocated total for each script? I imagine
this might be complicated by the GC.

Cheers,

Jim.

Send instant messages to your online friends http://uk.messenger.yahoo.com 



More information about the Mono-devel-list mailing list