Abstract
If a procedure P is relatively nonrecursive with respect to a procedure Q, i.e., P is always preceded by Q in the calling graph of the program, then P does not need an activation record of its own — it can be integrated into that of Q. Thus, the efficiency of a call to P is between that of a strictly recursive and a nonrecursive one.
An algorithm is presented which classifies each procedure (or function) in a program as being either nonrecursive, relatively nonrecursive or strictly recursive (i.e., recursive but not relatively nonrecursive) and associates each relatively nonrecursive with a strictly recursive one.
The method is based on finding dominators in the (transformed) calling graph.
Preview
Unable to display preview. Download preview PDF.
7. References
Alfred V. Aho, Jeffrey D. Ullman: Principles of Compiler Design, Chapter 13, Addison-Wesley Publishing Company, third Printing, April 1979
Hans Langmaack: On Correct Procedure Parameter Passing in Higher Programming Languages Acta Informatica 2, 110–142 (1973)
R. Tarjan: Finding Dominators in Directed Graphs SIAM Journal of Comp., Vol.3, No.1, 62–89, March 1974
Kenneth G. Walter: Recursion Analysis for Compiler Optimization Communications of the ACM, September 1976, Volume 19, Number 9, 514–516
Karl Winklmann: On the Complexity of Some Problems Concerning the Use of Procedures. I. Acta Informatica 18, 299–318 (1982)
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 1985 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Armbruster, D. (1985). On the calling behaviour of procedures. In: Maheshwari, S.N. (eds) Foundations of Software Technology and Theoretical Computer Science. FSTTCS 1985. Lecture Notes in Computer Science, vol 206. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-16042-6_8
Download citation
DOI: https://doi.org/10.1007/3-540-16042-6_8
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-16042-7
Online ISBN: 978-3-540-39722-9
eBook Packages: Springer Book Archive