如何在Visual Studio 2010中分析程序的内存使用情况? [英] How to analyse program's memory usage in Visual Studio 2010?
问题描述
有没有一种方法可以检查在VS 2010中编码的程序中已分配了哪些内存? 我一直在注意,我最近制作的一个程序随着时间的推移不断使用越来越多的内存,而没有释放任何内存.
Is there a way to check what memory has been allocated to in a program coded in VS 2010? I've been noticing that a recent program I've been making keeps using more and more memory over time without releasing any.
此外,是否有任何有关代码设计的文章可以教您良好的内存管理?我似乎在Google上搜索了错误的字词,因为我不断收到无用的结果.
Also, are there any articles on code design that teaches you good memory management? I seem to be searching the wrong terms on google as I keep getting useless results.
推荐答案
有一些商业工具,例如 ANTS Memory Profiler 或 .NET Memory Profiler 或此MSDN文章.最后,毛尼·史蒂芬斯(Maoni Stephens)在.NET中有很多关于垃圾收集和内存管理的博客文章.它们都链接
There are commercial tools such as ANTS Memory Profiler or .NET Memory Profiler or dotTrace. Secondly, take a look at this MSDN article. Lastly, Maoni Stephens has many blog posts on garbage collection and memory management in .NET. They are all linked here.
这篇关于如何在Visual Studio 2010中分析程序的内存使用情况?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!