Heapy: A Memory Profiler and Debugger for Python
Independent thesis Basic level (professional degree), 20 points / 30 hpStudent thesis
Excessive memory use may cause severe performance problems and system crashes. Without appropriate tools, it may be difficult or impossible to determine why a program is using too much memory. This applies even though Python provides automatic memory management --- garbage collection can help avoid many memory allocation bugs, but only to a certain extent due to the lack of information during program execution. There is still a need for tools helping the programmer to understand the memory behaviour of programs, especially in complicated situations. The primary motivation for Heapy is that there has been a lack of such tools for Python.
The main questions addressed by Heapy are how much memory is used by objects, what are the objects of most interest for optimization purposes, and why are objects kept in memory. Memory leaks are often of special interest and may be found by comparing snapshots of the heap population taken at different times. Memory profiles, using different kinds of classifiers that may include retainer information, can provide quick overviews revealing optimization possibilities not thought of beforehand. Reference patterns and shortest reference paths provide different perspectives of object access patterns to help explain why objects are kept in memory.
Place, publisher, year, edition, pages
2006. , 75 p.
memory profiling, memory leaks, debugging, optimization, testing, quality assurance, Python
IdentifiersURN: urn:nbn:se:liu:diva-7247ISRN: LITH-IDA-EX--06/043--SEOAI: oai:DiVA.org:liu-7247DiVA: diva2:22287