A Memory Allocation Profiler for C and Lisp Programs
Benjamin G. Zorn, Paul N. Hilfinger · 1988
This paper describes mprof, a tool used to study the dynamic memory allocation behavior of programs. Mprof records the amount of memory that a function allocates, breaks down allocation information by type and size, and displays a program’s dynamic call graph so that functions indirectly responsible for memory allocation are easy to identify. Mprof is a two-phase tool. The monitor phase is linked into executing programs and records information each time memory is allocated. The display phase reduces the data generated by the monitor and presents the information to a user in several tables. Mprof has been implemented for C and Kyoto Common Lisp. Measurements of these implementations are presented. 1