Abstract
Flow analyses of untyped higher-order functional programs have in the past decade been presented by Ayers, Bondorf, Consel, Jones, Heintze, Sestoft, Shivers, Steckler, Wand, and others. The analyses are usually defined as abstract interpretations and are used for rather different tasks such as type recovery, globalization, and binding-time analysis. The analyses all contain a global closure analysis that computes information about higher-order control-flow. Sestoft proved in 1989 and 1991 that closure analysis is correct with respect to call-by-name and call-by-value semantics, but it remained open if correctness holds for arbitrary beta-reduction.
This article answers the question; both closure analysis and others are correct with respect to arbitrary beta-reduction. We also prove a subject-reduction result: closure information is still valid after beta-reduction. The core of our proof technique is to define closure analysis using a constraint system. The constraint system is equivalent to the closure analysis of Bondorf, which in turn is based on Sestoft's.
- AGESEN, O., PALSBERG, J., AND SCHWARTZBACH, M. I. 1993. Type inference of Self: Analysis of objects with dynamic and multiple inheritance. In Proceedings of ECOOP'93, 7th European Conference on Ob3ect-Omented Programming. Lecture Notes in Computer Science, vol. 707. Springer-Verlag, New York, 247-267. Google Scholar
- AYERS, A. 1992. Efficient closure analysis with reachability. In Proceedzngs of WSA '92, Analyse Statique. IRISA, Rennes, France, 126-134.Google Scholar
- BARENDREGT, H. P. 1981. The Lambda Calculus: Its Syntax and Semantics. North-HoIland, Amsterdam.Google Scholar
- BONDORF, A. 1993. Similix 5.0 Manual. DIKU, University of Copenhagen, Denmark. Included in Similix 5.0 distribution.Google Scholar
- BONDORF, A. 1991. Automatic autoprojection of higher order recursive equations. Sci. Comput. Program. 17, 1-3 (Dec.), 3-34. Google Scholar
- BONDORF, A. AND DANVY, 0. 1991. Automatic autoprojection of recursive equations with global variables and abstract data types. Sci. Comput. Program. 16, 151-195. Google Scholar
- BONDORF, A. AND JOaGENSEN, J. 1993. Efficient analyses for realistic off-line partial evaluation. J. Func~wnal Program. 3, 3, 315-346.Google Scholar
- CONSEL, C. 1990. Binding time analysis for higher order untyped functional languages. In Proceedings of the A CM Conference on Lisp and Functional Programming. ACM, New York, 264-272. Google Scholar
- GIANNINI, P. AND ROCCA, S. R. D. 1988. Characterization of typings in polymorphic type discipline. In Proceedings of LICS'88, 3rd Annual Symposium on Logic in Computer Science. IEEE, New York, 61-70.Google Scholar
- HEINTZE, N. 1994. Set-based analysis of ML programs. In Proceedings of the A CM Conference on LISP and Functional Programming. ACM, New York, 306-317. Google Scholar
- HEINTZE, N. 1992. Set based program analysis. Ph.D. thesis, CMU-CS-92-201, Carnegie Mellon University~ Pittsburgh, Pa. Google Scholar
- JONES, N. D. 1981. Flow analysis of lambda expressions. In Proceedings of the 8th Colloquium on Automata, Languages, and Programming. Lecture Notes in Computer Science, vol. 115. Springer-Verlag, New York, 114-128. Google Scholar
- PALSBERG, J. 1993. Correctness of binding-time analysis. J. Functional Program. 3, 3,347-363.Google Scholar
- PALSBERG, J. AND SCHWARTZBACH, M. I. 1994a. Binding-time analysis: Abstract interpretation versus type inference. In Proceedzngs of ICCL '9~, 5th IEEE International Conference on Computer Languages. IEEE, New York, 289-298.Google Scholar
- PALSBERG, J. AND SCHWARTZBACH, M. I. 1994b. Object-Oriented Type Systems. John Wiley and Sons, New York. Google Scholar
- PALSBERG, J. AND SCHWARTZBACH, ~{. I. 1992a. Safety analysis versus type inference. Inf. Comput. To be published. Google Scholar
- PALSBERG, J. AND SCHWARTZBACH, M. I. 1992b. Safety analysis versus type inference for partial types. Inf. Process. Left. ~3, 175-180. Google Scholar
- PALSBERG, J. AND SCHWARTZBACH, M. I. 1991. Object-oriented type inference. In Proceedings of OOPSLA '91, A CM SIGPLAN 6th Annual Conference on Object-Oriented Programming Systems, Languages and Applications. ACM, New York, 146-161. Google Scholar
- SESTOFT, P. 1991. Analysis and efficient implementation of functional programs. Ph.D. thesis, DIKU, University of Copenhagen.Google Scholar
- SESTOFT, P. 1989. Replacing function parameters by global variables. M.S. thesis, DIKU, University of Copenhagen.Google Scholar
- SmvErtS, O. 1991a. Control-flow analysis of higher-order languages. Ph.D. thesis, CMU-CS- 91-145, Carnegie Mellon University, Pittsburgh, Pa.Google Scholar
- SHIVERS~ O. 1991b. Data-flow analysis and type recovery in Scheme. In Topics in Advanced Language Implementation, P. Lee, Ed. MIT Press, Cambridge, Mass., 47-87.Google Scholar
- UNGAR, D. AND SMITH, R. B. 1987. SELF: The power of simplicity. In Proceedzngs of OOP- SLA '87, Object-Oriented Programming Systems, Languages and Applications. ACM, New York, 227-241. Also published in Lisp and Symbolic Computation 4(3), Kluwer Acadamic Publishers, June 1991. Google Scholar
- WAND, M. AND STECKLER, P. 1994. Selective and lightweight closure conversion. In Proceedings of POPL'94, 21st Annual Symposium on Principles of Programming Languages. ACM, New York, 434-445. Google Scholar
Index Terms
- Closure analysis in constraint form
Recommendations
Logic programs with monotone abstract constraint atoms*
We introduce and study logic programs whose clauses are built out of monotone constraint atoms. We show that the operational concept of the one-step provability operator generalizes to programs with monotone constraint atoms, but the generalization ...
On the freeze quantifier in Constraint LTL: Decidability and complexity
Constraint LTL, a generalisation of LTL over Presburger constraints, is often used as a formal language to specify the behavior of operational models with constraints. The freeze quantifier can be part of the language, as in some real-time logics, but ...
Implementing a fixed point semantics for a constraint deductive database based on hereditary harrop formulas
PPDP '09: Proceedings of the 11th ACM SIGPLAN conference on Principles and practice of declarative programmingThis work is aimed to show a concrete implementation of a deductive database system based on the scheme HH_(C) (Hereditary Harrop Formulas with Negation and Constraints) following a fixpoint semantics proposed in a previous work. We have developed a ...
Comments