This paper presents a new notion of typing for logic programs which generalizes the notion of directional types. The generation of type dependencies for a logic program is fully automatic and optimal with respect to a given domain of types. The analysis method is based on a novel combination of program abstraction and ACIunification. The method is both theoretically clean and easy to implement using general purpose tools. Type dependencies are obtained by abstracting programs, replacing concrete terms by type expressions, and evaluating the meaning of the abstract programs using a standard bottom-up interpreter for logic programs enhanced by ACI-unification. Efficiency is maintained by choosing a non-ground semantics which results in a concise representation for types and also contributes to the persistence of analyses to changes in the underlying domain of types. The proposed method has been fully implemented and the experimental results are promising.
|
1654
|
Foundations of Logic Programming
– Lloyd
- 1984
|
|
1266
|
Abstract interpretation : a unified lattice model for the static analysis of programs by construction or approximation of fixpoints
– Cousot, Cousot
- 1977
|
|
556
|
The Art of Prolog
– Sterling, Shapiro
- 1986
|
|
387
|
Logic programming
– Apt
- 1990
|
|
340
|
A lattice-theoretical fixed point theorem and its applications
– Tarski
- 1955
|
|
254
|
Magic Sets and Other Strange Ways to Implement Logic Programs
– Bancilhon, Maier, et al.
- 1986
|
|
159
|
Unification theory
– Baader, Snyder
- 2001
|
|
127
|
Semantic domains
– Gunter, Scott
- 1990
|
|
114
|
The s-semantics approach: Theory and applications
– Bossi, Gabrielli, et al.
- 1994
|
|
112
|
Declarative modeling of the operational behavior of logic languages
– Falaschi, Levi, et al.
- 1989
|
|
107
|
de Waal. Fast and Precise Regular Approximations of Logic Programs
– Gallagher, A
- 1994
|
|
93
|
Logic programs as types for logic programs
– Frühwirth, Shapiro, et al.
- 1991
|
|
88
|
Static analysis of logic programs for independent AND-parallelism
– Jacobs, Langen
- 1992
|
|
70
|
Global Flow Analysis as a Practical Compilation Tool
– Hermenegildo, Warren, et al.
- 1992
|
|
68
|
A unification algorithm for associative-commutative functions
– Stickel
- 1981
|
|
67
|
A Model-Theoretic Reconstruction of the Operational Semantics of Logic Programs
– Falaschi, Levi, et al.
- 1993
|
|
57
|
Bottom-up abstract interpretation of logic programs
– Codish, Dams, et al.
- 1994
|
|
51
|
A framework of directionality for proving termination of logic programs
– Bronsard, Lakshman, et al.
- 1992
|
|
51
|
Precise and Efficient Groundness Analysis for Logic Programs
– Marriott, Sndergaard
- 1993
|
|
37
|
Directional type checking of logic programs
– Aiken, Lakshman
- 1994
|
|
37
|
Deriving Polymorphic Type Dependencies for Logic Programs Using Multiple Incarnations of Prop
– Codish, Demoen
- 1994
|
|
36
|
Analysing logic programs using "prop"-ositional logic programs and a magic wand
– Codish, Demoen
- 1995
|
|
34
|
A Generalized Semantics for Constraint Logic Programs
– Giacobazzi, Debray, et al.
- 1992
|
|
26
|
P.: Complexity of Unification Problems with Associativecommutative Operators
– Kapur, Narendran
- 1992
|
|
24
|
A type inference system for Prolog
– Xu, Warren
- 1988
|
|
24
|
Types and the intended meaning of logic programs
– Naish
- 1992
|
|
23
|
Declarative programming in Prolog
– Apt
- 1993
|
|
21
|
Abstract interpretation of logic programs: An abstract domain for groundness, sharing, freeness and compoundness analysis
– Cortesi, Fil'e
- 1991
|
|
20
|
Analyzing Logic Programs using "Prop"-ositional Logic Programs and a Magic Wand
– Codish, Demoen
- 1995
|
|
19
|
A Bottom-up Polymorphic Type Inference in Logic Programming
– Barbuti, Giacobazzi
- 1992
|
|
19
|
Adventures in Associative-Commutative Unification
– Lincoln, Christian
- 1989
|
|
18
|
Two aspects of directional types
– Boye, Maluszynski
- 1995
|
|
17
|
Efficient Goal Directed Bottom-up Evaluation of Logic Programs
– Codish
|
|
17
|
Integrating modes and subtypes into a Prolog type-checker
– Rouzaud, Nguyen-Phuong
- 1992
|
|
15
|
Directional Types in Logic Programming
– Boye
- 1996
|
|
13
|
An application of constraint propagation to data-flow analysis
– Bagnara, Giacobazzi, et al.
- 1993
|
|
13
|
Inference of polymorphic types for logic programs
– Pyo, Reddy
- 1989
|
|
12
|
An algebraic approach to sharing analysis of logic programs
– Codish, Lagoon, et al.
- 1997
|
|
12
|
A first-order theory of types and polymorphism in logic programming
– Kifer, Wu
- 1991
|
|
7
|
Type Inference by Program Transformation and Partial Evaluation
– Fruhwirth
- 1989
|
|
4
|
A proof method for run-time properties of Prolog programs
– Pedreschi
- 1994
|
|
3
|
A directional type system for Prolog: Unifying notions of types and directionality
– Lakshman, Reddy, et al.
- 1994
|
|
2
|
General purpose semantic based analysis using XSB
– Codish, Demoen, et al.
- 1997
|
|
2
|
Logic program analysis using set logic programs
– Lagoon
- 1998
|