posted on Sunday, December 18, 2005 4:23 PM by Jonathan Hodgson

.NET memory and performance profilers

I've talked before about memory consumption in managed applications and recently learn about .NET Memory Profiler from Scitech software.

Described as:

Allowing you to retrieve information about all instance allocations performed on the garbage collected heap (GC heap) and all instances that reside on the GC heap. The retrieved information is presented in real-time, both numerically and graphically.

The real-time information presented gives a good overview of the activity and status of the GC heap, but by collecting snapshots of the heap, very detailed information can be presented. A heap snapshot can optionally include the instance data of each instance on the heap, allowing the presentation of field values of instances. It is also possible to compare two snapshots, which is a very convenient and efficient way of detecting memory leaks in a program. A snapshot provides in formation about: all classes, all instances of classes, the call stacks of the instance allocations, the path to a root from each instance.

The profiler also contains a dispose tracker, which provides additional data about disposable instances (i.e. instances of classes implementing the System.IDisposable interface).

The new .NET Memory Profiler API makes it possible to automatically detect memory leaks and control the profiler from within the profiled program.

Remember when Rational Purify and Quantify ruled in the unmanaged profiling world, now we have Red-Gate ANTS, JetBrains dotTrace, AutomatedQA AQTime and Microsoft CLR Profiler, not forgetting Compuware DevPartnerIBM Rational PurifyPlus or Visual Studio Team Suite if your budget can stretch.

Couple of nice video demos of JetBrains Reshaper and dotTrace if you haven't come across them before.

Also good paper on C# threading from Microsoft Research and the latest patterns and practices book on Designing Web Service Security with some interesting diagrams showing different ways to flow security credentials.

Comments