Results 1 -
8 of
8
Inference of Well-typings for Logic Programs with Application to Termination Analysis
, 2005
"... This paper develops a method to infer a polymorphic well-typing for a logic program. One of the main motivations is to contribute to a better automation of termination analysis in logic programs, by deriving types from which norms can automatically be constructed. Previous work on type-based termina ..."
Abstract
-
Cited by 11 (6 self)
- Add to MetaCart
This paper develops a method to infer a polymorphic well-typing for a logic program. One of the main motivations is to contribute to a better automation of termination analysis in logic programs, by deriving types from which norms can automatically be constructed. Previous work on type-based termination analysis used either types declared by the user, or automatically generated monomorphic types describing the success set of predicates. Declared types are typically more precise and result in stronger termination conditions than those obtained with inferred types. Our type inference procedure involves solving set constraints generated from the program and derives a well-typing in contrast to a success-set approximation. Experiments show that our automatically inferred well-typings are close to the declared types and thus result in termination conditions that are as good as those obtained with declared types for all our experiments to date. We describe the method, its implementation and experiments with termination analysis based on the inferred types.
Binding-Time Analysis for Mercury
- 16th International Conference on Logic Programming, pages 500 { 514
, 1999
"... . In this paper, we describe a binding-time analysis (BTA) for a statically typed and strongly moded pure logic programming language, in casu Mercury. Binding-time analysis is the key concept in achieving o-line program specialisation: the analysis starts from a description of the program's inpu ..."
Abstract
-
Cited by 8 (4 self)
- Add to MetaCart
. In this paper, we describe a binding-time analysis (BTA) for a statically typed and strongly moded pure logic programming language, in casu Mercury. Binding-time analysis is the key concept in achieving o-line program specialisation: the analysis starts from a description of the program's input available for specialisation, and propagates this information throughout the program, deriving directives for when and how to perform specialisation. 1
Fully automatic binding-time analysis for Prolog
- Proceedings LOPSTR 2004, LNCS 3573
, 2004
"... Abstract. Offline partial evaluation techniques rely on an annotated version of the source program to control the specialisation process. These annotations guide the specialisation and ensure the termination of the partial evaluation. We present an algorithm for generating these annotations automati ..."
Abstract
-
Cited by 4 (2 self)
- Add to MetaCart
Abstract. Offline partial evaluation techniques rely on an annotated version of the source program to control the specialisation process. These annotations guide the specialisation and ensure the termination of the partial evaluation. We present an algorithm for generating these annotations automatically. The algorithm uses state-of-the-art termination analysis techniques, combined with a new type-based abstract interpretation for propagating the binding types. This algorithm has been implemented as part of the logen partial evaluation system, along with a graphical annotation visualiser and editor, and we report on the performance of the algorithm for a series of benchmarks. 1
Inferring Polymorphic Types from Logic Programs
- Proc. of the Int’l Symposium on Logic-based Program Synthesis and Transformation (LOPSTR’04). Springer LNCS
, 2005
"... Abstract. This extended abstract sketches work in progress on how to infer polymorphic types from logic programs. Type information can contribute to a better automation of termination analysis. However, as sketched in the introduction, the monomorphic types describing the success set of predicates, ..."
Abstract
-
Cited by 1 (0 self)
- Add to MetaCart
Abstract. This extended abstract sketches work in progress on how to infer polymorphic types from logic programs. Type information can contribute to a better automation of termination analysis. However, as sketched in the introduction, the monomorphic types describing the success set of predicates, as derived by current inference systems, result in weaker termination conditions than those obtainable with declared types. The analysis of a simple example indicates that the polymorphic types, as inferred in this paper, can contribute to stronger termination conditions. In the remainder of this extended abstract, a sketch is given of a procedure to perform polymorphic type inference. The starting point is a more general notion of type rule that also allows both types and type variables as options in the right hand side. 1
Termination Analysis of Typed Logic Programs
, 2003
"... In this paper we show how we can use size and groundness analyses lifted to regular and (polymorphic) Hindley/Milner typed logic programs to determine more accurate termination of (type correct) programs. Type information for programs may be either inferred automatically or declared by the programme ..."
Abstract
- Add to MetaCart
In this paper we show how we can use size and groundness analyses lifted to regular and (polymorphic) Hindley/Milner typed logic programs to determine more accurate termination of (type correct) programs. Type information for programs may be either inferred automatically or declared by the programmer. The analysis of the typed logic programs is able to completely reuse a framework for termination analysis of untyped logic programs by using abstract compilation of the type abstraction. We de ne a methodology for mapping a typed logic program to a type separated CLP(N) program that allows us to automatically determine termination characteristics of the original program. We demonstrate how the approach is able to prove termination of programs which the untyped analysis can not.
Improving PARMA trailing
, 2004
"... Taylor introduced a variable binding scheme for logic variables in his PARMA system, that uses cycles of bindings rather than the linear chains of bindings used in the standard WAM representation. Both the HAL and dProlog languages make use of the PARMA representation in their Herbrand constraint so ..."
Abstract
- Add to MetaCart
Taylor introduced a variable binding scheme for logic variables in his PARMA system, that uses cycles of bindings rather than the linear chains of bindings used in the standard WAM representation. Both the HAL and dProlog languages make use of the PARMA representation in their Herbrand constraint solvers. Unfortunately, PARMA's trailing scheme is considerably more expensive in both time and space consumption. The aim of this paper is to present several techniques that lower the cost. First, we
Automated Termination Proofs for Logic Programs by Term Rewriting
"... There are two kinds of approaches for termination analysis of logic programs: “transformational” and “direct ” ones. Direct approaches prove termination directly on the basis of the logic program. Transformational approaches transform a logic program into a term rewrite system (TRS) and then analyze ..."
Abstract
- Add to MetaCart
There are two kinds of approaches for termination analysis of logic programs: “transformational” and “direct ” ones. Direct approaches prove termination directly on the basis of the logic program. Transformational approaches transform a logic program into a term rewrite system (TRS) and then analyze termination of the resulting TRS instead. Thus, transformational approaches make all methods previously developed for TRSs available for logic programs as well. However, the applicability of most existing transformations is quite restricted, as they can only be used for certain subclasses of logic programs. (Most of them are restricted to well-moded programs.) In this paper we improve these transformations such that they become applicable for any definite logic program. To simulate the behavior of logic programs by TRSs, we slightly modify the notion of rewriting by permitting infinite terms. We show that our transformation results in TRSs which are indeed suitable for automated termination analysis. In contrast to most other methods for termination of logic programs, our technique is also sound for logic programming without occur check, which is typically used in practice. We implemented our approach in the termination prover

