289 research outputs found

    RedAlert: Determinacy Inference for Prolog

    Get PDF
    This paper revisits the problem of determinacy inference addressing the problem of how to uniformly handle cut. To this end a new semantics is introduced for cut, which is abstracted to systematically derive a backward analysis that derives conditions sufficient for a goal to succeed at most once. The method is conceptionally simpler and easier to implement than existing techniques, whilst improving the latter's handling of cut. Formal arguments substantiate correctness and experimental work, and a tool called 'RedAlert' demonstrates the method's generality and applicability.Comment: Theory and Practice of Logic Programming, 2011, 27th Int'l. Conference on Logic Programming (ICLP'11) Special Issue, volume 11, issue 4-

    Retractions in comparing PROLOG semantics

    Get PDF
    We present an operational model O and a continuation based denotational model D for a uniform variant of PROLOG, including the cut operator. The two semantical definitions make use of higher order transformations Phi and Psi, respectively. We prove O and D equivalent in a novel way by comparing yet another pair of higher order transformations Phi~ and Psi~, that yield Phi and Psi, respectively, by application of a suitable abstraction operator

    Operational and Goal-Independent Denotational Semantics for Prolog with Cut

    Get PDF
    In this paper we propose an operational and a denotational semantics for Prolog. We deal with the control rules of Prolog and the cut operator. Our denotational semantics provides a goal--independent semantics. This means that the behaviour of a goal in a program is defined as the evaluation of the goal in the denotation (semantics) of the program. We show how our denotational semantics can be specialised into a computed answer semantics and into a call pattern semantics. Our work provides a basis for a precise abstract interpretation of Prolog programs

    Comparative metric semantics for concurrent Prolog

    Get PDF
    AbstractThis paper shows the equivalence of two semantics for a version of Concurrent Prolog with non-flat guards: an operational semantics based on a transition system and a denotational semantics which is a metric semantics (the domains are metric spaces). We do this in the following manner. First a uniform language L is considered, that is a language where the atomic actions have arbitrary interpretations. For this language we define an operational and a denotational semantics, and we prove that the denotational semantics is correct with respect to the operational semantics. This result relies on Banach's fixed point theorem. Techniques stemming from imperative languages are used. Then we show how to translate a Concurrent Prolog program to a program in L by selecting certain basic sets for L and then instantiating the interpretation function for the atomic actions. In this way we induce the two semantics for Concurrent Prolog and the equivalence between the two semantics
    • …
    corecore