Results 1 -
5 of
5
Offline specialisation in Prolog using a hand-written compiler generator
, 2004
"... The so called âcogen approachâ to program specialisation, writing a compiler generator instead of a specialiser, has been used with considerable success in partial evaluation of both functional and imperative languages. This paper demonstrates that this approach is also applicable to partial eva ..."
Abstract
-
Cited by 38 (21 self)
- Add to MetaCart
The so called âcogen approachâ to program specialisation, writing a compiler generator instead of a specialiser, has been used with considerable success in partial evaluation of both functional and imperative languages. This paper demonstrates that this approach is also applicable to partial evaluation of logic programming languages, also called partial deduction. Self-application has not been as much in focus in logic programming as for functional and imperative languages, and the attempts to self-apply partial deduction systems have, of yet, not been altogether that successful. So, especially for partial deduction, the cogen approach should prove to have a considerable importance when it comes to practical applications. This paper first develops a generic offline partial deduction technique for pure logic programs, notably supporting partially instantiated datastructures via binding types. From this a very efficient cogen is derived, which generates very efficient generating extensions (executing up to several orders of magnitude faster than current online systems) which in turn perform very good and non-trivial specialisation, even rivalling existing online systems. All this is supported by extensive benchmarks. Finally, it is shown how the cogen can be extended to directly support a large part of Prologâs declarative and non-declarative features and how semi-online specialisation can be efficiently integrated.
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
Reuse of Results in Termination Analysis of Typed Logic Programs
- In Static Analysis, 9th International Symposium
, 2002
"... Recent works by the authors address the problem of automating the selection of a candidate norm for the purpose of termination analysis. These works illustrate a powerful technique in which a collection of simple type-based norms, one for each data type in the program, are combined together to provi ..."
Abstract
-
Cited by 7 (1 self)
- Add to MetaCart
Recent works by the authors address the problem of automating the selection of a candidate norm for the purpose of termination analysis. These works illustrate a powerful technique in which a collection of simple type-based norms, one for each data type in the program, are combined together to provide the candidate norm. This paper extends these results by investigating type polymorphism. We show that by considering polymorphic types we reduce, without sacrificing precision, the number of type-based norms which should be combined to provide the candidate norm. Moreover, we show that when a generic polymorphic typed program component occurs in one or more specific type contexts, we need not reanalyse it. All of the information concerning its termination and its e ect on the termination of other predicates in that context can be derived directly from the context independent analysis of that component based on norms derived from the polymorphic types.
Proving Termination With Adornments
- IN PROC. 14TH ICLP
, 1997
"... Proving termination is one of the most intriguing problems of program verification. Recently, the study of termination of numerical programs led to the emerging of the adorning technique. This approach is based on the idea of distinguishing between different subsets of values for variables, and d ..."
Abstract
-
Cited by 2 (0 self)
- Add to MetaCart
Proving termination is one of the most intriguing problems of program verification. Recently, the study of termination of numerical programs led to the emerging of the adorning technique. This approach is based on the idea of distinguishing between different subsets of values for variables, and deriving piecewise level mappings based on these subsets. In the current paper we generalise the technique and consider symbolical computations. Our experience suggests that such a generalisation will allow automated tools to verify termination of examples that remain at the moment beyond their abilities.
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.

