dotgnu-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [DotGNU]Finalization


From: Gopal V
Subject: Re: [DotGNU]Finalization
Date: Sun, 22 Jun 2003 15:48:21 +0530
User-agent: Mutt/1.2.5i

If memory serves me right, Rhys Weatherley wrote:
> Because there are three calls to "new Pok()", the second and third will 
> overwrite the temporary storage used by the first and second.  This will 
> leave a pointer to the third still in play, and hence uncollectable until 
> something else stomps on it.

Even worse try the sample attached ...

ie the last pk=new Pok(3);

is never finalized.. so this not a random occurrence ..
> Prior to calling the collector for the last time, clear all of the CVM thread 
> stacks to zero.  This will remove any transistory pointers and allow them to 
> be collected.  Some experimentation is probably required to find the right 
> balance - I doubt you'll be able to collect everything.

Yes ...

> > PS.  I have monitors working and finalizers are now running on a
> > separate thread :D.
> 
> Fantastic!

We have lift-off in threading, yeah !

Gopal
-- 
The difference between insanity and genius is measured by success

Attachment: TestFinalizer.cs
Description: Text document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]