Sciweavers

PLDI
2003
ACM

A practical flow-sensitive and context-sensitive C and C++ memory leak detector

14 years 4 months ago
A practical flow-sensitive and context-sensitive C and C++ memory leak detector
This paper presents a static analysis tool that can automatically find memory leaks and deletions of dangling pointers in large C and C++ applications. We have developed a type system to formalize a practical ownership model of memory management. In this model, every object is pointed to by one and only one owning pointer, which holds the exclusive right and obligation to either delete the object or to transfer the right to another owning pointer. In addition, a pointertyped class member field is required to either always or never own its pointee at public method boundaries. Programs satisfying this model do not leak memory or delete the same object more than once. We have also developed a flow-sensitive and context-sensitive algorithm to automatically infer the likely ownership interfaces of methods in a program. It identifies statements inconsistent with the model as sources of potential leaks or double deletes. The algorithm is sound with respect to a large subset of the C and ...
David L. Heine, Monica S. Lam
Added 05 Jul 2010
Updated 05 Jul 2010
Type Conference
Year 2003
Where PLDI
Authors David L. Heine, Monica S. Lam
Comments (0)