This is the mail archive of the gsl-discuss@sourceware.cygnus.com mailing list for the GSL project.


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

Re: Reference counting for matrices


Klaus Schilling wrote:
> 
> And this doesn't depend on the garbage collection mechanism of the VHLL?
> The mark-and-sweep of guile, ruby, elastiC and ici doesn't ressemble at
> all the primitive refcounting of perl. Can one expect the same thing
> to work well with all of the various mechanisms?
> 
> Klaus Schilling

If I understand this message correctly, then I agree
completely. Leave garbage collection to the garbage
collectors. And C is not the best context in which
to deal with such things. Garbage collection should be
provided by a non-intrusive mix-in which can be turned
on and off at will. In the case of VHLL wrappers, the
mix-in is provided by the VHLL runtime facility, and the
wrapper implementation is straightforward. In the C++ world
you can provide a mix-in class to handle reference counting
when needed or insert a complete mark-and-sweep system
below the library implementation level, w/o disturbing the
underlying library objects. At the library level in C,
you would have to stand on your head. Forget it.

-- 
G. Jungman

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