Logic-Based Program Synthesis and Transformation - 23rd International Symposium, LOPSTR 2013, Madrid, Spain, September 18-19, 2013, Revised Selected Papers

Logic-Based Program Synthesis and Transformation - 23rd International Symposium, LOPSTR 2013, Madrid, Spain, September 18-19, 2013, Revised Selected Papers
复制标题

基于逻辑的程序综合与转换 - 第 23 届国际研讨会,LOPSTR 2013,西班牙马德里,2013 年 9 月 18-19 日,修订后的精选论文

DOI:
10.1007/978-3-319-14125-1_13
复制
发表时间:
2014
期刊:
--
影响因子:
--
通讯作者:
Bach Poulsen C
Bach Poulsen C
中科院分区:
--
文献类型:
--
作者:
Bach Poulsen C

文献摘要

相似文献

模块化结构操作语义(MSOS)是结构操作语义(SOS)的一个变体。它允许语言结构被独立指定,这样,没有重新制定现有的规则在MSOS规范是必需的,当一种语言扩展了新的结构和feature.Introducing的Prolog MSOS工具,我们回顾如何合成可执行的解释器从小步MSOS规范编译MSOS规则到Prolog子句。实现编译后的小步长规则的传递闭包给出了Prolog中的可执行解释器。在最坏的情况下,这样的解释器遍历每个中间程序项在其全部深度,导致在每一步的显着overhead.We展示了如何转换成相应的大步规范,通过两步的专业化的小步骤MSOS规范通过内部化的规则,实现在MSOS和“重新聚焦”的小步骤规则的传递闭包。专门的规范导致生成的解释器显着减少了解释开销。
Modular Structural Operational Semantics (MSOS) is a variant of Structural Operational Semantics (SOS). It allows language constructs to be specified independently, such that no reformulation of existing rules in an MSOS specification is required when a language is extended with new constructs and features.Introducing the Prolog MSOS Tool, we recall how to synthesize executable interpreters from small-step MSOS specifications by compiling MSOS rules into Prolog clauses. Implementing the transitive closure of compiled small-step rules gives an executable interpreter in Prolog. In the worst case, such interpreters traverse each intermediate program term in its full depth, resulting in a significant overhead in each step.We show how to transform small-step MSOS specifications into corresponding big-step specifications via a two-step specialization by internalizing the rules implementing the transitive closure in MSOS and ‘refocusing’ the small-step rules. Specialized specifications result in generated interpreters with significantly reduced interpretive overhead.