Exploiting Goal Independence in the Analysis of Logic Programs

Abstract This paper illustrates the use of a top-down framework to obtain goal independent analyses of logic programs, a task which is usually associated with the bottom-up approach. While it is well known that the bottom-up approach can be used, through the magic set transformation, for goal dependent analysis, it is less known that the top-down approach can be used for goal independent analysis. The paper describes two ways of doing the latter. We show how the results of a goal independent analysis can be used to speed up subsequent goal dependent analyses. However this speed-up may result in a loss of precision. The influence of domain characteristics on this precision is discussed and an experimental evaluation using a generic top-down analyzer is described. Our results provide intuition regarding the cases where a two phase analysis might be worth-while.

[1]  Maurice Bruynooghe,et al.  Live-structure dataflow analysis for Prolog , 1994, TOPL.

[2]  Maurice Bruynooghe,et al.  A Practical Framework for the Abstract Interpretation of Logic Programs , 1991, J. Log. Program..

[3]  Pascal Van Hentenryck,et al.  Experimental evaluation of a generic abstract interpretation algorithm for Prolog , 1992, ICCL.

[4]  Patrick Cousot,et al.  Abstract interpretation: a unified lattice model for static analysis of programs by construction or approximation of fixpoints , 1977, POPL.

[5]  M. Codish,et al.  Goal Dependent vs . Goal Independent Analysis of Logic Programs , 1994 .

[6]  Kim Marriott,et al.  Precise and efficient groundness analysis for logic programs , 1993, LOPL.

[7]  Patrick Cousot,et al.  Abstract Interpretation and Application to Logic Programs , 1992, J. Log. Program..

[8]  Maurice Bruynooghe,et al.  A live-structure data-flow analysis for Prolog: theory , 1993 .

[9]  A. Cortesi,et al.  Prop revisited: propositional formula as abstract domain for groundness analysis , 1991, [1991] Proceedings Sixth Annual IEEE Symposium on Logic in Computer Science.

[10]  Gerda Janssens,et al.  A Blueprint for an Abstract Machine for Abstract Interpretation of (Constraint) Logic Programs , 1995, ILPS.

[11]  Pascal Van Hentenryck,et al.  Evaluation of the Domain Prop , 1995, J. Log. Program..

[12]  Manuel V. Hermenegildo,et al.  Compile-Time Derivation of Variable Dependency Using Abstract Interpretation , 1992, J. Log. Program..

[13]  Giorgio Levi,et al.  Declarative Modeling of the Operational Behavior of Logic Languages , 1989, Theor. Comput. Sci..

[14]  Agostino Cortesi,et al.  Optimal Groundness Analysis Using Propositional Logic , 1996, J. Log. Program..

[15]  Pascal Van Hentenryck,et al.  Groundness analysis for Prolog: implementation and evaluation of domain prop , 1993, PEPM '93.

[16]  Kim Marriott,et al.  Bottom-up Abstract Interpretation of Logic Programs , 1988, ICLP/SLP.

[17]  Maurice Bruynooghe,et al.  Goal Dependent versus Goal Independent Analysis of Logic Programs , 1994, LPAR.

[18]  Agostino Cortesi,et al.  Comparison of Abstract Interpretations , 1992, ICALP.

[19]  Gerda Janssens,et al.  Live-Structure Analysis for Logic Programming Languages with Declarations , 1997, ICLP.

[20]  Roberto Barbuti,et al.  A general framework for semantics-based bottom-up abstract interpretation of logic programs , 1993, TOPL.

[21]  Simon L. Peyton Jones,et al.  Imperative functional programming , 1993, POPL '93.

[22]  Kazunori Ueda,et al.  Proceedings of the 1991 international symposium on Logic programming , 1991 .

[23]  Dean Jacobs,et al.  Static Analysis of Logic Programs for Independent And-Parallelism , 1992, J. Log. Program..

[24]  Bart Demoen,et al.  Analysing Logic Programs Using 'Prop'-ositional Logic Programs and a Magic Wand , 1993, ILPS.

[25]  Antoine Rauzy,et al.  Efficient Bottom-up Abstract Interpretation of Prolog by Means of Constraint Solving over Symbolic Finite Domains , 1993, PLILP.

[26]  Michael Codish,et al.  Bottum-up abstract interpretation of logic programs , 1992 .

[27]  Harald Søndergaard,et al.  An Application of Abstract Interpretation of Logic Programs: Occur Check Reduction , 1986, ESOP.