A memory leak and deadlock finder for C, C++
BugInsight is a tool for finding memory leaks and potential deadlocks in C/C++ software for Microsoft Windows OS.
Main reason for use is to test Windows applications that cannot be tested under Linux (e.g. with AddressSanitizer, ThreadSanitizer, Valgrind) and to test the Windows only parts of an application.
An other reason is the low overhead with I/O bound (e.g. TCP/IP) applications or Qt GUI applications. A real world test with a TCP/IP application shows a slowdown of 10 %, with option "--callstacks=false" only 5 %.
BugInsight can be used manually and automated in a CI system. BugInsight does not need to be linked and no rebuilding of the application is needed.
BugInsight.exe [Options] [Configuration] -- ["]application_to_test.exe["] [application_to_test options]
Examples:
BugInsight.exe example_memory_leak.exe
BugInsight.exe --on_error=fail -- example_deadlock.exe
BugInsight.exe --ignore_modules=libssl-3-x64.dll,libcrypto-3-x64.dll -- app.exe --app_option
Example output memory leak detection: Example_Output
Example output deadlock detection: Example_Output
Usage in VS debugger (the VS output window will display clickable call stacks):
BugInsight uses (improved) parts from Visual Leak Detector for memory leak finding. The deadlock detection algorithm is from the C++ library Abseil.
Finding memory leaks and wrong memory API usage e.g. delete, delete[] mismatch
Deadlock detection and detect wrong lock usage with CriticalSection and std::mutex, std::recursive_mutex
Test applications (or parts of it) that cannot be tested on Linux with ThreadSanitizer and AddressSanitizer
Test with the Windows operating system on which the program will later run
Test applications that run too slowly with other test tools
Lock watchdog: The time a lock is waiting for a lock or holding a lock is monitored and a log or error is created if a maximum time is exceeded
Periodic heap validation (_heapchk(), HeapValidate())
Test C/C++ DLLs loaded in a Java program ( Java Native Interfaces)
Test C/C++ DLLs loaded in a .Net program (P/Invoke)
BugInsight can detect leaks or deadlocks from the following APIs: Monitored APIs. Please report missing APIs.
BugInsight monitors all modules (Exe ,DLL) used by application under test excluding modules provided by Windows OS (DLLs with Copyright info: 'Microsoft Corporation', e.g. Kernel32.dll).
BugInsight does not yet monitor handle leaks.
Command Line Options
Runtime_API
BugInsight is licensed under the terms of the GNU General Public License v3.0 license. See LICENSE for more information.