What is the best way to see memory leaks or areas to optimize code in your .net source code? I am using vs2005, c# , .net 2.0
Any good free tools out there that I can safely install on my work desktop?
What is the best way to see memory leaks or areas to optimize code in your .net source code? I am using vs2005, c# , .net 2.0
Any good free tools out there that I can safely install on my work desktop?
CLR Profiler can help you troubleshoot memory issues. Beware, though, the learning curve is pretty steep.
I never had to worry about memory leaks in my .net applications. You have to worry about system resources such as timers, file handles, comm port handles, database connections etc but again if you stick with right pattern (using?), they are not a problem either.
When it comes to optimization, you need to profile your application to see the performance bottlenecks. Don't even rely on your instincts when you are hunting a slow code because you might be looking at the wrong place.
AQTime, Ants profiler are good options but they are not free. They come with a trial period though so if you need them for a short period, you might get away with using them for trial period only. But if you really like them, you can consider buying them.
Or you can consider a free alternative EQATEC Profiler which seems pretty good but I haven't personally used it.
I don't know of any good C# memory profilers, besides the functionality built into Visual Studios. But a great commercial memory profiler is ANTS Memory Profiler($495)
I've been extensively using the dotTrace profiler from JetBrains (the makers of another invaluable tool, ReSharper). Its fairly lightweight and works well for tracking both memory utilization and standard application profiling.