Abstract
Higher-order assembly language (HOAL) generalizes combinator-based target languages by allowing free variables in terms to play the role of registers. We introduce a machine model for which HOAL is the assembly language, and prove the correctness of a compiler from a tiny language into HOAL. We introduce the notion of a λ-representation, which is an abstract binding operation, show how some common representations of procedures and continuations can be expressed as λ-representations. Last, we prove the correctness of a typical procedure-calling convention in this framework.
Work supported by the National Science Foundation and DARPA under grant numbers CCR-8801591, CCR-9002253, and CCR-9014603.
Preview
Unable to display preview. Download preview PDF.
References
Appel, A.W., and Jim, T., “Continuation-Passing, Closure-Passing Style,” Conf. Rec. 16th ACM Symp. on Principles of Programming Languages (1989), 293–302.
Barendregt, H.P. The Lambda Calculus: Its Syntax and Semantics, North-Holland, Amsterdam, 1981.
Boyer, R.S., and Moore, J S. “The Sharing of Structure in Theorem-Proving Programs,” in Machine Intelligence 7 (B. Meltzer & D. Michie, eds), Edinburgh University Press (1972), 101–116.
Church, A. “A formulation of the simple theory of types,” J. of Symbolic Logic 5 (1940), 56–68.
Clinger, W. “The Scheme 311 Compiler: An Exercise in Denotational Semantics,” Conf. Rec. 1984 ACM Symposium on Lisp and Functional Programming (August, 1984), 356–364.
Hannan, J. “Making Abstract Machines Less Abstract,” Proc. 1991 ACM Conf. on Functional Programming, Languages, and Architectures, to appear.
Kelsey, R., and Hudak, P. “Realistic Compilation by Program Transformation,” Conf. Rec. 16th Ann. ACM Symp. on Principles of Programming Languages (1989), 281–292.
Meyer, A.R. “What Is a Model of the Lambda Calculus?” Information and Control 52 (1982), 87–122.
Meyer, A.R., and Wand, M. “Continuation Semantics in Typed Lambda-Calculi,” Logics of Programs (Brooklyn, June, 1985) (R. Parikh, ed.) Springer Lecture Notes in Computer Science, vol. 193 (1985), pp. 219–224.
Mitchell, J.C. “Representation Independence and Data Abstraction,” Proc. 13th ACM Symp. on Princ. of Programming Languages (1986), 263–276.
Pfenning, F., and Elliott, C, “Higher-Order Abstract Syntax,” Proc. SIGPLAN '88 Conf. on Prog. Lang. Design and Implementation, (June, 1988), 199–208.
Plotkin, G.D. “Call-by-Name, Call-by-Value and the λ-Calculus,” Theoret. Comp. Sci. 1 (1975) 125–159.
Schmidt, D.A. “Detecting Global Variables in Denotational Semantics,” ACM TOPLAS 7 (1985) 299–310.
Sethi, R. “Control Flow Aspects of Semantics-Directed Compiling” ACM Trans. on Prog. Lang. and Sys. 5 (1983) 554–596.
Stoy, J.E. “The Congruence of Two Programming Language Definitions,” Theoret. Comp. Sci. 13 (1981), 151–174.
Turner, D.A. “A New Implementation Technique for Applicative Languages,” Software-Practice and Experience 9 (1979), 31–49.
Wand, M. “Semantics-Directed Machine Architecture” Conf. Rec. 9th ACM Symp. on Principles of Prog. Lang. (1982), 234–241.
Wand, M. “Deriving Target Code as a Representation of Continuation Semantics” ACM Trans. on Prog. Lang. and Systems 4, 3 (July, 1982) 496–517.
Wand, M. “Loops in Combinator-Based Compilers,” Conf. Rec. 10th ACM Symposium on Principles of Programming Languages (1983), 190–196.
Wand, M. “Embedding Type Structure in Semantics” Conf. Rec. 12th ACM Symp. on Principles of Prog. Lang. (1985), 1–6.
Wand, M. “A Short Proof of the Lexical Addressing Algorithm,” Information Processing Letters 35 (1990), 1–5.
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 1992 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Wand, M. (1992). Correctness of procedure representations in higher-order assembly language. In: Brookes, S., Main, M., Melton, A., Mislove, M., Schmidt, D. (eds) Mathematical Foundations of Programming Semantics. MFPS 1991. Lecture Notes in Computer Science, vol 598. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-55511-0_15
Download citation
DOI: https://doi.org/10.1007/3-540-55511-0_15
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-55511-7
Online ISBN: 978-3-540-47194-3
eBook Packages: Springer Book Archive