Academia.edu no longer supports Internet Explorer.
To browse Academia.edu and the wider internet faster and more securely, please take a few seconds to upgrade your browser.
1989, ACM Transactions on Programming Languages and Systems
…
12 pages
1 file
In this paper we propose a denotational semantics for Prolog and an approach to the abstract interpretation of Prolog programs; we deal with the control rules of Prolog and the cut operator. Moreover, we get a simple denotation for negation as nite failure. The abstract analysis is proposed both for computed answers analysis and for call patterns analysis. In both cases the abstract semantics is nitely computable. Two examples show the usefulness of our approach for the analysis of Prolog programs.
New Generation Computing, 1992
To relate operational semantics of logic programs to its declarative semantics, we have to rely on SLD-trees. But this form of operational semantics does not make it easy to relate execution behaviour to program structure. The reason is that the traversal of SLD-trees decomposes in a way that is different from the decomposition (which is by disjunction and conjunction) of programs. We propose SLD-contours, a variant of SLD-trees, that are, like programs, built up out of simpler components by means of disjunction and conjunction. The traversal of SLD-trees carries over to the traversal of SLD-contours in such a way that the trace events of the Box Model (Try, Succeed, Retry, Fail) are reproduced in the same way as during the execution of the program. Thus SLD-contours relate the trace more closely to the program than SLD-trees. SLD-contours specify the trace more completely than the Box Model does. However, SLD-contours have the disadvantage that similar constructs are repeated. We introduce a way of collapsing repeated occurrences into a single one. The result is an elaboration of the existing Box Model. Hence we call them SLD-boxes. In this way, SLD-boxes connect the semantics of Prolog programs to the Box Model, the most widely used aid in tracing Prolog programs.
Science of Computer Programming, 1998
The coincidence of the declarative and procedural interpretations of logic programs does not apply to Prolog programs, due to the depth-first left-to-right evaluation strategy of Prolog interpreters. We propose a semantics for Prolog programs based on a four-valued logic. The semantics is based on a new concept of completion analogous to Clark's and it enjoys the nice properties of the declarative semantics of logic programming: existence of the least Herbrand model, equivalence of the model-theoretic and operational semantics. @ 1998 Elsevier Science B.V. All rights resewed.
HAL (Le Centre pour la Communication Scientifique Directe), 2009
The majority of abstract interpretation models defined for Prolog use abstract operations which do not have explicit counterpart in the SLD-resolution. We propose, in this paper, an operational semantics closely related to these models. We prove his equivalence with the SLDresolution and then we use it to prove the consistency of one of abstract semantics presents in 9].
The Journal of Logic Programming, 1992
1992
This paper proposes to specify semantic definitions for Prolog in terms of an oracle which provides information on which clauses are to be applied to resolve a given goal. The approach is quite general. It is applicable to pure Prolog to define both operational and declarative semantics; and can be viewed as a basis for both sequential and parallel implementations. Previous semantic definitions for Prolog typically attempt to encode the sequential depth-first search of the language into various mathematical frameworks. A clause is applied in such semantics only if it is chosen under the search strategy. We prefer instead to specify in a more declarative way the condition upon which a clause is to be applied. The decision whether or not to apply a clause may be viewed as a query to an oracle which may be specified from within the semantics or reasoned about from outside. This approach results in simple and concise semantic definitions which are more useful for arguing the correctness of program transformations and providing the basis for abstract interpretations than previous proposals.
PPDP
Bousi∼Prolog is a fuzzy logic programming language with an operational semantics which is an adaptation of the SLD resolution principle, where classical unification has been replaced by a fuzzy unification algorithm based on proximity relations. Hence, it is a programming language well suited for dealing with uncertainty and approximate reasoning. There are several practical applications where Bousi∼Prolog can be useful: flexible query answering; advanced pattern matching; information retrieval where textual information is selected or analyzed using an ontology; text cataloging and analysis; etc. In this paper we give a model-theoretic semantics for a pure subset of this language: we formalize the notion of least fuzzy Herbrand model as the declarative semantics for definite programs. We prove various important properties of these models. Finally we define an immediate consequences operator, which is proved monotonous and continuous, obtaining a fixpoint characterization of the least fuzzy Herbrand model.
Two main aspects of Partial Evaluation for Prolog programs are considered: treatment of cuts and control of recursion. The analysis about cut is exhaustive: we consider occurrences of cut within both conjunctions and disjunctions. We show which restrictions are necessary to safely deal with cut in Partial Evaluation and which transformations are allowed. We dene a set of conditions for compile-time execution and remotion of cuts. The safety of these conditions is formally proved. Some interesting results about the impact of mode inference techniques within this framework are nally drawn. As for control issues, we address a new approach to the problem of detecting innite derivation paths. It is based on a theoretical characterization of non-termination and provides a general technique whose eectiv eness does not depend on the structure of program domains.
1994
A novel abstract interpretation framework is introduced, which captures Prolog depth-rst strategy and the cut operation. The framework is based on a new conceptual idea, the notion of substitution sequences, and the traditional xpoint approach to abstract interpretation. It broadens the class of analyses that are amenable in practice to abstract interpretation and re nes the precision of existing analyses. Its practicability is demonstrated in a companion paper 4]. This paper focuses on theoretical foundations.
dectau.uclm.es
Bousi∼Prolog is an extension of the standard Prolog language aiming at to make more flexible the query answering process and to deal with vagueness applying declarative techniques. In this paper we precise a model-theoretic semantics for a pure subset of this language, we recall both the WSLD-resolution principle and a similarity-based unification algorithm which is the basis of its operational mechanism and then we prove the soundness of WSLD-resolution.
Programming Languages and Systems — ESOP '96, 1996
interpretation-based data-flow analysis of logic programs is, at this point, relatively well understood from the point of view of general frameworks and abstract domains. On the other hand, comparatively little attention has been given to the problems which arise when analysis of a full, practical dialect of the Prolog language is attempted, and only few solutions to these problems have been proposed to date. Existing proposals generally restrict in one way or another the classes of programs which can be analyzed. This paper attempts to fill this gap by considering a full dialect of Prolog, essentially the recent ISO standard, pointing out the problems that may arise in the analysis of such a dialect, and proposing a combination of known and novel solutions that together allow the correct analysis of arbitrary programs which use the full power of the language.
Loading Preview
Sorry, preview is currently unavailable. You can download the paper by clicking the button above.
Theory and Practice of Logic Programming, 2002
Theory and Practice of Logic Programming
Lecture Notes in Computer Science, 1993
Lecture Notes in Computer Science, 1996
Journal of Logic, Language and Information, 1992
The Journal of Logic Programming, 1986
The Journal of Logic Programming, 1986
The Journal of Logic Programming, 1984
Acta Informatica, 1995
Lecture Notes in Computer Science, 2001
Theory and Practice of Logic Programming, 2012
ACM Transactions on Programming Languages and Systems, 1994
IEEE Transactions on Software Engineering, 1990