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”
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
References
Bruynooghe M. A practical framework for the abstract interpretation of logic programs. Journal of Logic Programming, Feb 1991, pp 91-124.
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.
Corsini MM. Interprétation abstraite en programmation logique: théorie et applications. PhD thesis, Université de Bordeaux I, Jan 1989.
Devienne P. Weighted Graphs, a tool for expressing the behaviour of recursive rules in Logic Programming. FGCS conferences, Nov. 1988.
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.
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.
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.
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.
Kanamori T. and Kawamura T. Analysing success patterns of logic programs by abstract hybrid interpretation. ICOT Technical Report, 1987.
Lecoutre C, Devienne P. and Lebegue P. Abstract Interpretation and recursive behaviour of logic programs. LIFL Technical Report, Oct 1991.
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.
86]_Mellish CS. Abstract Interpretation of Prolog programs. In Abstract interpretation of declarative languages, S. Abramsky and C. Hankin (Eds), Ellis Horwood, 1987.
88]_Marriot K. and Sondergaard H. Bottom-up abstract interpretation of logic programs. Proceedings of the fifth ILCP, Seattle, August 1988, pp 733-748.
86]_Tamaki H., Sato T. OLD resolution with Tabulation. Proceedings of the third ICLP, LNCS, 225, Springer-Verlag, 1986.
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights 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