## A General Framework for Semantics-based Bottom-up Abstract Interpretation of Logic Programs (1993)

Venue: | ACM Transactions on Programming Languages and Systems |

Citations: | 75 - 26 self |

### BibTeX

@ARTICLE{Barbuti93ageneral,

author = {Roberto Barbuti and Roberto Giacobazzi and Giorgio Levi},

title = {A General Framework for Semantics-based Bottom-up Abstract Interpretation of Logic Programs},

journal = {ACM Transactions on Programming Languages and Systems},

year = {1993},

volume = {15},

pages = {133--181}

}

### Years of Citing Articles

### OpenURL

### Abstract

Interpretation of Logic Programs Roberto Barbuti , Roberto Giacobazzi , Giorgio Levi Dipartimento di Informatica Universit`a di Pisa Corso Italia 40, 56125 Pisa fbarbuti,giaco,levig@di.unipi.it in ACM Transactions on Programming Languages and Systems Vol 15, January 1993 Abstract The theory of abstract interpretation provides a formal framework to develop advanced dataflow analysis tools. The idea is to define a non-standard semantics which is able to compute, in finite time, an approximated model of the program. In this paper we define an abstract interpretation framework based on a fixpoint approach to the semantics. This leads to the definition, by means of a suitable set of operators, of an abstract fixpoint characterization of a -model associated with the program. Thus, we obtain a specializable abstract framework for bottom-up abstract interpretations of definite logic programs. The specialization of the framework is shown on two examples, namely ground dependence analysis and depth-k analysis.

### Citations

1996 |
Abstract interpretation: a unified lattice model for static analysis of programs by construction or approximation of fixpoints
- Cousot, Cousot
- 1977
(Show Context)
Citation Context ...; I.2.3 [Artificial Intelligence]: Deduction and Theorem Proving - logic programming. Keywords: Abstract interpretation, logic programming, program analysis. 1 Introduction An abstract interpretation =-=[13, 14]-=- of a program is an approximation of its standard semantics on an abstract simpler, generally finite, domain. Its goal is to collect static (compile-time) information about the run-time behavior of a ... |

1913 |
Foundations of Logic Programming
- LLoyd
- 1987
(Show Context)
Citation Context ...ed on a denotational semantics [8, 9, 19, 43, 48, 46, 58, 35]. The bottom-up approach propagates the information as in the computation of the least fixpoint of the immediate consequences operator T P =-=[39, 60]-=-. The idea of bottom-up analysis was first introduced in [45]. [48] uses a bottom-up analysis to reason about top-down computations. The main difference between the top-down and the bottom-up approach... |

667 | Systematic design of program analysis frameworks
- Cousot, Cousot
(Show Context)
Citation Context ... interpretation. They define a strong relationship between the concrete domain of computations and the abstract, usually simpler, domain associated with the analysis. Their usefulness was outlined in =-=[13, 14]-=- as a base to develop soundness conditions for semantics-based analysis of flowchart programs. Galois insertions ensure that the domain D ] P (the abstract domain of computation) does not contain redu... |

623 |
Lattice Theory
- Birkhoff
- 1940
(Show Context)
Citation Context ...ly, in section 6 further extensions and applications of the general framework are presented. 2 2 Logic Programs and Abstract Interpretation In this section we recall some notions about lattice theory =-=[7]-=-, about the semantics of logic programs (as defined in [23]) and about the general theory of abstract interpretation (as defined in [1, 13]. The reader is assumed to be acquainted with the basic conce... |

391 | A Kripke-Kleene Semantics for Logic Programs
- Fitting
- 1985
(Show Context)
Citation Context ...k As already mentioned in the introduction, the idea of T P -based bottom-up abstract interpretation goes back to [45], which considers general programs using as concrete semantics the one defined in =-=[25]-=-. Since this semantics is defined on a ground domain, the resulting abstract analysis is not able to capture computational properties related to the use of logical variables. [46] solves the above pro... |

227 |
Unification revisited
- Lassez, Maher, et al.
- 1987
(Show Context)
Citation Context ...y Unif(E) the (possibly empty) set of unifiers of E. We denote by mgu(E) the set f# 2 Unif(E) j 8# 0 2 Unif(E) : #s# 0 g. It is well known that all the most general unifiers of a set E are equivalent =-=[21, 38]-=-. Consider a program P and the set Cons P of constructors of the first order language underlyingsP . The extended Herbrand Universe U P is defined as TCons P (V ar)= , i.e. the set of equivalence clas... |

117 |
Declarative modeling of the operational behavior of logic languages
- Falaschi, Levi, et al.
- 1989
(Show Context)
Citation Context ...an abstract -model for P . 2 Let us denote by = ] = fI ] 2 H P j T ] P (I ] )sff I ] g. Thus = ] ` fI ] 2 H P j I ] is an abstract -model of P g. The following theorem corresponds to the standard one =-=[23]-=- specifying = ] as a finite lattice with respect tosff . Theorem 3.13 = ] is a finite lattice with respect to thesff order relation. Proof. Let us first show that for any finite set of abstract -model... |

