[gclist] Buffy finalizer slayer.
Fri, 11 Jun 1999 10:02:01 -0400
At 08:03 AM 6/11/99 -0500, Charles Fiterman wrote:
>So instead of running a finalizer lets send out a death notice. I call
>objects receiving a death notice watcher objects. One way of building a
>watcher object is to include a weak pointer to the object to be shut down.
>Finalizers may allocate storage and trigger a collect from within the
>Finalizer objects require extra collector overhead in a world where we are
>judged by latency. Watcher objects run at the convenience of the mutator.
You should probably go have a look at weak/soft/phantom references
in the "Java 2" (aka jdk1.2) documentation. However, I find these
weak references are no easier or cheaper to implement than
finalization. It has also been our experience ("our" == me and
colleagues) that Finalizer objects do not run "within" the collector;
instead, the collector queues them and hands them off to the mutator,
where they are run in one of a collection of threads designated
for this purpose (not under user control, but not randomly chosen,
David Chase -- firstname.lastname@example.org
NaturalBridge LLC -- http://www.naturalbridge.com
BulletTrain bytecode compiler -- when you can't wait for performance