Compiling real time functional reactive programming

Dana N. Xu, Siau-Cheng Khoo
{"title":"Compiling real time functional reactive programming","authors":"Dana N. Xu, Siau-Cheng Khoo","doi":"10.1145/568173.568183","DOIUrl":null,"url":null,"abstract":"Most of the past languages for reactive systems are based on synchronous dataflow. Recently, a new reactive language, called Real-Time Functional Reactive Programming (RT-FRP) [18] , has been proposed based on the functional paradigm. The unique feature of this language is the high-level abstraction provided in the form of behaviors for conti-nuous-time signals, and events for discrete-time signals. RT-FRP also features some performance guarantees in the form of bounded runtime and space usage for each reactive computation step.In this paper, we propose a new compilation scheme for RT-FRP. Our compilation scheme is based on two key stages. In the first stage, we translate RT-FRP program to an intermediate functional code. This code is deliberately kept at high level for two reasons. First, it is easier for us to validate its correctness. Second, it allows us to apply high-level source-to-source transformation to achieve further optimization. The second stage attempts to compile the intermediate code to a corresponding automata code. Our main novelty is the use of two high-level transformation techniques for this compilation. The first technique, partial evaluation, attempts to propagate constant values (wherever feasible) in order to perform more aggressive specialization. The second technique, tupling, combines mutually dependent automata together into a composite automaton whenever possible. Both techniques are needed for generating fast target code for RT-FRP.","PeriodicalId":187828,"journal":{"name":"ASIA-PEPM '02","volume":"9 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2002-09-12","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"7","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"ASIA-PEPM '02","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/568173.568183","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 7

Abstract

Most of the past languages for reactive systems are based on synchronous dataflow. Recently, a new reactive language, called Real-Time Functional Reactive Programming (RT-FRP) [18] , has been proposed based on the functional paradigm. The unique feature of this language is the high-level abstraction provided in the form of behaviors for conti-nuous-time signals, and events for discrete-time signals. RT-FRP also features some performance guarantees in the form of bounded runtime and space usage for each reactive computation step.In this paper, we propose a new compilation scheme for RT-FRP. Our compilation scheme is based on two key stages. In the first stage, we translate RT-FRP program to an intermediate functional code. This code is deliberately kept at high level for two reasons. First, it is easier for us to validate its correctness. Second, it allows us to apply high-level source-to-source transformation to achieve further optimization. The second stage attempts to compile the intermediate code to a corresponding automata code. Our main novelty is the use of two high-level transformation techniques for this compilation. The first technique, partial evaluation, attempts to propagate constant values (wherever feasible) in order to perform more aggressive specialization. The second technique, tupling, combines mutually dependent automata together into a composite automaton whenever possible. Both techniques are needed for generating fast target code for RT-FRP.
查看原文
分享 分享
微信好友 朋友圈 QQ好友 复制链接
本刊更多论文
编译实时函数式响应式编程
过去大多数用于响应式系统的语言都是基于同步数据流的。最近,一种新的反应性语言,称为实时功能反应性编程(RT-FRP)[18],已经提出了基于功能范式。这种语言的独特之处在于,它以行为的形式为连续时间信号提供高级抽象,以事件的形式为离散时间信号提供高级抽象。RT-FRP还以每个响应式计算步骤的有限运行时间和空间使用的形式提供了一些性能保证。本文提出了一种新的RT-FRP编制方案。我们的编译方案基于两个关键阶段。在第一阶段,我们将RT-FRP程序翻译成中间功能代码。出于两个原因,故意将此代码保存在高层。首先,我们更容易验证其正确性。其次,它允许我们应用高级的源到源转换来实现进一步的优化。第二阶段尝试将中间代码编译成相应的自动机代码。我们的主要新颖之处在于为这个编译使用了两种高级转换技术。第一种技术,部分求值,试图传播常数值(只要可行),以便执行更积极的专门化。第二种技术是tupling,它尽可能地将相互依赖的自动机组合成一个复合自动机。这两种技术都需要快速生成RT-FRP目标代码。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 去求助
来源期刊
自引率
0.00%
发文量
0
期刊最新文献
Automatic generation of efficient string matching algorithms by generalized partial computation Using indexed data structures for program specialization Jones optimality, binding-time improvements, and the strength of program specializers Compiling real time functional reactive programming Defying the speed of light:: a spatially-aware compiler for wire-exposed architectures
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
现在去查看 取消
×
提示
确定
0
微信
客服QQ
Book学术公众号 扫码关注我们
反馈
×
意见反馈
请填写您的意见或建议
请填写您的手机或邮箱
已复制链接
已复制链接
快去分享给好友吧!
我知道了
×
扫码分享
扫码分享
Book学术官方微信
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术
文献互助 智能选刊 最新文献 互助须知 联系我们:info@booksci.cn
Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。
Copyright © 2023 Book学术 All rights reserved.
ghs 京公网安备 11010802042870号 京ICP备2023020795号-1