104 |
A semantics-based framework for the abstract interpretation of Prolog
- Jones, Sondergaard
- 1987
(Show Context)
Citation Context ...tion in the same direction as SLD-resolution does. In this class we can find top-down ad-hoc algorithms, frameworks based on an operational semantics, and frameworks based on a denotational semantics =-=[8, 9, 19, 43, 48, 46, 58, 35]-=-. The bottom-up approach propagates the information as in the computation of the least fixpoint of the immediate consequences operator T P [39, 60]. The idea of bottom-up analysis was first introduced... |

79 |
Equivalence of logic programs
- Maher
(Show Context)
Citation Context ...richer information structure, like those giving a representation (usually finite by means of variables) of infinite sets of ground atoms. We have to consider a different notion of program equivalence =-=[40]-=-, rich enough to model the useful information for program analysis, i.e. the observable properties of the operational semantics. The extended Herbrand Universe contains also non-ground terms. Thus, it... |

74 | Automatic mode inference of logic programs
- Debray, Warren
- 1988
(Show Context)
Citation Context ...tion in the same direction as SLD-resolution does. In this class we can find top-down ad-hoc algorithms, frameworks based on an operational semantics, and frameworks based on a denotational semantics =-=[8, 9, 19, 43, 48, 46, 58, 35]-=-. The bottom-up approach propagates the information as in the computation of the least fixpoint of the immediate consequences operator T P [39, 60]. The idea of bottom-up analysis was first introduced... |

74 |
Abastract Interpretation of Prolog Programs
- Mellish
- 1987
(Show Context)
Citation Context ...tion in the same direction as SLD-resolution does. In this class we can find top-down ad-hoc algorithms, frameworks based on an operational semantics, and frameworks based on a denotational semantics =-=[8, 9, 19, 43, 48, 46, 58, 35]-=-. The bottom-up approach propagates the information as in the computation of the least fixpoint of the immediate consequences operator T P [39, 60]. The idea of bottom-up analysis was first introduced... |

72 |
Denotational abstract interpretation of logic programs
- Marriott, Søndergaard, et al.
- 1994
(Show Context)
Citation Context ...e bottom-up approach propagates the information as in the computation of the least fixpoint of the immediate consequences operator T P [39, 60]. The idea of bottom-up analysis was first introduced in =-=[45]-=-. [48] uses a bottom-up analysis to reason about top-down computations. The main difference between the top-down and the bottom-up approach is related to goal dependence. In particular, the top-down a... |

71 | A Model-theoretic Reconstruction of the Operational Semantics of Logic Programs - Falaschi, Levi, et al. - 1993 |

71 | A compositional semantics for logic programs
- Bossi, Gabrielli, et al.
- 1994
(Show Context)
Citation Context ... to atoms as well). We extend also the notion of variancesto any syntactic object (i.e. terms, atoms, clauses, etc.). In the following, an extended notion of interpretation (-interpretation) is given =-=[24, 26]-=-. -interpretations are more expressive than Herbrand interpretations because of the use of more syntactic objects (like variables) in the semantic domains. Analogously to the standard semantics, the B... |

