Abstract
Over the past thirty years, there has been significant progress in developing general-purpose, language-based approaches to incremental computation, which aims to efficiently update the result of a computation when an input is changed. A key design challenge in such approaches is how to provide efficient incremental support for a broad range of programs. In this paper, we argue that first-class names are a critical linguistic feature for efficient incremental computation. Names identify computations to be reused across differing runs of a program, and making them first class gives programmers a high level of control over reuse. We demonstrate the benefits of names by presenting Nominal Adapton, an ML-like language for incremental computation with names. We describe how to use Nominal Adapton to efficiently incrementalize several standard programming patterns---including maps, folds, and unfolds---and show how to build efficient, incremental probabilistic trees and tries. Since Nominal Adapton's implementation is subtle, we formalize it as a core calculus and prove it is from-scratch consistent, meaning it always produces the same answer as simply re-running the computation. Finally, we demonstrate that Nominal Adapton can provide large speedups over both from-scratch computation and Adapton, a previous state-of-the-art incremental computation system.
Supplemental Material
Available for Download
This material provides a virtual machine image to run empirical experiments on Nominal Adapton. For the latest Adapton code in OCaml, see https://github.com/plum-umd/adapton.ocaml
- U. A. Acar. Self-Adjusting Computation. PhD thesis, Department of Computer Science, Carnegie Mellon University, May 2005. Google Scholar
Digital Library
- U. A. Acar and R. Ley-Wild. Self-adjusting computation with Delta ML. In Advanced Functional Programming. 2009. Google Scholar
Digital Library
- U. A. Acar, G. E. Blelloch, and R. Harper. Adaptive memoization. Technical Report CMU-CS-03-208, Carnegie Mellon University, Nov. 2004.Google Scholar
- U. A. Acar, G. E. Blelloch, M. Blume, R. Harper, and K. Tangwongsan. A library for self-adjusting computation. ENTCS, 148 (2), 2006. Google Scholar
Digital Library
- J. Allen. Anatomy of LISP. McGraw-Hill, Inc., New York, NY, USA, 1978. ISBN 0-07-001115-X. C. B. Barber, D. P. Dobkin, and H. Huhdanpaa. The quickhull algorithm for convex hulls. ACM Trans. Math. Softw., 22(4), Dec. 1996. Google Scholar
Digital Library
- R. Bellman. Dynamic Programming. Princeton Univ. Press, 1957. Google Scholar
Digital Library
- P. Bhatotia, A. Wieder, R. Rodrigues, U. A. Acar, and R. Pasquin. Incoop: MapReduce for incremental computations. SOCC ’11, 2011. Google Scholar
Digital Library
- P. Bhatotia, P. Fonseca, U. A. Acar, B. B. Brandenburg, and R. Rodrigues. iThreads: A threading library for parallel incremental computation. ASPLOS ’15, 2015. Google Scholar
Digital Library
- Y. Cai, P. G. Giarrusso, T. Rendel, and K. Ostermann. A theory of changes for higher-order languages: Incrementalizing λ-calculi by static differentiation. In PLDI, 2014. Google Scholar
Digital Library
- Y. Chen, U. A. Acar, and K. Tangwongsan. Functional programming for dynamic and large data with self-adjusting computation. In ICFP, 2014. Google Scholar
Digital Library
- G. H. Cooper and S. Krishnamurthi. Embedding dynamic dataflow in a call-by-value language. In ESOP, 2006. Google Scholar
Digital Library
- E. Czaplicki and S. Chong. Asynchronous functional reactive programming for GUIs. In PLDI, 2013. Google Scholar
Digital Library
- A. Demers, T. Reps, and T. Teitelbaum. Incremental evaluation of attribute grammars with application to syntax-directed editors. In POPL, 1981. Google Scholar
Digital Library
- J.-C. Filliˆatre and S. Conchon. Type-safe modular hash-consing. In Proceedings of the 2006 Workshop on ML, pages 12–19. ACM, 2006. Google Scholar
Digital Library
- M. Hammer and U. A. Acar. Memory management for selfadjusting computation. In ISMM, 2008. Google Scholar
Digital Library
- M. Hammer, G. Neis, Y. Chen, and U. A. Acar. Self-adjusting stack machines. In ACM SIGPLAN Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA), 2011. Google Scholar
Digital Library
- M. A. Hammer, U. A. Acar, and Y. Chen. CEAL: a C-based language for self-adjusting computation. In ACM SIGPLAN Conference on Programming Language Design and Implementation, 2009. Google Scholar
Digital Library
- M. A. Hammer, Y. P. Khoo, M. Hicks, and J. S. Foster. Adapton: Composable, demand-driven incremental computation. In PLDI, 2014. Google Scholar
Digital Library
- M. A. Hammer, J. Dunfield, K. Headley, N. Labich, J. S. Foster, M. Hicks, and D. Van Horn. Incremental computation with names (extended version). arXiv:1503.07792 {cs.PL}, 2015. Google Scholar
Digital Library
- N. R. Krishnaswami and N. Benton. A semantic model for graphical user interfaces. In ICFP, 2011. Google Scholar
Digital Library
- P. B. Levy. Call-by-push-value: A subsuming paradigm. In TLCA, 1999. Google Scholar
Digital Library
- P. B. Levy. Call-By-Push-Value. PhD thesis, Queen Mary and Westfield College, University of London, 2001.Google Scholar
- Y. A. Liu and T. Teitelbaum. Systematic derivation of incremental programs. Sci. Comput. Program., 24(1):1–39, 1995. Google Scholar
Digital Library
- Y. A. Liu, S. Stoller, and T. Teitelbaum. Static caching for incremental computation. ACM Transactions on Programming Languages and Systems, 20(3):546–585, 1998. Google Scholar
Digital Library
- J. McCarthy. A basis for a mathematical theory of computation. In Computer Programming and Formal Systems, 1963.Google Scholar
Cross Ref
- D. Michie. “Memo” functions and machine learning. Nature, 218: 19–22, 1968.Google Scholar
Cross Ref
- R. Mitschke, S. Erdweg, M. Köhler, M. Mezini, and G. Salvaneschi. i3QL: Language-integrated live data views. In OOPSLA, 2014. Google Scholar
Digital Library
- W. Pugh. Incremental Computation via Function Caching. PhD thesis, Cornell University, 1988.Google Scholar
- W. Pugh and T. Teitelbaum. Incremental computation via function caching. In POPL, 1989. Google Scholar
Digital Library
- T. Reps. Generating Language-Based Environments. PhD thesis, Cornell University, Aug. 1982a. T. Reps. Optimal-time incremental semantic analysis for syntaxdirected editors. In POPL, 1982b. A. Shankar and R. Bod´ık. DITTO: Automatic incrementalization of data structure invariant checks (in Java). In PLDI, 2007. Google Scholar
Digital Library
- H. Vogt, D. Swierstra, and M. Kuiper. Efficient incremental evaluation of higher order attribute grammars. In PLILP, 1991.Google Scholar
Cross Ref
- G. Winskel. The Formal Semantics of Programming Languages: An Introduction. MIT Press, 1993. Google Scholar
Digital Library
Index Terms
Incremental computation with names
Recommendations
Incremental computation with names
OOPSLA 2015: Proceedings of the 2015 ACM SIGPLAN International Conference on Object-Oriented Programming, Systems, Languages, and ApplicationsOver the past thirty years, there has been significant progress in developing general-purpose, language-based approaches to incremental computation, which aims to efficiently update the result of a computation when an input is changed. A key design ...
Adapton: composable, demand-driven incremental computation
PLDI '14Many researchers have proposed programming languages that support incremental computation (IC), which allows programs to be efficiently re-executed after a small change to the input. However, existing implementations of such languages have two important ...
Adapton: composable, demand-driven incremental computation
PLDI '14: Proceedings of the 35th ACM SIGPLAN Conference on Programming Language Design and ImplementationMany researchers have proposed programming languages that support incremental computation (IC), which allows programs to be efficiently re-executed after a small change to the input. However, existing implementations of such languages have two important ...






Comments