Abstract
Many 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 drawbacks. First, recomputation is oblivious to specific demands on the program output; that is, if a program input changes, all dependencies will be recomputed, even if an observer no longer requires certain outputs. Second, programs are made incremental as a unit, with little or no support for reusing results outside of their original context, e.g., when reordered.
To address these problems, we present λiccdd, a core calculus that applies a demand-driven semantics to incremental computation, tracking changes in a hierarchical fashion in a novel demanded computation graph. λiccdd also formalizes an explicit separation between inner, incremental computations and outer observers. This combination ensures λiccdd programs only recompute computations as demanded by observers, and allows inner computations to be reused more liberally. We present Adapton, an OCaml library implementing λiccdd. We evaluated Adapton on a range of benchmarks, and found that it provides reliable speedups, and in many cases dramatically outperforms state-of-the-art IC approaches.
- M. Abadi, B. W. Lampson, and J.-J. Lévy. Analysis and caching of dependencies. In ICFP, 1996. Google Scholar
Digital Library
- 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
- U. A. Acar, G. E. Blelloch, M. Blume, and K. Tangwongsan. An experimental analysis of self-adjusting computation. In PLDI, 2006. Google Scholar
Digital Library
- U. A. Acar, G. E. Blelloch, and R. Harper. Adaptive functional programming. TOPLAS, 28(6), 2006. Google Scholar
Digital Library
- U. A. Acar, A. Ihler, R. Mettu, and O. Sümer. Adaptive Bayesian inference. In NIPS, 2007.Google Scholar
- U. A. Acar, G. E. Blelloch, K. Tangwongsan, and D. Türkoğlu. Robust kinetic convex hulls in 3D. In ESA, 2008. Google Scholar
Digital Library
- U. A. Acar, A. Cotter, B. Hudson, and D. Türkoğlu. Dynamic well-spaced point sets. In SoCG, 2010. Google Scholar
Digital Library
- R. Bellman. Dynamic Programming. Princeton Univ. Press, 1957.Google Scholar
- M. A. Bender, R. Cole, E. D. Demaine, M. Farach-Colton, and J. Zito. Two simplified algorithms for maintaining order in a list. In ESA, 2002. Google Scholar
Digital Library
- M. Carlsson. Monads for incremental computing. In ICFP, 2002. Google Scholar
Digital Library
- Y. Chen, J. Dunfield, M. A. Hammer, and U. A. Acar. Implicit self-adjusting computation for purely functional programs. In ICFP, 2011. Google Scholar
Digital Library
- Y. Chen, J. Dunfield, and U. A. Acar. Type-directed automatic incrementalization. In PLDI, 2012. 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
- P. F. Dietz and D. D. Sleator. Two algorithms for maintaining order in a list. In STOC, 1987. Google Scholar
Digital Library
- J. Field and T. Teitelbaum. Incremental reduction in the lambda calculus. In LFP, 1990. Google Scholar
Digital Library
- M. Hammer and U. A. Acar. Memory management for self-adjusting computation. In ISMM, 2008. Google Scholar
Digital Library
- M. Hammer, U. A. Acar, M. Rajagopalan, and A. Ghuloum. A proposal for parallel self-adjusting computation. In DAMP, 2007. Google Scholar
Digital Library
- M. Hammer, G. Neis, Y. Chen, and U. A. Acar. Self-adjusting stack machines. In 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 PLDI, 2009. Google Scholar
Digital Library
- M. A. Hammer, Y. P. Khoo, M. Hicks, and J. S. Foster. Adapton: Composable, demand-driven incremental computation. Technical Report CS-TR-5027, Computer Science Department, University of Maryland, College Park, 2014.Google Scholar
Digital Library
- A. Heydon, R. Levin, and Y. Yu. Caching function calls using precise dependencies. In PLDI, 2000. Google Scholar
Digital Library
- R. Hoover. Alphonse: Incremental computation as a programming abstraction. In PLDI, 1992. Google Scholar
Digital Library
- R. Hoover and T. Teitelbaum. Efficient incremental evaluation of aggregate values in attribute grammars. In CC, 1986. Google Scholar
Digital Library
- S. E. Hudson. Incremental attribute evaluation: A flexible algorithm for lazy update. TOPLAS, 13(3), 1991. 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. Levy. Call-by-push-value: A subsuming paradigm. In TLCA, 1999. Google Scholar
Digital Library
- P. B. Levy. Call-by-push-value: A Functional/imperative Synthesis. Springer, 2003. Google Scholar
Digital Library
- R. Ley-Wild. Programmable Self-Adjusting Computation. PhD thesis, Computer Science Department, Carnegie Mellon University, Oct. 2010. Google Scholar
Digital Library
- R. Ley-Wild, U. A. Acar, and M. Fluet. A cost semantics for self-adjusting computation. In POPL, 2009. Google Scholar
Digital Library
- R. Ley-Wild, U. A. Acar, and G. E. Blelloch. Non-monotonic self-adjusting computation. In ESOP, 2012. Google Scholar
Digital Library
- Y. A. Liu and T. Teitelbaum. Systematic derivation of incremental programs. SOCP, 24(1), 1995. Google Scholar
Digital Library
- J. McCarthy. A basis for a mathematical theory of computation. In P. Braffort and D. Hirschberg, editors, Computer Programming and Formal Systems. North-Holland, Amsterdam, 1963.Google Scholar
Cross Ref
- L. A. Meyerovich, A. Guha, J. Baskin, G. H. Cooper, M. Greenberg, A. Bromfield, and S. Krishnamurthi. Flapjax: A programming language for ajax applications. In OOPSLA, 2009. Google Scholar
Digital Library
- D. Michie. "Memo" functions and machine learning. Nature, 218, 1968.Google Scholar
- W. Pugh and T. Teitelbaum. Incremental computation via function caching. In POPL, 1989. Google Scholar
Digital Library
- G. Ramalingam and T. Reps. A categorized bibliography on incremental computation. In POPL, 1993. Google Scholar
Digital Library
- A. Shankar and R. Bodik. DITTO: Automatic incrementalization of data structure invariant checks (in Java). In PLDI, 2007. Google Scholar
Digital Library
Index Terms
Adapton: composable, demand-driven incremental computation
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 '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 ...
Incremental computation with names
OOPSLA '15Over 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 ...







Comments