An automatic programming approach to high level program monitoring and measuring

Yingsha Liao · University of Southern California Digital Library · 2017

Program monitoring and measuring (PMM) is the activity of collecting empirical data of a program's execution to answer questions about the program's performance. PMM is usually done by altering the program to collect interesting data as it runs. Unfortunately, this is itself an arduous task involving all the difficulties of program construction and maintenance. Generally there are three tasks involved in altering the program to answer performance questions: determining what data has to be collected, determining where in the program that data can be collected, and adding code to the program to collect that data and to process it to produce the desired results. As programs become larger and as the computational structures employed by languages become more complicated, performing those tasks becomes a challenge for human programmers. This dissertation presents a system that automates each of these tasks. Its input is a high level specification of PMM questions and the source program. Its output is an augmented version of the program whose execution produces both the results of the original program and the answers to the PMM questions. This system has proved to be very effective. It exploits several techniques not previously used. First, PMM questions are specified in a specification language that facilitates both question specification and automatic program augmentation. The language is based on an Entity-Relationship model and a set of programming language dependent primitives that enables the relevant data to be collected to be determined from the primitives used in the questions. Determining where to insert instrumentation is done by relating run time program behaviors with the source program constructs that produce that behavior and a static analysis which locates those program constructs in the source program. Adding code to collect that data can be done efficiently via instantiating generic instrumentation templates associated with each of the programming language primitives. Second, the instrumentation for computing the answers to the questions is constructed automatically by filtering, combining and merging the data collected by these primitive templates using the formalism and power of a relational query processor. Finally, to minimize the collection of extraneous data, static analysis is used to filter out irrelevant Sites at compile time and temporal analysis is used to filter out data at run time. (Copies available exclusively from Micrographics Department, Doheny Library, USC, Los Angeles, CA 90089-0182.)

Read the paper · More papers on PaperTik