Content deleted Content added
Citation bot (talk | contribs) Alter: title. | Use this bot. Report bugs. | Suggested by BrownHairedGirl | #UCB_webform 2803/3838 |
|||
(4 intermediate revisions by 4 users not shown) | |||
Line 3:
{{Program execution}}
A '''memory debugger''' is a [[debugger]] for finding software memory problems such as [[memory leak]]s and [[buffer overflow]]s.
==Overview==
Memory debuggers work by monitoring memory access, allocations, and deallocation of memory. Many memory debuggers require applications to be recompiled with special dynamic memory allocation libraries, whose APIs are mostly compatible with conventional dynamic memory allocation libraries, or else use dynamic linking. [[Electric Fence]] is such a debugger which debugs memory allocation with [[malloc]]. Some memory debuggers (e.g. [[Valgrind]]) work by running the executable in a virtual machine-like environment, monitoring memory access, allocation and deallocation so that no recompilation with special memory allocation libraries is required.
Finding memory issues such as leaks can be extremely time
As abnormally high memory utilization can be a contributing factor in [[software aging]], memory debuggers can help programmers to avoid [[software anomaly|software anomalies]] that would exhaust the computer system memory, thus ensuring high reliability of the software even for long [[run time (program lifecycle phase)|runtimes]].
==Comparison to static analyzer==
Some [[List of tools for static code analysis|static analysis tools]] can also help find memory errors. Memory debuggers operate as part of an application while
==List of memory debugging tools==
Line 29:
| Linux, Mac OS
| Free/open source (LLVM)
| C, C++
| Compile-time instrumentation (available in [[Clang]] and [[GNU Compiler Collection|GCC]]) and specialized library
|-
Line 76:
| [[dmalloc]]
| {{Any}}
| Free/open source ([[ISC License]])
| C
| Compile-time override
Line 116:
| Runtime
|-
|
| Linux (gcc)
| Free/open source
Line 165:
|-
| {{section link|Valgrind|Memcheck}}
| Linux, FreeBSD, Solaris/illumos, Mac OS, Android
| {{GPL-lic|Free/open source (GPL)}}
| {{Any}}
|