A local algorithm for incremental evaluation of tabled logic programs

  • Authors:
  • Diptikalyan Saha;C. R. Ramakrishnan

  • Affiliations:
  • Dept. of Computer Science, Stony Brook University, Stony Brook, NY;Dept. of Computer Science, Stony Brook University, Stony Brook, NY

  • Venue:
  • ICLP'06 Proceedings of the 22nd international conference on Logic Programming
  • Year:
  • 2006

Quantified Score

Hi-index 0.00

Visualization

Abstract

This paper considers the problem of efficient incremental maintenance of memo tables in a tabled logic programming system. Most existing techniques for this problem consider insertion and deletion of facts as primitive changes, and treat update as deletion of the old version followed by insertion of the new version. They handle insertion and deletion using independent algorithms, consequently performing many redundant computations when processing updates. In this paper, we present a local algorithm for handling updates to facts. The key idea is to interleave the propagation of deletion and insertion operations generated by the updates through a dynamic (and potentially cyclic) dependency graph. The dependency graph used in our algorithm is more general than that used in algorithms previously proposed for incremental evaluation of attribute grammars and functional programs. Nevertheless, our algorithm’s complexity matches that of the most efficient algorithms built for these specialized cases. We demonstrate the effectiveness of our algorithm using data-flow analysis and parsing examples.