[Mono-list] Is there a mechanism to precompile a method?

Miguel de Icaza miguel@ximian.com
12 Sep 2002 12:43:20 -0400


Hello,

> You are right, the garbage collector is a problem. The code we will execute 
> under real-time conditions is somewhat constrained in the way it allocates 
> memory. We hope that this can be used to prevent a garbage collection to 
> occur for threads being executed in real-time. 
> 
> Of course, we still need to do some research in this area. Carl, do you know 
> of some useful references on real-time garbage collection? 

One thing I wanted to explore in the past (but there has been no need to
do so far) is to use implicit reference counting with cycle detection
for the GC engine.  It uses some extra 32 bits of memory per object
allocated, but it gives you the predictability you are looking for.

There are various papers that discuss the subject, we have some linked
from the Mono site.

> I was not yet able to look at the gc interface of Mono. How difficult would 
> it be to switch from the currently used Boehm-Weiser collector to a different 
> one? Could this be done for single domains or threads?

It is doable, but requires a lot of work.

Miguel