Deriving a compiler from an operational semantics written in VDL |
| |
Authors: | Shahrzade Mazaher Daniel M Berry |
| |
Affiliation: | Computer Science Department, University of California, Los Angeles, CA 90024, U.S.A. |
| |
Abstract: | This paper addresses the issue of compiler correctness. The approach taken is to systematically construct a correct compiler for a language from a formal semantic definition of the language. For this purpose, an operational semantics of a language is chosen as the basis for the approach. That is, the compiler for a language is derived from an interpreter of the language. The derivation process uses the notion of mixed computation proposed by Ershov. Briefly stated, one begins interpreting and when a primitive state changing instruction is about to be executed, the instruction is emitted as code instead. The correctness of all compilers produced by the method is guaranteed by proving the derivation rules correct. This proof is a one-time task for each specification language. The specification language studied in this paper is the Vienna Definition Language (VDL). The object code generated by the compiler is in an intermediate language close to an assembly language. Therefore, the translation from the intermediate language into the assembly language should be straightforward. |
| |
Keywords: | Compilers Compiler Correctness Compiler Generation Operational Semantics VDL |
本文献已被 ScienceDirect 等数据库收录! |
|