[plug] Garbage Collection in C

James Devenish devenish at guild.uwa.edu.au
Wed Nov 26 11:55:54 WST 2003


In message <20031126034808.89543.qmail at web8103.mail.in.yahoo.com>
on Wed, Nov 26, 2003 at 03:48:08AM +0000, Alex Bobby wrote:
> Do we have any better technical approach to implement garbage
> collection in C, other than establishing a counter and freeing ()
> the dynamic chunk when the count becomes zero.

Although the C language itself does not define high-level garbage
collection, there are runtime libraries for this purpose. If you have
APT installed, you might try `apt-cache search garbage` for 'popular'
options. Of course, Google is probably more informative.

> I believe to make use of the storage classes of the pointers pointing
> to the chunk, the information embedded in the object file, by the
> compiler.
>  
> Thus, we go beyond the compilation phase, which I am not interested in.

Are you saying you want to do static compile-time analysis or are you
saying that you /don't/ want to? I am not sure what you mean. The
solutions to these problems are not likely to be Linux-specific,
so you might find better advice elsewhere.


_______________________________________________
plug mailing list
plug at plug.linux.org.au
http://mail.plug.linux.org.au/cgi-bin/mailman/listinfo/plug


More information about the plug mailing list