MiniValgrind: Simple Memory Leak Detector

  • Артем Михайлович Мухин SPbSU, St. Petersburg, Russia
  • Георгий Алексеевич Чернышев SPbSU, Saint-Petersburg, Russia
Keywords: introductory programming course, interpreter, memory leak detection

Abstract

In this paper, we describe an educational project for creating a memory leak detector for an interpreted language. This project is intended for a student or a group of second-year students. It was developed as an alternative form of classroom assignment in an introductory programming course. 
The statement of the problem, and the general outline of the project are described in the paper; the subtasks and methods for their solution are also discussed. All stages of the project are considered: language development, interpreter construction, implementation of the memory leak detector. In addition, the experience – obtained in the fall semester of 2016 – of applying this project in the educational process is described in the article. The project code is available from GitHub.

Author Biographies

Артем Михайлович Мухин, SPbSU, St. Petersburg, Russia

Artem M. Mukhin: second-year undergraduate student, Saint-Petersburg State University

Георгий Алексеевич Чернышев, SPbSU, Saint-Petersburg, Russia

George A. Chernishev: assistant professor of Department of Analytical Information Systems, Saint-Petersburg State University; 198504, SaintPetersburg, Peterhof, Universitetsky pr. 28, Department of Analytical Information Systems.

References

[1] Valgrind Home [Online], Available: http://valgrind.org/
[2] A. V. Aho, M. S. Lam, R. Sethi, and J. D. Ullman, Kompilyatory: printsipy, tekhnologii i instrumentarii [Compilers. Principles, Techniques, & Tools], Moscow, Russia: Williams, 2015 (in Russian).
[3] J. Levine, Flex & Bison, O’Reilly Media, 2009.
[4] G. A. Сhernishev, “Opyt provedeniya praktikumov po programmirovaniyu na matematiko-mekhanicheskom fakul'tete SPbGU” [Teaching Introductory Programming Course for Computer Programming Majors at the Department of Mathematics and Mechanics of Saint-Petersburg University], Computer tools in education journal, no. 6, pp. 43–66, 2015 (in Russian).
[5] E. Balakina, G. Chernishev, B. Novikov, A. Mukhin, G. Pervakov, K. Smirnov, A. Smirnova, and G. Zakharov, “Using Programming Contest in Teaching Introductory Programming Course: an Experience,” In Proc. of the 9th IEEE International Conference on UbiMedia Computing, Moscow, Russia, 2016, pp. 272–277.
[6] K. K. Smirnov and G. A. Сhernishev, “Uchastie v sorevnovanii ACM SIGMOD kak vozmozhnost' dlya studentov uglublenno izuchit' nekotorye aspekty baz dannykh i programmnoi inzhenerii” [ACM SIGMOD Programming Contest: an opportunity to study distinguished aspects of database systems and software engineering], Computer tools in education journal, no. 5, pp. 25–32, 2012 (in Russian).
[7] S. Miner, T. Pevzner, A. Deutsch, S. Baden, and P. Kube, “Building an XQuery Interpreter in a Compiler Construction Course,” SIGCSE Bull., vol. 37, no. 1, pp. 2–6, 2005. doi: 10.1145/1047344.1047363
[8] A. Sattar and T. Lorenzen, “Develop a Compiler in Java for a Compiler Design Course,” SIGCSE Bull., vol. 39, no. 2, pp. 80–82, 2007. doi: 10.1145/1272848.1272890
[9] D. Baldwin, “A Compiler for Teaching About Compilers,” SIGCSE Bull., vol. 35, no. 1, pp. 220–223, 2003. doi: 10.1145/611892.611974
[10] T. R. Henry, “Teaching Compiler Construction Using a Domain Specific Language,” SIGCSE Bull., vol. 37, no. 1, pp. 7–11, 2005. doi: 10.1145/1047344.1047364
[11] H. Luoma, E. Lahtinen, and H.-M. J’arvinen, “CLIP, a Command Line Interpreter for a Subset of C++,” In Proc. of the Seventh Baltic Sea Conference on Computing Education Research, Darlinghurst, Australia, vol. 88, 2007, pp. 199–202.
[12] A. N. Terekhov, “Instrumental'noe sredstvo obucheniya programmirovaniyu i tekhnike translyatsii” [Programming and compiler techniques educational tool], Computer tools in education journal, no. 1, pp. 36–47, 2015 (in Russian).
Published
2017-09-19
How to Cite
Мухин, А. М., & Чернышев, Г. А. (2017). MiniValgrind: Simple Memory Leak Detector. Computer Tools in Education, (2), 5-15. Retrieved from http://cte.eltech.ru/ojs/index.php/kio/article/view/1469
Section
Software Engineering