State-saving transformations for efficient bottom-up

  • Authors:
  • Knut Hinkelmann;Helge Hintze

  • Affiliations:
  • German Research Center for Artificial Intelligence – DFKI GmbH, Postfach 2080, 67608 Kaiserslautern, Germany E‐mail: hinkelma@dfki.uni‐kl.de;German Research Center for Artificial Intelligence – DFKI GmbH, Postfach 2080, 67608 Kaiserslautern, Germany E‐mail: hinkelma@dfki.uni‐kl.de

  • Venue:
  • Annals of Mathematics and Artificial Intelligence
  • Year:
  • 1997

Quantified Score

Hi-index 0.01

Visualization

Abstract

Redundant computations in bottom‐up evaluation of logic programs and rule‐based systems can be avoided by caching intermediate joins – i.e., partial rule instantiations – for later use. Joins can be cached either at representation level by program transformation techniques introducing supplementary predicates or at implementation level by specialized implementation techniques using internal memory cells. The efficiency of these state‐saving techniques depends on the selection of premises for storing the joins. In this paper we first present a general program transformation technique for saving joins which heuristically reorders subgoals and performs predicate splitting optimization, an extension of unfolding. This state‐saving transformation can be applied for any goal‐directed and model‐generation evaluation. It does not require any information about the query. We show that the program transformation approach is equivalent to the specialized state‐saving implementations known from production systems and model‐generation theorem provers. To use the efficient and complete bottom‐up evaluation also for query answering, we improve the supplementary extensions of Generalized Magic Sets and Magic Templates rewriting strategies by the presented state‐saving transformation.