Nice garbage collector for C extensions!

Nick Jacobson nicksjacobson at yahoo.com
Tue Jul 20 04:23:08 EDT 2004


In the Python documentation on Extending and Embedding (in section
1.10), there's a quote:

"Maybe some day a sufficiently portable automatic garbage collector
will be available for C. Until then, we'll have to live with reference
counts."

What about the Boehm-Demers-Weiser conservative garbage collector (at
http://www.hpl.hp.com/personal/Hans_Boehm/gc/)?

They state, "The collector is not completely portable, but the
distribution includes ports to most standard PC and UNIX/Linux
platforms. The collector should work on Linux, *BSD, recent Windows
versions, MacOS X, HP/UX, Solaris, Tru64, Irix and a few other
operating systems. Some ports are more polished than others."

That's not bad! :)

The license also looks good, and it states, "Both space and time
overhead are likely to be only slightly higher for programs written
for malloc/free."

--Nick



More information about the Python-list mailing list