Guerric Chupin
Functional Reactive Programming, restated
Chupin, Guerric; Nilsson, Henrik
Authors
Henrik Nilsson
Abstract
Functional Reactive Programming is an approach to declarative programming of reactive systems by describing interactions between time-varying values. FRP implementations are often realised as an embedding in a functional host language, making for very expressive reactive programming frameworks. However, this expressiveness comes at a cost: current embedded FRP implementations incur substantial performance overheads, in particular for values that (notionally) vary continuously. The basic idea of FRP is closely related to synchronous data-flow and continuous system simulation languages. In contrast to FRP, these handle values that vary continuously efficiently, but are less expressive. This paper seeks to bridge this gap by proposing a novel approach to embedded FRP-implementation that uses the fundamental implementation approach of synchronous datalow and simulation languages for efficient handling of continuously varying values, while retaining the expressiveness normally associated with FRP, as well as paying attention to values that only change relatively infrequently. These ideas are applicable beyond FRP, for example for implementing flexible embedded simulation languages. We evaluate our approach on a range of benchmarks, including an existing full-fledged video game where using our new FRP implementation as a drop-in replacement for the old one gave a three-fold performance improvement.
Citation
Chupin, G., & Nilsson, H. (2019). Functional Reactive Programming, restated. In PPDP '19: Proceedings of the 21st International Symposium on Principles and Practice of Programming Languages 2019 (1–14). https://doi.org/10.1145/3354166.3354172
Presentation Conference Type | Edited Proceedings |
---|---|
Conference Name | PPDP '19: Principles and Practice of Programming Languages 2019 |
Start Date | Oct 7, 2019 |
End Date | Oct 9, 2019 |
Acceptance Date | Jun 20, 2019 |
Online Publication Date | Oct 7, 2019 |
Publication Date | Oct 7, 2019 |
Deposit Date | Sep 4, 2020 |
Publicly Available Date | Sep 24, 2020 |
Publisher | Association for Computing Machinery (ACM) |
Pages | 1–14 |
Book Title | PPDP '19: Proceedings of the 21st International Symposium on Principles and Practice of Programming Languages 2019 |
ISBN | 9781450372497 |
DOI | https://doi.org/10.1145/3354166.3354172 |
Public URL | https://nottingham-repository.worktribe.com/output/4882090 |
Publisher URL | https://dl.acm.org/doi/10.1145/3354166.3354172 |
About Repository@Nottingham
Administrator e-mail: discovery-access-systems@nottingham.ac.uk
This application uses the following open-source libraries:
SheetJS Community Edition
Apache License Version 2.0 (http://www.apache.org/licenses/)
PDF.js
Apache License Version 2.0 (http://www.apache.org/licenses/)
Font Awesome
SIL OFL 1.1 (http://scripts.sil.org/OFL)
MIT License (http://opensource.org/licenses/mit-license.html)
CC BY 3.0 ( http://creativecommons.org/licenses/by/3.0/)
Powered by Worktribe © 2024
Advanced Search