哪个是分析内存并处理本机(c ++)win32服务中泄漏的最佳工具? [英] Which is the best tool to analyse memory and handle leaks in a native (c++) win32 service?

查看:58
本文介绍了哪个是分析内存并处理本机(c ++)win32服务中泄漏的最佳工具?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,
除了Rational Purifier之外,他们是否有任何(免费或完整评估)工具来分析我的Win32本机服务中的内存泄漏?

Hi all,
Other than rational purifier, is their any (free or fully evaluating) tool to analyze memory leaks in my win32 native service?

推荐答案

以上所有好的答案...

如果可以在调试器中以_DEBUG模式运行服务,只需在#include语句后的每个.cpp文件中添加以下定义.

All good answers above...

If you can run your service in the debugger in _DEBUG mode, simply put the following define in each of your .cpp files after the #include statements.

#ifdef _DEBUG
#define new DEBUG_NEW
#endif



然后调试器将列出退出时的所有泄漏,并为您分配内存的位置.



Then the debugger will list all of your leaks on exit, and give you the location where the memory was allocated.


Bounds Checker是我使用的一个很棒的工具-DevPartner for Visual C ++ BoundsChecker Suite [
Bounds Checker is a great tool that I have used - DevPartner for Visual C++ BoundsChecker Suite[^]


我认为Rational Purify是一个不错的选择,非常有用的工具
I think Rational Purify is a good option, very useful tool [^]


这篇关于哪个是分析内存并处理本机(c ++)win32服务中泄漏的最佳工具?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