Skip to main content

Abstract Intepretation and recursive behaviour of logic programs

  • Conference paper
Logic Program Synthesis and Transformation

Part of the book series: Workshops in Computing ((WORKSHOPS COMP.))

Abstract

We propose a general abstract interpretation based on the recursive behaviour study of Prolog programs. This abstract interpretation allows both the dataflow analysis of a program execution and the automatic derivation of some program properties.

First, we introduce a new notion: the limited-unfolding loop (abbreviated to lul). Roughly speaking, a tree t satisfies a lul m iff the leaf of the branch corresponding to the unfolding of the loop m is labelled with a constant. Instead of a term-groundedness analysis, our study can be seen as a “branch-groundedness” analysis. A finite set of luls can be regarded as a type which may be associated with a variable. Thus, a new algebra of atoms is built and substitution, unification (lub) and anti-unification (gib) operations are redefined in an easy way.

Then, a general abstract resolution (called abstract OLDT resolution) based on the work of H. Tamaki and T. Sato is presented. This abstract resolution always terminates and allows the collection of some information about the concrete resolution (i.e., the standard Prolog interpretation) of all program.

The three stages for our Prolog program abstract interpretation are: 1) computation of a finite set of “significant” luls by looking into the structure of a given Prolog program. 2) abstract resolution from a given call-pattern. 3) analysis of the abstract structure (result of the previous step) for establishing properties like, e.g., solution pattern(s), termination, boundedness, determinism, complexity, ...

This work is supported by the “GRECO de la programmation du CNRS”

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Bruynooghe M. A practical framework for the abstract interpretation of logic programs. Journal of Logic Programming, Feb 1991, pp 91-124.

    Google Scholar 

  2. Cousot P. and Cousot R. Abstract Interpretation: a unified lattice for static analysis of programs by construction of approximation of fixpoints. POPL 1977, Sigact Sigplan, 1977, pp 238-252.

    Google Scholar 

  3. Corsini MM. Interprétation abstraite en programmation logique: théorie et applications. PhD thesis, Université de Bordeaux I, Jan 1989.

    Google Scholar 

  4. Devienne P. Weighted Graphs, a tool for expressing the behaviour of recursive rules in Logic Programming. FGCS conferences, Nov. 1988.

    Google Scholar 

  5. Devienne P. Weighted Graphs, a tool for studying the halting problem and time complexity in term rewriting systems and Logic Programming. ICOT technical report TR-437, 1988.

    Google Scholar 

  6. De Schreye D., Verschaetse K. and Bruynooghe M. A practical technique for detecting non-terminating queries for a restricted class of Horn clauses using directed, weighted graphs. Report CW-109, Mar 1990.

    Google Scholar 

  7. Gallagher J., Codish M. and Shapiro E. Specialisation of Prolog and FCP Programs using Abstract Interpretation. New Generation Computing, OHMSHA LTD and Springer-Verlag, 1988, pp 159-186.

    Google Scholar 

  8. Jones N. and Sondergaard H. A semantics-based framework for the abstract interpretation of Prolog. In Abstract interpretation of declarative languages, S. Abramsky and C. Hankin (Eds), Ellis Horwood, 1987.

    Google Scholar 

  9. Kanamori T. and Kawamura T. Analysing success patterns of logic programs by abstract hybrid interpretation. ICOT Technical Report, 1987.

    Google Scholar 

  10. Lecoutre C, Devienne P. and Lebegue P. Abstract Interpretation and recursive behaviour of logic programs. LIFL Technical Report, Oct 1991.

    Google Scholar 

  11. Lebègue P. Contribution à l’étude de la Programmation Logique par les Graphes Orientés Pondérés. PhD thesis, Université de LILLE I, Nov 1988.

    Google Scholar 

  12. 86]_Mellish CS. Abstract Interpretation of Prolog programs. In Abstract interpretation of declarative languages, S. Abramsky and C. Hankin (Eds), Ellis Horwood, 1987.

    Google Scholar 

  13. 88]_Marriot K. and Sondergaard H. Bottom-up abstract interpretation of logic programs. Proceedings of the fifth ILCP, Seattle, August 1988, pp 733-748.

    Google Scholar 

  14. 86]_Tamaki H., Sato T. OLD resolution with Tabulation. Proceedings of the third ICLP, LNCS, 225, Springer-Verlag, 1986.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 1992 Springer-Verlag London

About this paper

Cite this paper

Lecoutre, C., Devienne, P., Lebegue, P. (1992). Abstract Intepretation and recursive behaviour of logic programs. In: Clement, T.P., Lau, KK. (eds) Logic Program Synthesis and Transformation. Workshops in Computing. Springer, London. https://doi.org/10.1007/978-1-4471-3494-7_12

Download citation

  • DOI: https://doi.org/10.1007/978-1-4471-3494-7_12

  • Publisher Name: Springer, London

  • Print ISBN: 978-3-540-19742-3

  • Online ISBN: 978-1-4471-3494-7

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics