首页> 美国政府科技报告 >Run-time Code Generation and Modal-ML
【24h】

Run-time Code Generation and Modal-ML

机译:运行时代码生成和模态mL

获取原文

摘要

This paper presents early experience with a typed programming language andcompiler for runtime code generation. The language is an extension of the SML language with modal operators, based on the lambda(square) language of Davies and Pfenning. It allows programmers to specify precisely, through types, the stages of computation in a program. The compiler generates target code that makes use of runtime code generation in order to exploit the staging information. The target machine is currently a version of the Categorial Abstract Machine, called the CCAM, which we have extended with facilities for runtime code generation. Using this approach, the programmer is able to express the staging that he wants to the compiler directly. It also provides a typed framework in which to verify the correctness of his staging intentions, and to discuss his staging decisions with other programmers. Finally, it supports in a natural way multiple stages of runtime specialization, so that dynamically generated code can be used to generate yet further specialized code. This paper presents an overview of the language, with several examples of programs that illustrate key concepts and programming techniques. Then, it discusses the CCAM and the compilation of lambda(square) programs into CCAM code. Finally, the results of some experiments are shown, to demonstrate the benefits of this style of runtime code generation for some applications.

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号