Simple Generation of Static Single-Assignment Form

The static single-assignment (SSA) form of a program provides data flow information in a form which makes some compiler optimizations easy to perform. In this paper we present a new, simple method for convertingto SSA form, which produces correct solutions for nonreducible control-flow graphs, and produces minimal solutions for reducible ones. Our timing results show that, despite its simplicity, our algorithm is competitive with more established techniques.

[1]  Jong-Deok Choi,et al.  Automatic construction of sparse data flow evaluation graphs , 1991, POPL '91.

[2]  Andrew W. Appel,et al.  Modern Compiler Implementation in Java , 1997 .

[3]  Bowen Alpern,et al.  Detecting equality of variables in programs , 1988, POPL '88.

[4]  Raymond Lo,et al.  A new algorithm for partial redundancy elimination based on SSA form , 1997, PLDI '97.

[5]  Ron Cytron,et al.  Code motion of control structures in high-level languages , 1986, POPL '86.

[6]  Matthew S. Hecht,et al.  Flow Analysis of Computer Programs , 1977 .

[7]  Donald Ervin Knuth,et al.  The Art of Computer Programming , 1968 .

[8]  Alfred V. Aho,et al.  Code optimization and finite church-rosser systems , 1971 .

[9]  Ron K. Cytron,et al.  Efficiently computing φ-nodes on-the-fly , 1993 .

[10]  Steven S. Muchnick,et al.  Advanced Compiler Design and Implementation , 1997 .

[11]  Keshav Pingali,et al.  The program structure tree: computing control regions in linear time , 1994, PLDI '94.

[12]  Jeffrey D. Ullman,et al.  Set Merging Algorithms , 1973, SIAM J. Comput..

[13]  Robert E. Tarjan,et al.  Efficiency of a Good But Not Linear Set Union Algorithm , 1972, JACM.

[14]  M. Wegman,et al.  Global value numbers and redundant computations , 1988, POPL '88.

[15]  Mark N. Wegman,et al.  Efficiently computing static single assignment form and the control dependence graph , 1991, TOPL.

[16]  C. Robert Morgan,et al.  Building an Optimizing Compiler , 1998 .

[17]  Mark N. Wegman,et al.  Constant propagation with conditional branches , 1985, POPL.

[18]  Hanspeter Mössenböck,et al.  Single-pass generation of static single-assignment form for structured languages , 1994, TOPL.

[19]  Jeffrey D. Ullman,et al.  Flow Graph Reducibility , 1972, SIAM J. Comput..

[20]  Donald E. Knuth,et al.  The Art of Computer Programming, Volume I: Fundamental Algorithms, 2nd Edition , 1997 .

[21]  Donald E. Knuth,et al.  An empirical study of FORTRAN programs , 1971, Softw. Pract. Exp..

[22]  Robert M. Shapiro,et al.  THE REPRESENTATION OF ALGORITHMS , 1969 .

[23]  Andrew W. Appel,et al.  SSA is functional programming , 1998, SIGP.

[24]  Guang R. Gao,et al.  A linear time algorithm for placing φ-nodes , 1995, POPL '95.

[25]  Michael J. Fischer,et al.  Efficiency of Equivalence Algorithms , 1972, Complexity of Computer Computations.