CS1621
Assignment 3
Due: November 3, 2003
You are to implement a system which does analysis of a program and
provides information about the characteristics of the variables.
As you debug an application, there are many things that you may want
to know about such as if a variable is an actual constant (or an
effective constant where it is assigned one and one time only). A
variable may also only ever contain a non-computed value. You
may want to know if a variable may be used before initialized or has a
path through a program where it can be used before initialized. You
may want to know about variables that are assigned but never used.
A C compiler front end is available in
/afs/pitt.edu/usr/bigrigg/public/cs1621/proj3. It takes in a C source
file, performes lexical and syntax analysis on it (no semantic
analysis), puts the program into an internal syntax tree, and then
outputs an equivalent C program. Additional information on the
internal syntax tree is provided here. You are to create a SEPARATE
PASS to determine each set of variables.
PROJECT HELP