Precise Interprocedural Dataflow Analysis with Applications to Constant Propagation

Mooly Sagiv, Thomas Reps, and Susan Horwitz
University of Wisconsin

This paper concerns interprocedural dataflow-analysis problems in which the dataflow information at a program point is represented by an environment (i.e., a mapping from symbols to values), and the effect of a program operation is represented by a distributive environment transformer. We present an efficient dynamic-programming algorithm that produces precise solutions.

The method is applied to solve precisely and efficiently two (decidable) variants of the interprocedural constant-propagation problem: copy constant propagation and linear constant propagation. The former interprets program statements of the form x := 7 and x := y. The latter also interprets statements of the form x := 5 * y + 17.

(Click here to access the paper: PostScript, PDF.)