Summary
A criterion is developed to define a hierarchy of inner loops in a program which constitute sections of the program which take up large proportions of the execution time; this hierarchy lends a dynamic loop structure to the program. It is assumed that the program has been given a flowgraph representation in which each vertex corresponds to a statement or a set of statements and the flow in each edge corresponds to the frequency of passage of control from one statement or set of statements to another. While developing this criterion an attempt is made to guarantee that moving a loop invariant statement from an inner loop to a point outside of the loop would always yield a more optimal code.
Similar content being viewed by others
References
Allen, F.E.: Program optimization. Annual Review in Automatic Programming 5, pp. 239–307 (1969)
Allen, F.E., Cocke, J.: A catalogue of optimizing transformations. In: Design and optimization of compilers (R. Rustin, ed.), Prentice-Hall (1972)
Aho, A.V., Ulman, J.D.: Principles of compiler design. Addison Wesley (1978)
Ingalls, D.: FETE, a FORTRAN execution time estimator. In: Program style, design, efficiency, debugging and testing. Prentice Hall (1974)
Ingalls, D.: The execution time profile as a programming tool. In: Design and optimization of compilers (R. Rustin, ed.) Prentice-Hall (1972)
Knuth, D.E.: An empirical study of FORTRAN programs. Software practice and experience 1, 2, pp. 105–133 (1971)
Mont-Reynaud, B.: Hierarchical properties of flows and the determination of inner loops. Technical Report STAN-CS-77-644, Computer Science Department, Stanford University, Stanford, CA, USA (Ph. D. Thesis, December 1977)
Vasudevan, S.: Determination of the inner loops in flowgraphs — A New Criterion. Disertation report. Department of EECS, University of California, Berkley, USA
Venkataraman, K.N.: Some graph theoretical algorithms. Disertation report, Computer Centre, Indian Institute of Technology, Madras, India (1975)
Author information
Authors and Affiliations
Rights and permissions
About this article
Cite this article
Vasudevan, S. Inner loops in flowgraphs and code optimization. Acta Informatica 17, 143–155 (1982). https://doi.org/10.1007/BF00288967
Received:
Issue Date:
DOI: https://doi.org/10.1007/BF00288967