Control Generation by Program Transformation

  • Authors:
  • Andy King;Jonathan C. Martin

  • Affiliations:
  • University of Kent, UK. E-mail: a.m.king@kent.ac.uk;University of Kent, UK. E-mail: a.m.king@kent.ac.uk

  • Venue:
  • Fundamenta Informaticae - Program Transformation: Theoretical Foundations and Basic Techniques. Part 2
  • Year:
  • 2006

Quantified Score

Hi-index 0.00

Visualization

Abstract

The objective of control generation in logic programming is to derive a computation rule for a program that is efficient and yet does not compromise programcorrectness. Progress in solving this fundamental problem in logic programming has been slow and, to date, only partial solutions have been proposed. Previously proposed schemes are either inefficient, incomplete (incorrect) or difficult to apply for programs consisting of many components (the scheme is not modular). This paper shows how the control generation problem can be tackled by program transformation. The transformation relies on information about the depths of derivations to derive delay declarations which orchestrate the control. To prove correctness of the transformation, the notion of semi-delay recurrency is introduced, which generalises previous ideas in the termination literature for reasoning about logic programs with delay declarations. In contrast to previous work, semi-delay recurrency does not require an atom to be completely resolved before another is selected for reduction. This enhancement permits the transformation to introduce control which is flexible and relatively efficient.