Abstract
This paper presents a semantics of self-adjusting computation and proves that the semantics is correct and consistent. The semantics integrates change propagation with the classic idea of memoization to enable reuse of computations under mutation to memory. During evaluation, reuse of a computation via memoization triggers a change propagation that adjusts the reused computation to reflect the mutated memory. Since the semantics combines memoization and change-propagation, it involves both non-determinism and mutation. Our consistency theorem states that the non-determinism is not harmful: any two evaluations of the same program starting at the same state yield the same result. Our correctness theorem states that mutation is not harmful: self-adjusting programs are consistent with purely functional programming. We formalized the semantics and its meta-theory in the LF logical framework and machine-checked the proofs in Twelf.
Chapter PDF
Similar content being viewed by others
Keywords
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.
References
Abadi, M., Lampson, B.W., Levy, J.-J.: Analysis and caching of dependencies. In: International Conference on Functional Programming, pp. 83–91 (1996), citeseer.nj.nec.com/abadi96analysis.html
Acar, U.A.: Self-Adjusting Computation. PhD thesis, Department of Computer Science, Carnegie Mellon University (May 2005)
Acar, U.A., et al.: An experimental analysis of self-adjusting computation. In: Proceedings of the ACM SIGPLAN Conference on Programming Language Design and Implementation, ACM Press, New York (2006)
Acar, U.A., Blelloch, G.E., Harper, R.: Adaptive functional programming. In: Proc. of the 29th Ann. ACM Symp. on POPL, pp. 247–259. ACM Press, New York (2002), citeseer.nj.nec.com/article/acar01adaptive.html
Acar, U.A., Blelloch, G.E., Harper, R.: Selective memoization. In: Proc. of the 30th Annual ACM Symposium on Principles of Programming Languages, ACM Press, New York (2003)
Acar, U.A., et al.: Dynamizing static algorithms with applications to dynamic trees and history independence. In: ACM-SIAM Symposium on Discrete Algorithms (SODA), ACM Press, New York (2004)
Acar, U.A., et al.: Kinetic algorithms via self-adjusting computation. Technical Report CMU-CS-06-115, Department of Computer Science, Carnegie Mellon University (March 2006)
Acar, U.A., Blelloch, G.E., Vittes, J.L.: An experimental analysis of change propagation in dynamic trees. In: Workshop on Algorithm Engineering and Experimentation (2005)
Acar, U.A., Blume, M., Donham, J.: A consistent semantics of self-adjusting computation. Technical Report CMU-CS-06-168, Department of Computer Science, Carnegie Mellon University (2006)
Carlsson, M.: Monads for incremental computing. In: Proc. of the 7th ACM SIGPLAN Intl. Conf. on Funct. Prog., Pittsburgh, PA, USA, pp. 26–35. ACM Press, New York (2002), doi:10.1145/581478.581482
Demers, A., Reps, T., Teitelbaum, T.: Incremental evaluation of attribute grammars with application to syntax directed editors. In: Proceedings of the 8th Annual ACM Symposium on Principles of Programming Languages, pp. 105–116. ACM Press, New York (1981)
Field, J., Teitelbaum, T.: Incremental reduction in the lambda calculus. In: Proceedings of the ACM ’90 Conference on LISP and Functional Programming, June 1990, pp. 307–322. ACM Press, New York (1990)
Harper, R., Honsell, F., Plotkin, G.: A framework for defining logics. Journal of the Association for Computing Machinery 40(1), 143–184 (1993)
Harper, R., Licata, D.: Mechanizing language definitions (Submitted for publication) (April 2006)
Michie, D.: ’Memo’ functions and machine learning. Nature 218, 19–22 (1968)
Pfenning, F.: System description: Twelf — a meta-logical framework for deductive systems. In: Ganzinger, H. (ed.) CADE 1999. LNCS (LNAI), vol. 1632, pp. 202–206. Springer, Heidelberg (1999)
Pugh, W., Teitelbaum, T.: Incremental computation via function caching. In: Proceedings of the 16th Annual ACM Symposium on Principles of Programming Languages, pp. 315–328. ACM Press, New York (1989)
Ramalingam, G., Reps, T.: A categorized bibliography on incremental computation. In: Conference Record of the 20th Annual ACM Symposium on POPL, Jan. 1993, pp. 502–510. ACM Press, New York (1993)
Sundaresh, R.S., Hudak, P.: Incremental compilation via partial evaluation. In: Conf. Record of the 18th Ann. ACM Symp. on POPL, Jan. 1991, pp. 1–13. ACM Press, New York (1991)
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 2007 Springer Berlin Heidelberg
About this paper
Cite this paper
Acar, U.A., Blume, M., Donham, J. (2007). A Consistent Semantics of Self-adjusting Computation. In: De Nicola, R. (eds) Programming Languages and Systems. ESOP 2007. Lecture Notes in Computer Science, vol 4421. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-71316-6_31
Download citation
DOI: https://doi.org/10.1007/978-3-540-71316-6_31
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-71314-2
Online ISBN: 978-3-540-71316-6
eBook Packages: Computer ScienceComputer Science (R0)