What do you mean by 'rooted'? Do you mean that it's reachable from a root?
If so, the problem is that the CLR never knows whether a particular object is reachable except on the occasions when it performs a GC. If it was able to determine whether objects were reachable without performing a GC, it wouldn't need to do most of the work involved in performing a GC! Why do you need to know this? -- Ian Griffiths DevelopMentor > -----Original Message----- > From: Pinto, Ed [mailto:[EMAIL PROTECTED] > > I've got a cache that needs to know that a weakreference's target is > rooted. > What is the best way to do this? > > The cache is accessed ~20 times/second in a server environment, and once > per > minute in a rich client environment. > > Calling GC.Collect would solve my logical problem, but I can't imagine > that > it would be very performant on the server. > > Are there other options I can use? Would the profiler APIs help