59 |
Accurate and Efficient Approximation of Variable Aliasing in Logic Programs
- Jacobs, Langen
- 1989
(Show Context)
Citation Context ...straint logic programming paradigm. In its present form, the approach can be instantiated to various analyses. The groundness analysis framework can be extended to deal with variable sharing analysis =-=[15, 34, 51, 43, 48, 57]-=-. The idea is to specialize our scheme, by using the same abstract universe of the groundness analysis and a different notion of dependence. Namely, there exists a dependence between some arguments if... |

56 | Bottom-up abstract interpretation of logic programs
- Codish, Dams, et al.
- 1994
(Show Context)
Citation Context ...e abstract base (2 B ] P ; `) is usually not concise enough to represent abstract information. In some applications, as an example, the analysis returns at most one success pattern per program clause =-=[10]-=- or per predicate symbol [19, 47]. This assumption is reasonable if we assume that in most of the real programs, specific predicate arguments are used with the same mode or type structure. As shown in... |

56 |
Some Global Optimizations for a Prolog Compiler
- Mellish
- 1985
(Show Context)
Citation Context ... is usually not concise enough to represent abstract information. In some applications, as an example, the analysis returns at most one success pattern per program clause [10] or per predicate symbol =-=[19, 47]-=-. This assumption is reasonable if we assume that in most of the real programs, specific predicate arguments are used with the same mode or type structure. As shown in [18], this technique may lead to... |

53 |
An Abstract Machine for Restricted And-Parallel Execution of Logic Programs
- Hermenegildo
- 1986
(Show Context)
Citation Context ...w abstract information is represented is central in abstract interpretation. Program analysis often requires to capture the interaction between abstract terms, like sharing and functional dependences =-=[28, 30, 31, 32, 50, 61]-=-. An equivalence relation on abstract atoms A characterizes such properties. Example 3.2 Let us consider the abstract universe of terms defined with respect to the following equivalence relation t 1st... |

52 |
An instance of abstract interpretation integrating type and mode irfferencing
- Bmynooghe, Janssens
- 1988
(Show Context)
Citation Context ...n the field of logic and functional languages can be found in [1]. Abstract interpretation is inherently semantics sensitive. However, in many cases the result is an ad-hoc algorithm (see for example =-=[8]). Alterna-=-tively, the abstract interpretation is explicitly based on a formal semantics definition. This work has been supported by "Progetto Finalizzato Sistemi Informatici e Calcolo Parallelo" of C.... |

49 |
Abstract interpretation : towards the global optimization of Prolog programs
- Bmynooghe, Janssens, et al.
- 1987
(Show Context)
Citation Context ...finite, domain. Its goal is to collect static (compile-time) information about the run-time behavior of a program (data-flow analysis), to be used by compilers (for error detection, code optimization =-=[9, 11, 20, 36]-=-) and, in general, by program manipulation systems [27]. An introduction to the subject of abstract interpretation in the field of logic and functional languages can be found in [1]. Abstract interpre... |

48 |
of Substitutions and Unifications
- Eder, Properties
(Show Context)
Citation Context ...y Unif(E) the (possibly empty) set of unifiers of E. We denote by mgu(E) the set f# 2 Unif(E) j 8# 0 2 Unif(E) : #s# 0 g. It is well known that all the most general unifiers of a set E are equivalent =-=[21, 38]-=-. Consider a program P and the set Cons P of constructors of the first order language underlyingsP . The extended Herbrand Universe U P is defined as TCons P (V ar)= , i.e. the set of equivalence clas... |

44 |
An Algebra of Logic Programs
- Mancarella, Pedreschi
- 1988
(Show Context)
Citation Context ...B n ); I ] 1 )s\Phi ff-mgu((B 1 ; :::; B n ); I ] 2 ). By the monotonicity of ff-apply, it follows that T ] C (I ] 1 )sff T ] C (I ] 2 ). 2 Following the approach to program compositionality given in =-=[42]-=-, the abstract transformation maps can be composed in an algebraic way, such that, for each T ] C 1 ; T ] C 2 , the composed abstract transformation map is I ] :(T ] C 1 (I ] )ff-tT ] C 2 (I ] )). We ... |

35 | Efficient Dataflow Analysis of Logic Programs
- Debray
- 1988
(Show Context)
Citation Context ... approach given in [14] can be applied to logic programming obtaining elegant techniques to define abstract domains. These techniques can always be summarized by a suitable notion of data equivalence =-=[16, 19]-=-. In the following we develop a step-by-step approach to the abstract domain definition. The main problem is what we want to observe from concrete data behavior and how the resulting abstract data are... |

33 | Semantics-based dataflow analysis of logic programs
- Marriott, Søndergaard
- 1989
(Show Context)
Citation Context ...s the one defined in [25]. Since this semantics is defined on a ground domain, the resulting abstract analysis is not able to capture computational properties related to the use of logical variables. =-=[46]-=- solves the above problem by using a non-ground domain for interpretations. However, the resulting semantics, which is the same as the C-semantics in [23], can only model the non-ground logical conseq... |

32 |
On derived dependencies and connected databases
- Dart
- 1991
(Show Context)
Citation Context ...ication with atoms in F ] (P ) we obtain information on which arguments will definitely become ground and on ground dependences between the arguments. The underlying analysis is similar to the one in =-=[15]-=-, which, however, is not explained in terms of abstract interpretation. In Section 4.1.1 we briefly discuss the use of our analysis to obtain call patterns information. Let us consider an abstract uni... |

31 |
Improving the Execution Speed of Compiled Prolog with Modes, Clause Selection, and Determinism
- Roy, Demoen, et al.
- 1987
(Show Context)
Citation Context ...d z to g. Thus, in this clause the procedure t is always called with a ground argument. This allows several optimizations to be performed in the code of p (for example elimination of backtrack points =-=[20]-=-). In the second clause, the unification of the goal ? \Gamma s(x; y) with s(ng; ng) 6 ? binds y to ng, thus showing that t can be called with a non-ground argument. Note that in this example, the cal... |

31 |
Specialisation of Prolog and FCP Programs Using Abstract Interpretation
- Gallagher, Codish, et al.
(Show Context)
Citation Context ...mation about the run-time behavior of a program (data-flow analysis), to be used by compilers (for error detection, code optimization [9, 11, 20, 36]) and, in general, by program manipulation systems =-=[27]-=-. An introduction to the subject of abstract interpretation in the field of logic and functional languages can be found in [1]. Abstract interpretation is inherently semantics sensitive. However, in m... |

29 | Galois connections and computer science applications - Melton, Schmidt, et al. - 1986 |

28 | Modelling Prolog control, in
- Barbuti, Codish, et al.
- 1992
(Show Context)
Citation Context ...nhance a given (Prolog) program with a transformation defined in terms of an instance of the cc paradigm so that the standard meaning of the enhanced program reflects the required control information =-=[2]-=-. This approach to Prolog analysis, needs a richer abstract interpretation technique, general enough to handle the constraint logic programming paradigm. In its present form, the approach can be insta... |

27 | Déjà vu in fixpoints of logic programs
- Maher, Ramakrishnan
- 1989
(Show Context)
Citation Context ...s can be summarized in a suitable graph notation. Then, the abstract unification can be specialized in a very efficient way, as a simple data dependences calculus, whose principles were introduced by =-=[15, 41]-=-. 25 We propose a new abstract domain of atoms which is isomorphic to the abstract base. Dependence information is represented by means of an hypergraph notation. The resulting analysis is more concis... |

26 |
A new declarative semantics for logic languages
- FALASCHI, LEVI, et al.
- 1988
(Show Context)
Citation Context ... Herbrand model, being defined on ground atoms only, does not allow to model correctly the concept of logical variable which is essential in describing properties like modes and aliasing [37, 45]. In =-=[22, 23, 24]-=- a model-theoretic and a fixpoint semantics is defined which capture (non-ground) computed answer substitutions. The corresponding immediate consequences operator operates on a domain composed of grou... |

25 |
On the Correctness and Efficiency of Independent And-Parallelism
- Hermenegildo, Rossi
- 1989
(Show Context)
Citation Context ...w abstract information is represented is central in abstract interpretation. Program analysis often requires to capture the interaction between abstract terms, like sharing and functional dependences =-=[28, 30, 31, 32, 50, 61]-=-. An equivalence relation on abstract atoms A characterizes such properties. Example 3.2 Let us consider the abstract universe of terms defined with respect to the following equivalence relation t 1st... |

23 |
Flow analysis of Prolog programs
- Mannila, Ukkonen
- 1987
(Show Context)
Citation Context |

22 |
Abstract interpretation of logic programs: an abstract domain for groundness, sharing, freeness and compoundness analysis
- Cortesi, File
- 1991
(Show Context)
Citation Context ...e of terms. We want to define it as composed of equivalence classes corresponding to the sets of (definitely) ground and (possibly) non-ground terms. Ground dependence analysis (like sharing analysis =-=[12, 43, 57]-=-) requires variable information for each non-ground concrete term. The equivalence relationst is defined as follows 8t 1 ; t 2 2 U P : t 1st t 2 iff var(t 1 ) = var(t 2 ). Each equivalence class can b... |

19 |
A bottom-up polymorphic type inference in logic programming
- Barbuti, Giacobazzi
- 1992
(Show Context)
Citation Context ...nat; char; errg. In the abstract universe, terms are then approximated by their type structure. An extension to type polymorphism, by a suitable partitioning of the universe of terms, is presented in =-=[3]-=-. The abstract domain of terms can be a non-flat one. If variables are considered [3] the partial ordering relations(less instantiated than) on concrete terms (up to renaming) can be abstracted in ord... |

17 |
Polymorphic type inference in prolog by abstract interpretation
- Horiuchi, Kanamori
- 1987
(Show Context)
Citation Context ...finite, domain. Its goal is to collect static (compile-time) information about the run-time behavior of a program (data-flow analysis), to be used by compilers (for error detection, code optimization =-=[9, 11, 20, 36]-=-) and, in general, by program manipulation systems [27]. An introduction to the subject of abstract interpretation in the field of logic and functional languages can be found in [1]. Abstract interpre... |

13 |
An Introduction to Abstract Interpretation
- Abramski, Hankin
- 1987
(Show Context)
Citation Context ...zation [9, 11, 20, 36]) and, in general, by program manipulation systems [27]. An introduction to the subject of abstract interpretation in the field of logic and functional languages can be found in =-=[1]-=-. Abstract interpretation is inherently semantics sensitive. However, in many cases the result is an ad-hoc algorithm (see for example [8]). Alternatively, the abstract interpretation is explicitly ba... |

13 | Detecting Determinate Computation by Bottom-Up Abstract Interpretation
- Giacobazzi, Ricci
- 1992
(Show Context)
Citation Context ...ain information about the ground dependences between the arguments of the goals. There are further applications of the ground dependence analysis by means of the same abstract data representation. In =-=[28, 29]-=- the previous dataflow analysis is enhanced by means of labeled hypergraphs. Deterministic dependences [29] can then be exploited simply by adding a suitable set of labels to each hyperarc, without ch... |

13 |
An Algebraic Framework for Abstract Interpretation of Definite Programs
- KBMP, RINGWOOD
- 1990
(Show Context)
Citation Context ... is the least Herbrand model, being defined on ground atoms only, does not allow to model correctly the concept of logical variable which is essential in describing properties like modes and aliasing =-=[37, 45]-=-. In [22, 23, 24] a model-theoretic and a fixpoint semantics is defined which capture (non-ground) computed answer substitutions. The corresponding immediate consequences operator operates on a domain... |

8 |
A Complete Framework for the Abstract Interpretation of Logic Programs: Theory and Applications
- Corsini, File
- 1989
(Show Context)
Citation Context ...finite, domain. Its goal is to collect static (compile-time) information about the run-time behavior of a program (data-flow analysis), to be used by compilers (for error detection, code optimization =-=[9, 11, 20, 36]-=-) and, in general, by program manipulation systems [27]. An introduction to the subject of abstract interpretation in the field of logic and functional languages can be found in [1]. Abstract interpre... |

8 |
Pipeline Optimizations in And-parallelism by Abstract Interpretation
- GIACOBAZZI, RICCI
- 1990
(Show Context)
Citation Context ...w abstract information is represented is central in abstract interpretation. Program analysis often requires to capture the interaction between abstract terms, like sharing and functional dependences =-=[28, 30, 31, 32, 50, 61]-=-. An equivalence relation on abstract atoms A characterizes such properties. Example 3.2 Let us consider the abstract universe of terms defined with respect to the following equivalence relation t 1st... |

6 |
Recognizing non-floundering logic programs and goals
- Barbuti, Martelli
- 1990
(Show Context)
Citation Context ...ramework. Some new applications of the framework are mentioned at the end of Section 4.1. 4.1 Ground Dependence Analysis Ground analysis has been considered by several authors in a top-down framework =-=[6, 16, 19, 43, 48, 35]-=-. Most of the above papers are concerned with groundness analysis for code optimization. Thus the emphasis is on obtaining information about call patterns. Our analysis collects goal independent infor... |

6 |
Galois Connections
- Herrlich, Husek
- 1985
(Show Context)
Citation Context ...and the abstract semantics was established in [13] by defining a pair of functions ff and fl (abstraction and concretization), which form a Galois connection between (D ] P ;s] D P ) and (D P ; D P ) =-=[33, 49, 54]-=-. This notion allows us to formally handle the correctness condition on the abstract interpretation framework [5]. Formally, an abstract interpretation scheme [13, 45] is a tuple h(D P ; D P ) ; E P ;... |

5 | Generalized Horn Clause Programs
- Debray, Ramakrishnan
- 1991
(Show Context)
Citation Context ... properties, i.e. abstract computed answer substitutions. Our abstract immediate consequences operators can be viewed as instances of a more general operator whose algebraic properties are defined in =-=[17]-=-. This characterization establishes a connection between fixpoint and transitive closure computations, thus allowing algorithms developed in the last area to be considered for bottom-up analysis. 6 Co... |

4 |
A Structured Approach to Semantics Correctness
- Barbuti, Martelli
- 1983
(Show Context)
Citation Context ...on), which form a Galois connection between (D ] P ;s] D P ) and (D P ; D P ) [33, 49, 54]. This notion allows us to formally handle the correctness condition on the abstract interpretation framework =-=[5]-=-. Formally, an abstract interpretation scheme [13, 45] is a tuple h(D P ; D P ) ; E P ; (D ] P ;s] D P ) ; E ] P ; ff ; fli such that 1. (D P ; D P ) and (D ] P ;s] D P ) are complete lattices, 7 2. E... |

3 |
The mythical free lunch: Notes on the complexity/precision tradeoff in dataflowanalysis of logic programs
- Debray
- 1991
(Show Context)
Citation Context ...or per predicate symbol [19, 47]. This assumption is reasonable if we assume that in most of the real programs, specific predicate arguments are used with the same mode or type structure. As shown in =-=[18]-=-, this technique may lead to a considerable simplification in the analysis complexity. Example 3.3 Consider an analysis which tries to infer the type of the arguments of a predicate symbol p, for all ... |

2 |
Finding Explicit Representations for Subsets of the Herbrand Universe
- Marriott
- 1988
(Show Context)
Citation Context ... the atoms in the program. We can classify this kind of analysis as a type inference analysis. We can find some interesting applications for program specialization to most specific logic programs, in =-=[44]-=-. Let us consider the function depth : TCons (V ar) ! !, such that depth(t) = 8 ? ! ? : 1 if t is a constant or a variable max(depth(t 1 ); :::; depth(t n )) + 1 if t = f(t 1 ; :::; t n ) and let us c... |

1 |
A Declarative Abstract Semantics for Logic Programs
- Barbuti, Giacobazzi, et al.
- 1989
(Show Context)
Citation Context ...(g); p(ng); q(g); q(ng)g in our approach. As we can observe, the abstract models we obtain are richer than the ones based on different semantics definitions. The semantics defined in [23] was used in =-=[4]-=- (an earlier version of our framework) and independently used in [10, 37]. [10] extends our approach with an elegant mechanism to compute call patterns in a bottom-up way, by using program transformat... |

1 |
Efficient Management of Backtacking in AND-Parallelism
- Hermenegildo, Nasr
- 1986
(Show Context)
Citation Context |