Header menu link for other important links
X

Memory leak detection using Heap Object Flow Graph (HOFG)

Published in ACM
2024
Volume: 16
   
Pages: 1 - 11
Abstract

Unsafe programming languages like C/C++ lack efficient memory management module. A programmer is privileged to do explicit allocation and deallocation of heap memory blocks in C/C++ programming languages. Memory errors related to heap memory are difficult to capture using software testing in such programming languages. Program analysis can improve the reliability of software by identifying and repairing bugs related to dynamic memory management. An efficient static analyzer needs to look at the control flow graph of the whole program binary. Capturing context, path, and flow sensitivity is challenging using abstract interpretation and can lead to over approximated results. We propose Heap Object Flow Graph (HOFG), a program representation that eases program analysis to detect memory errors using static program analysis. An efficient program analysis on HOFG called HOFG-Analyser is defined, to capture memory leaks. We were able to detect memory leaks on different benchmarks written in C/C++ programming language with sizes up to 521K Lines of Code (LoC) with minimal false positive rates. Our experimental evaluation show that HOFG-Analyser is efficient and effective than an existing static analysis tool, INFER. In many cases, more number of leaks and less false positive rate is achieved by the HOFG-Analyser

About the journal
JournalInnovation in Software Engineering
PublisherACM
Open AccessNo