Instrumentation of C programs for measuring test coverage

OData support
Dr. Majzik István
Department of Measurement and Information Systems

The standards for developing safety-critical system require the thorough code coverage of the developed tests. In my thesis, I summarize the major code coverage metrics and methods, I emphasize the method of measuring the coverage through the instrumentation of the source code, especially for embedded systems. I present the Coverage Analysis Tool for Embedded Systems (or CATES), a tool developed by the Fault Tolerant Systems Research Group at the Budapest University of Technology and Economics, which is trying to provide a solution to this problem.

I briefly summarize the history and the operation of the parser generators, especially the ANTLR (Another Tool for Language Recognition) parser generator. I review its structure, operation and usage in the CATES tool.

I summarize my work during the semester, during which I upgraded the ANTLR version used by CATES, while adapting the used grammar and instrumentation algorithm. Furthermore, I describe the way in which I modified the tool to be suitable for measuring code coverage of programs built from multiple source files.

I demonstrate the result of my work on two platforms: in a PC environment and on an Atmel ATMega8 microcontroller. I also tested the instrumentation of source codes of the ProSigma railway signaling equipment, developed by Prolan Zrt.


Please sign in to download the files of this thesis.