3

I use DotTrace as memory profiler. I wonder how it can filter circular incoming references?

As for the scenarios that I want to see who the hell holds reference to my object and keep it alive, those circular references, especially event handlers are not of interest but the true bad reference is often hidden among them.

Additionally, what is the meaning of "Show Held in New Tab" and "Show Reachable in New Tab" and do these help identifying circular references?

Many thanks to any answer.

Brett Veenstra
  • 47,674
  • 18
  • 70
  • 86
Steve
  • 4,935
  • 11
  • 56
  • 83

1 Answers1

0

What do you mean by "circular references"? If I recall correctly, there's no way to achieve a memory leak through circular references as the GC would identify and destroy the whole sub-graph of inter-connected objects.

If, however, any of the objects in the sub-graph has a live reference, the whole graph survives. So you should probably take a closer look to all of the objects you suspect and find the one that is incorrectly referenced.

olygofren
  • 41
  • 1
  • 5