Abstract
This paper shows how the Improvement Theorem-a semantic condition for the total correctness of program transformation on higher-order functional programs-has practical value in proving the correctness of automatic techniques, including deforestation and supercompilation. This is aided by a novel formulation (and generalisation) of deforestation-like transformations, which also greatly adds to the modularity of the proof with respect to extensions to both the language and the transformation rules.
Chapter PDF
Similar content being viewed by others
Keywords
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.
References
S. Abramsky. The lazy lambda calculus. In Research Topics in Functional Programming. Addison Wesley, 1990.
R. Burstall and J. Darlington. A transformation system for developing recursive programs. JACM, 24:44–67, January 1977.
W. N. Chin. Automatic Methods for Program Transformation. PhD thesis, Imperial College, 1990.
C. Consel and S. Khoo. On-line and off-line partial evaluation: Semantic specification and correctness proofs. Tech. Report, Yale, April 1993.
B. Courcelle. Infinite trees in normal form and recursive equations having a unique solution. Math. Systems Theory, 13:131–180, 1979.
M. Felleisen, D. Friedman, and E. Kohlbecker. A syntactic theory of sequential control. TCS, 52:205–237, 1987.
A. Ferguson and P. Wadler. When will deforestation stop. In 1988 Glasgow Workshop on Functional Programming, Research Rep. 89/R4, 1988.
R. Glück and A. V. Klimov. Occam's razor in metacomputation: the notion of a perfect process tree. In Static Analysis Syposium, LNCS 724, 1993.
A. Gill, J. Launchbury, and S. Peyton Jones. A short cut to deforestation. In FPCA '93. ACM Press, 1993.
C. Gomard. A self-applicable partial evaluator for the lambda calculus: correctness and pragmatics. ACM TOPLAS, 14(2):147–172, 1992.
D. J. Howe. Equality in lazy computation systems. In 4th LICS. IEEE, 1989.
N. D. Jones, C. Gomard, and P. Sestoft. Partial Evaluation and Automatic Program Generation. Prentice-Hall, 1993.
J. Komorowski. An introduction to partial deduction. In Third Int. Workshop on Meta-Programming in Logic, LNCS 649, 1992.
L. Kott. About transformation system: A theoretical study. In B. Robinet, editor, Program Transformations. Dunod, 1978.
J. W. Lloyd and J. Shepherdson. Partial evaluation in logic programming. J. Logic Programming, 3–4(11), 1991.
S. Marlow and P. Wadler. Deforestation for higher-order functions. In Functional Programming, Glasgow 1992, Springer Workshop Series, 1992.
K. Nielsen and M. Heine Sørensen Deforestation, partial exaluation and evaluation orders. Unpublished, DIKU, Copenhagen, 1994.
J. Palsberg. Correctness of binding time analysis. J. Functional Programming, 3(3), 1993.
G. D. Plotkin. Call-by-name, Call-by-value and the λ-calculus. TCS, 1(1):125–159, 1975.
P. Partsch and R. Steinbruggen. Program transformation systems. Computing Surveys, 15:199–236, 1983.
D. Sands. Operational theories of improvement in functional languages (extended abstract). In Fourth Glasgow Workshop on Functional Programming, Springer Workshop Series, 1991.
D. Sands. Total correctness by local improvement in program transformation. In 22nd POPL. ACM Press, 1995.
D. Sands. Total correctness by local improvement in the transformation of functional programs. DIKU, University of Copenhagen, 48pages, January 1995.
T. Sheard and L. Fegaras. A fold for all seasons. In FPCA '93. ACM Press, 1993.
M. H. Sørensen, R. Glück, and N. D. Jones. Towards unifying partial evaluation, deforestation, supercompilation, and GPC. In ESOP'94. LNCS 788, Springer Verlag, 1994.
M H Sørensen. A grammar-based data-flow analysis to stop deforestation. In CAAP'94, LNCS 787, 1994.
M H Sørensen. Turchin's supercompiler revisited: An operational theory of positive information propagation. Master's thesis, DIKU, University of Copenhagen, (RR 94/9) 1994.
P. Steckler. Correct Higher-Order Program Transformations. PhD thesis, Northeastern University, Boston, 1994.
H. Tamaki and T. Sato. Unfold/fold transformation of logic programs. In 2nd Int. Logic Programming Conf., 1984.
V. F. Turchin. The concept of a supercompiler. To PLaS, 8:292–325, July 1986.
P. Wadler. The concatenate vanishes. University of Glasgow. Unpublished (preliminary version circulated on the fp mailing list, 1987), November 1989.
P. Wadler. Deforestation: transforming programs to eliminate trees. TCS, 73:231–248, 1990. (Preliminary version in ESOP 88, LNCS 300).
M. Wand. Specifying the correctness of binding time analysis. J. Functional Programming, 3(3), 1993.
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 1995 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Sands, D. (1995). Proving the correctness of recursion-based automatic program transformations. In: Mosses, P.D., Nielsen, M., Schwartzbach, M.I. (eds) TAPSOFT '95: Theory and Practice of Software Development. CAAP 1995. Lecture Notes in Computer Science, vol 915. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-59293-8_228
Download citation
DOI: https://doi.org/10.1007/3-540-59293-8_228
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-59293-8
Online ISBN: 978-3-540-49233-7
eBook Packages: Springer Book Archive