Comments
3 comments
-
That's great to hear the profiler has helped and thanks very much for sharing your tips!
-
Sorry for bringing up an old post, but I'm new to "ants" and generally memory leak investigation, are they any good up to date tutorials on what to look out for and how to change it as well as understanding all the information ANTS gives us?
-
Hi @Harag
Thanks for your post.
You can get more information on this part of the process and related info in my links below.
https://documentation.red-gate.com/amp8/understanding-memory-problems
https://documentation.red-gate.com/amp8/strategies-for-memory-profiling
The you can check to see if it is fixed using this one:
https://documentation.red-gate.com/amp8/strategies-for-memory-profiling/checking-managed-memory-usage/checking-that-a-memory-leak-is-fixed
I hope this is helpful to you.
Add comment
Please sign in to leave a comment.
I have a few of these WinForms leaks under my belt now and thought I'd share my lessons learned:
* I know this is no great insight, but static events are the root of many managed leaks. Be very suspicious of them when debugging.
* When working in a WinForms application, watch objects of type System.Windows.Forms.PropertyStore. They are used heavily in the WinForms code and almost anything that you leak in WinForms will show as a large number of PropertyStore objects leaking. You can follow their retention graph up to the culprit in your code.
* You can really effectively narrow down your problem by varying your "steps to reproduce" and watching what happens in ANTS. I found a key clue by disabling an option in our application. I disabled the option, re-ran the steps and, no leak.
HTH somebody.