Heap Damage Detection Tool for C ++

Is there any tool helping me detect heap corruption in C ++? I can not provide the source code because it is a big project. I can use any tool that works with Visual Studio or using xcode. The tool should work fine with multithreading. The problem is not very common, it appears after a long time and only in very special cases (they were not detected exactly!).

Thanks!

EDIT:

Thank you all for your answers! I will test the tools and I will accept one answer after the tests.

+4
source share
4 answers

Valgrind is a defacto tool for executing memory tools for native code. It, however, does not work on Windows (OS X is fine).

There are several commercial tools that work on Windows, and although they have a graphical interface, in my opinion they are inferior to Valgrind.

+8
source

Debugging tools for Windows include gflags and a bunch of pages that help detect heap corruption.

+5
source

On Mac OS X (I suppose this is what you mean when you say Xcode), you already have a whole bunch of tools for debugging memory, for example. http://developer.apple.com/library/mac/#releasenotes/DeveloperTools/RN-MallocOptions/index.html , which allows you to enable heap validation through environment variables.

+2
source

On Windows use Application Verifier

+1
source

Source: https://habr.com/ru/post/1335516/


All Articles