Semantic foundations for typed assembly languages
Open Access
- 16 March 2010
- journal article
- research article
- Published by Association for Computing Machinery (ACM) in ACM Transactions on Programming Languages and Systems
- Vol. 32 (3) , 1-67
Abstract
Typed Assembly Languages (TALs) are used to validate the safety of machine-language programs. The Foundational Proof-Carrying Code project seeks to verify the soundness of TALs using the smallest possible set of axioms: the axioms of a suitably expressive logic plus a specification of machine semantics. This article proposes general semantic foundations that permit modular proofs of the soundness of TALs. These semantic foundations include Typed Machine Language (TML), a type theory for specifying properties of low-level data with powerful and orthogonal type constructors, and L c , a compositional logic for specifying properties of machine instructions with simplified reasoning about unstructured control flow. Both of these components, whose semantics we specify using higher-order logic, are useful for proving the soundness of TALs. We demonstrate this by using TML and L c to verify the soundness of a low-level, typed assembly language, LTAL, which is the target of our core-ML-to-sparc compiler. To prove the soundness of the TML type system we have successfully applied a new approach, that of step-indexed logical relations . This approach provides the first semantic model for a type system with updatable references to values of impredicative quantified types. Both impredicative polymorphism and mutable references are essential when representing function closures in compilers with typed closure conversion, or when compiling objects to simpler typed primitives.Keywords
Funding Information
- ARDA (NBCHC030106)
- Defense Advanced Research Projects Agency (F30602-99-1-0519)
- National Science Foundation (CCR-9974553CCR-0208601CCF-0540914)
- Division of Computing and Communication Foundations (CCR-9974553CCR-0208601CCF-0540914)
This publication has 54 references indexed in Scilit:
- On equivalence and canonical forms in the LF type theoryACM Transactions on Computational Logic, 2005
- Stack-based typed assembly languageJournal of Functional Programming, 2002
- An indexed model of recursive types for foundational proof-carrying codeACM Transactions on Programming Languages and Systems, 2001
- Parametric polymorphism and operational equivalenceMathematical Structures in Computer Science, 2000
- From system F to typed assembly languageACM Transactions on Programming Languages and Systems, 1999
- Relational interpretations of recursive types in an operational setting (Summary)1997
- A simplified account of polymorphic referencesInformation Processing Letters, 1994
- A critique of the foundations of Hoare style programming logicsCommunications of the ACM, 1982
- Intensional interpretations of functionals of finite type IThe Journal of Symbolic Logic, 1967
- A formulation of the simple theory of typesThe Journal of Symbolic Logic, 1940