现在,如何计算Malloc呼叫数量,因为Malloc钩子已经消失了。 (Ubuntu Linux)
我想计算一个大型C ++项目中的Malloc呼叫数量。
- 我尝试了malloc钩,但得知它们被删除了。
- Valgrind Massif告诉我分配了多少内存,但我不是对Malloc的电话数量。还是有一种方法可以获取这些数据?
- 我可以预加载一个替代Malloc的库。但是我真的找不到有关如何准确执行此操作的教程。
任何快速简便的方法来计算Malloc呼叫的数量,都将不胜感激!
I would like the count the number of malloc calls in a large C++ project.
- I tried malloc hooks but learned that they were removed.
- Valgrind Massif tells me how much memory is allocated but I not the number of calls to malloc. Or is there a way to get this data?
- I could preload a library which replaces malloc. But I could not really find a tutorial on how to do this exactly.
Any quick and easy approach to counting the number of malloc calls would be appreciated!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论