## Efficiently generating efficient generating extensions in Prolog

### Cached

### Download Links

- [repository.readscheme.org]
- [www.cs.kuleuven.ac.be]
- [www.stups.uni-duesseldorf.de]
- [www.stups.uni-duesseldorf.de]
- DBLP

### Other Repositories/Bibliography

Citations: | 16 - 13 self |

### BibTeX

@MISC{Jørgensen_efficientlygenerating,

author = {Jesper Jørgensen and Michael Leuschel},

title = {Efficiently generating efficient generating extensions in Prolog},

year = {}

}

### OpenURL

### Abstract

### Citations

1855 |
Foundations of Logic Programming
- Lloyd
- 1987
(Show Context)
Citation Context ...erlining the efficiency of the cogen. We conclude with some discussions in Sect. 5. 2 Off-Line Partial Deduction Throughout this paper, we suppose familiarity with basic notions in logic programming (=-=[35]-=-). Notational conventions are standard and self-evident. In particular, in programs, we denote variables through strings starting with (or usually just consisting of) an upper-case symbol, while the n... |

639 |
Partial Evaluation and Automatic Program Generation. Available online: http://www.itu.dk/people/sestoft/pebook
- Jones, Gomard, et al.
- 1993
(Show Context)
Citation Context ...n turn yield (for some examples at least) very good and non-trivial specialisation. 1 Introduction Partial evaluation has over the past decade received considerable attention both in functional (e.g. =-=[23]-=-), imperative (e.g. [1]) and logic programming (e.g. [13, 26, 42]). In the context of pure logic programs, partial evaluation is often referred to as partial deduction, the term partial evaluation bei... |

526 | Program Analysis and Specialization for the C Programming Language
- Andersen
- 1994
(Show Context)
Citation Context ...xamples at least) very good and non-trivial specialisation. 1 Introduction Partial evaluation has over the past decade received considerable attention both in functional (e.g. [23]), imperative (e.g. =-=[1]-=-) and logic programming (e.g. [13, 26, 42]). In the context of pure logic programs, partial evaluation is often referred to as partial deduction, the term partial evaluation being reserved for the tre... |

286 | Abstract Interpretation and Applications to Logic Programs - Cousot, Cousot - 1994 |

239 |
Partial evaluation in logic programming
- Lloyd, Shepherdson
- 1991
(Show Context)
Citation Context ...o be the set of clauses {Aθ1 ← G1, . . . , Aθn ← Gn}. We also define the set of leaves, leaves(τ), to be the atoms occurring in the goals G1, . . . , Gn. Partial deduction, as defined for instance in =-=[36]-=- or [4], uses the resultants for a given set of atoms A to construct the specialised program (and for each atom in A a different specialised predicate definition will be generated). Under the conditio... |

236 | Tutorial notes on partial evaluation
- Consel, Danvy
- 1993
(Show Context)
Citation Context ...oper specialisation phase, often to the point of making it completely trivial. 2 I.e. abstract(∅) = ∅ and abstract(S ∪ S ′ ) = abstract(S) ∪ abstract(S ′ ).sPartial evaluation of functional programs (=-=[10, 23]-=-) has mainly stressed offline approaches, while supercompilation of functional ([47, 46]) and partial deduction of logic programs ([15, 45, 6, 9, 37, 38, 29, 33]) have concentrated on on-line control.... |

145 | Tutorial on specialisation of logic programs
- Gallagher
- 1993
(Show Context)
Citation Context ...te definition will be generated). Under the conditions stated in [36], namely closedness and independence, correctness of the specialised program is guaranteed. In a lot of practical approaches (e.g. =-=[12, 13, 15, 31, 28, 29]-=-) independence is ensured by using a renaming transformation which maps dependent atoms 0 A B ′ The function h : 2 to 2 is a homomorphism iff h(∅) = ∅ and h(S ∪ S ) = h(S) ∪ h(S ′ ). 1 A trivial SLDNF... |

139 | Transformation of logic programs: Foundations and techniques
- Pettorossi, Proietti
- 1994
(Show Context)
Citation Context ...on-trivial specialisation. 1 Introduction Partial evaluation has over the past decade received considerable attention both in functional (e.g. [23]), imperative (e.g. [1]) and logic programming (e.g. =-=[13, 26, 42]-=-). In the context of pure logic programs, partial evaluation is often referred to as partial deduction, the term partial evaluation being reserved for the treatment of impure logic programs. A convent... |

118 | Compile-time derivation of variable dependency using abstract interpretation - Muthukumar, Hermenegildo - 1992 |

117 | Automatic autoprojection of recursive equations with global variables and abstract data types - Bondorf, Danvy - 1991 |

116 |
MIX: a self-applicable partial evaluator for experiments
- Jones, Sestoft, et al.
- 1989
(Show Context)
Citation Context ...ams ([15, 45, 6, 9, 37, 38, 29, 33]) have concentrated on on-line control. (Some exceptions are [39, 31, 28].) The main reason for using the off-line approach is to achieve effective selfapplication (=-=[24]-=-). But the off-line approach is in general also more efficient, since many decisions concerning control are made before and not during specialisation. For the cogen approach to be efficient it is vita... |

102 | An Automatic Partial Evaluator for Full Prolog
- Sahlin
- 1991
(Show Context)
Citation Context ...pecialiser the more complex the specialisation process becomes, because the specialiser then has to handle these features as well. This is why so far no partial evaluator for full Prolog (like mixtus =-=[45]-=-, or paddy [43]) has been made effectively self-applicable. On the other hand a partial deducer which specialises only purely declarative logic programs (like sage in [18] or the system in [7]) has it... |

91 | Static analysis of logic programs for independent and parallelism - Jacobs, Langen - 1992 |

83 | Combined determination of sharing and freeness of program variables through abstract interpretation - Muthukumar, Hermenegildo |

77 | Global Flow Analysis as a Practical Compilation Tool
- Hermenegildo, Warren, et al.
- 1992
(Show Context)
Citation Context ... standard groundness analysis on a transformed version of the program to be specialised, we can come up with a reasonable BT A. More details, along with some initial experiments using the PLAI system =-=[19]-=-, can be found in [25]. On a slightly longer term one might try to extend the cogen and the bindingtime analysis to handle partially static structures. It also seems natural to investigate to what ext... |

73 | An algorithm of generalization in positive supercompilation
- Sørensen, Glück
- 1995
(Show Context)
Citation Context ...stract(∅) = ∅ and abstract(S ∪ S ′ ) = abstract(S) ∪ abstract(S ′ ).sPartial evaluation of functional programs ([10, 23]) has mainly stressed offline approaches, while supercompilation of functional (=-=[47, 46]-=-) and partial deduction of logic programs ([15, 45, 6, 9, 37, 38, 29, 33]) have concentrated on on-line control. (Some exceptions are [39, 31, 28].) The main reason for using the off-line approach is ... |

63 |
A general criterion for avoiding infinite unfolding during partial deduction
- Bruynooghe, Schreye, et al.
- 1992
(Show Context)
Citation Context ...∪ abstract(S ′ ).sPartial evaluation of functional programs ([10, 23]) has mainly stressed offline approaches, while supercompilation of functional ([47, 46]) and partial deduction of logic programs (=-=[15, 45, 6, 9, 37, 38, 29, 33]-=-) have concentrated on on-line control. (Some exceptions are [39, 31, 28].) The main reason for using the off-line approach is to achieve effective selfapplication ([24]). But the off-line approach is... |

63 |
The derivation of an algorithm for program specialisation
- Gallagher, Bruynooghe
- 1991
(Show Context)
Citation Context ...te definition will be generated). Under the conditions stated in [36], namely closedness and independence, correctness of the specialised program is guaranteed. In a lot of practical approaches (e.g. =-=[12, 13, 15, 31, 28, 29]-=-) independence is ensured by using a renaming transformation which maps dependent atoms 0 A B ′ The function h : 2 to 2 is a homomorphism iff h(∅) = ∅ and h(S ∪ S ) = h(S) ∪ h(S ′ ). 1 A trivial SLDNF... |

60 | Ensuring global termination of partial deduction while allowing flexible polyvariance
- Martens, Gallagher
- 1995
(Show Context)
Citation Context ...can distinguish between two different levels of control. The unfolding rule U controls the construction of the incomplete SLDNF-trees. This is called the local control (we will use the terminology of =-=[13, 38]-=-). The abstraction operation controls the construction of the set of atoms for which local SLDNFtrees are built. We will refer to this aspect as the global control. The control problems have been tack... |

59 | Efficient multi-level generating extensions for program specialization
- Glück, Jørgensen
- 1995
(Show Context)
Citation Context ...on principles was, in all probability, the system RedCompile for a dialect of Lisp [2]. Since then successful compiler generators have been written for many different languages and language paradigms =-=[44, 21, 22, 5, 1, 16]-=-. In the context of definite clause grammars and parsers based on them, the idea of hand writing the compiler generator has also been used in [40, 41]. 8 However it is not based on (off-line) partial ... |

48 |
Loop checking in partial deduction
- Bol
- 1993
(Show Context)
Citation Context ...∪ abstract(S ′ ).sPartial evaluation of functional programs ([10, 23]) has mainly stressed offline approaches, while supercompilation of functional ([47, 46]) and partial deduction of logic programs (=-=[15, 45, 6, 9, 37, 38, 29, 33]-=-) have concentrated on on-line control. (Some exceptions are [39, 31, 28].) The main reason for using the off-line approach is to achieve effective selfapplication ([24]). But the off-line approach is... |

48 | Global control for partial deduction through characteristic atoms and global trees
- Leuschel, Martens
- 1996
(Show Context)
Citation Context ...∪ abstract(S ′ ).sPartial evaluation of functional programs ([10, 23]) has mainly stressed offline approaches, while supercompilation of functional ([47, 46]) and partial deduction of logic programs (=-=[15, 45, 6, 9, 37, 38, 29, 33]-=-) have concentrated on on-line control. (Some exceptions are [39, 31, 28].) The main reason for using the off-line approach is to achieve effective selfapplication ([24]). But the off-line approach is... |

47 |
Projection Factorisation in Partial Evaluation
- Launchbury
- 1990
(Show Context)
Citation Context ...al? X a) (equal? X a))) and the residual program would be identical to the original program. One could say that our system allows divisions that are not uniformly congruent in the sense of Launchbury =-=[27]-=- and essentially, our system performs specialisation that a partial evaluation system for a functional language would need some form of driving to be able to do. Whether application of the cogen appro... |

46 | Meta-programming in logic programming
- HILL, GALLAGHER
- 1998
(Show Context)
Citation Context ...use the non-ground representation (and even a compiled version of it). This is in contrast to self-applicable partial deducers which must use the ground representation in order to be declarative (see =-=[20, 34, 18]-=-). In fact the non-ground representation executes several orders of magnitude faster than the ground representation (even after specialising, see [8]) and, as shown in [34], can be impossible to speci... |

43 |
An introduction to partial deduction
- Komorowski
- 1992
(Show Context)
Citation Context ...on-trivial specialisation. 1 Introduction Partial evaluation has over the past decade received considerable attention both in functional (e.g. [23]), imperative (e.g. [1]) and logic programming (e.g. =-=[13, 26, 42]-=-). In the context of pure logic programs, partial evaluation is often referred to as partial deduction, the term partial evaluation being reserved for the treatment of impure logic programs. A convent... |

39 |
De Schreye. Automatic finite unfolding using well-founded measures
- Martens, D
- 1996
(Show Context)
Citation Context ...DNF-tree which, in addition to success and failure leaves, may also contain leaves where no literal has been selected for a further derivation step. Leaves of the latter kind will be called dangling (=-=[37]-=-). In the context of partial deduction these incomplete SLDNF-trees are obtained by applying an unfolding rule, defined as follows. Definition 1. (Unfolding rule) An unfolding rule U is a function whi... |

36 |
Logimix: A self-applicable partial evaluator for Prolog
- Mogensen, Bondorf
- 1993
(Show Context)
Citation Context ...iking a delicate balance between the expressivity of the underlying language and the ease with which it can be specialised. Two approaches for logic programming languages along this line are [11] and =-=[39]-=-. However the specialisation in [11] is incorrect with respect to some of the extra-logical built-ins, leading to incorrect compilers and compiler generators when attempting self-application (a proble... |

33 |
A Self-Applicable Partial Evaluator for the Logic Programming Language Godel
- Gurr
(Show Context)
Citation Context ...for full Prolog (like mixtus [45], or paddy [43]) has been made effectively self-applicable. On the other hand a partial deducer which specialises only purely declarative logic programs (like sage in =-=[18]-=- or the system in [7]) has itself to be written purely declaratively leading to slow systems and impractical compilers and compiler generators. So far the only practical compilers and compiler generat... |

32 | Controlling conjunctive partial deduction of definite logic programs
- Gluck, Jrgensen, et al.
- 1996
(Show Context)
Citation Context ...ate to what extent more powerful control and specialisation techniques (like the unfold/fold transformations, [42]) can be incorporated into the cogen in the context of conjunctive partial deduction (=-=[32, 17]-=-). Acknowledgements We thank Maurice Bruynooghe, Bart Demoen, Danny De Schreye, André De Waal, Robert Glück, Gerda Janssens, Bern Martens, Torben Mogensen and Ulrich Neumerkel for interesting discussi... |

31 |
A partial evaluator, and its use as a programming tool
- Beckman, Haraldson, et al.
- 1976
(Show Context)
Citation Context ...stablish this. Related Work in Partial Evaluation The first hand-written compiler generator based on partial evaluation principles was, in all probability, the system RedCompile for a dialect of Lisp =-=[2]-=-. Since then successful compiler generators have been written for many different languages and language paradigms [44, 21, 22, 5, 1, 16]. In the context of definite clause grammars and parsers based o... |

30 |
A Partial Evaluation Procedure for Logic Programs
- Benkerimi, Lloyd
- 1990
(Show Context)
Citation Context ... set of clauses {Aθ1 ← G1, . . . , Aθn ← Gn}. We also define the set of leaves, leaves(τ), to be the atoms occurring in the goals G1, . . . , Gn. Partial deduction, as defined for instance in [36] or =-=[4]-=-, uses the resultants for a given set of atoms A to construct the specialised program (and for each atom in A a different specialised predicate definition will be generated). Under the conditions stat... |

29 |
Handwriting cogen to avoid problems with static typing
- Holst, Launchbury
- 1991
(Show Context)
Citation Context ...on principles was, in all probability, the system RedCompile for a dialect of Lisp [2]. Since then successful compiler generators have been written for many different languages and language paradigms =-=[44, 21, 22, 5, 1, 16]-=-. In the context of definite clause grammars and parsers based on them, the idea of hand writing the compiler generator has also been used in [40, 41]. 8 However it is not based on (off-line) partial ... |

27 |
Hand-writing program generator generators
- Birkedal, Welinder
- 1994
(Show Context)
Citation Context ...on principles was, in all probability, the system RedCompile for a dialect of Lisp [2]. Since then successful compiler generators have been written for many different languages and language paradigms =-=[44, 21, 22, 5, 1, 16]-=-. In the context of definite clause grammars and parsers based on them, the idea of hand writing the compiler generator has also been used in [40, 41]. 8 However it is not based on (off-line) partial ... |

25 |
Supporting transformations for the partial evaluation of logic programs
- Benkerimi, Hill
- 1993
(Show Context)
Citation Context ...e whose root is a dangling leaf. This restriction is necessary to obtain correct partial deductions. See also Definition 2 below.sto new predicate symbols. Adapted correctness results can be found in =-=[3]-=- (see also [32]). Renaming is often combined with argument filtering to improve the efficiency of the specialised program (see e.g. [14]). Closedness can be ensured by using the following outline of a... |

25 | A conceptual embedding of folding into partial deduction: Towards a maximal integration
- Leuschel, Schreye, et al.
- 1996
(Show Context)
Citation Context ...ate to what extent more powerful control and specialisation techniques (like the unfold/fold transformations, [42]) can be incorporated into the cogen in the context of conjunctive partial deduction (=-=[32, 17]-=-). Acknowledgements We thank Maurice Bruynooghe, Bart Demoen, Danny De Schreye, André De Waal, Robert Glück, Gerda Janssens, Bern Martens, Torben Mogensen and Ulrich Neumerkel for interesting discussi... |

24 | Ecological partial deduction: Preserving characteristic trees without constraints
- Leuschel
- 1995
(Show Context)
Citation Context ...te definition will be generated). Under the conditions stated in [36], namely closedness and independence, correctness of the specialised program is guaranteed. In a lot of practical approaches (e.g. =-=[12, 13, 15, 31, 28, 29]-=-) independence is ensured by using a renaming transformation which maps dependent atoms 0 A B ′ The function h : 2 to 2 is a homomorphism iff h(∅) = ∅ and h(S ∪ S ) = h(S) ∪ h(S ′ ). 1 A trivial SLDNF... |

23 | A Compiler Generator Produced by a Self-Applicable Specializer Can Have a Surprisingly Natural and Understandable Structure. 445--463. Partial Evaluation and Mixed
- Romanenko
- 1988
(Show Context)
Citation Context |

22 | Deriving A Fixpoint Computation Algorithm for Top-down Abstract Interpretation of Logic Programs - Muthukumar, Hermenegildo - 1990 |

20 |
Towards fast and declarative meta-programming
- Bowers, Gurr
- 1995
(Show Context)
Citation Context ...sentation in order to be declarative (see [20, 34, 18]). In fact the non-ground representation executes several orders of magnitude faster than the ground representation (even after specialising, see =-=[8]-=-) and, as shown in [34], can be impossible to specialise satisfactorily by partial deduction alone. (Note that even [39] uses a “mixed” representation approach [31, 20]). Although the Futamura project... |

19 | Partial deduction of the ground representation and its application to integrity checking
- Leuschel, Martens
- 1995
(Show Context)
Citation Context ...use the non-ground representation (and even a compiled version of it). This is in contrast to self-applicable partial deducers which must use the ground representation in order to be declarative (see =-=[20, 34, 18]-=-). In fact the non-ground representation executes several orders of magnitude faster than the ground representation (even after specialising, see [8]) and, as shown in [34], can be impossible to speci... |

18 |
A self-applicable partial evaluator and its use in incremental compilation, New Generation Computing 6
- Fujita, Furukawa
- 1988
(Show Context)
Citation Context ...ed by striking a delicate balance between the expressivity of the underlying language and the ease with which it can be specialised. Two approaches for logic programming languages along this line are =-=[11]-=- and [39]. However the specialisation in [11] is incorrect with respect to some of the extra-logical built-ins, leading to incorrect compilers and compiler generators when attempting self-application ... |

17 |
Some low-level transformations for logic programs
- Gallagher, Bruynooghe
- 1990
(Show Context)
Citation Context ...w predicate symbols. Adapted correctness results can be found in [3] (see also [32]). Renaming is often combined with argument filtering to improve the efficiency of the specialised program (see e.g. =-=[14]-=-). Closedness can be ensured by using the following outline of a partial deduction algorithm (similar to the ones used in e.g. [12, 13, 29, 30]). Algorithm 1 (Partial deduction) 1. Let S0 be the set o... |

17 | Towards creating specialised integrity checks through partial evaluation of meta-interpreters
- Leuschel, Schreye
- 1995
(Show Context)
Citation Context ...tation (even after specialising, see [8]) and, as shown in [34], can be impossible to specialise satisfactorily by partial deduction alone. (Note that even [39] uses a “mixed” representation approach =-=[31, 20]-=-). Although the Futamura projections focus on how to generate a compiler from an interpreter, the projections of course also apply when we replace the interpreter by some other program. In that case t... |

16 | The PADDY partial deduction system
- Prestwich
- 1992
(Show Context)
Citation Context ...more complex the specialisation process becomes, because the specialiser then has to handle these features as well. This is why so far no partial evaluator for full Prolog (like mixtus [45], or paddy =-=[43]-=-) has been made effectively self-applicable. On the other hand a partial deducer which specialises only purely declarative logic programs (like sage in [18] or the system in [7]) has itself to be writ... |

14 | Analysing logic programs using \Prop"-ositional logic programs and a magic wand - Codish, Demoen - 1993 |

13 | Partial evaluation of the “real thing
- Leuschel
- 1994
(Show Context)
Citation Context ...in [11] is incorrect with respect to some of the extra-logical built-ins, leading to incorrect compilers and compiler generators when attempting self-application (a problem mentioned in [7], see also =-=[39, 28]-=-). logimix [39] does not share this problem, but gives only modest speedups (when compared to results for functional programming languages, see [39]) when self-applied. The actual creation of the coge... |

13 | An almost perfect abstraction operation for partial deduction using characteristic trees
- Leuschel, Schreye
- 1995
(Show Context)
Citation Context ...ering to improve the efficiency of the specialised program (see e.g. [14]). Closedness can be ensured by using the following outline of a partial deduction algorithm (similar to the ones used in e.g. =-=[12, 13, 29, 30]-=-). Algorithm 1 (Partial deduction) 1. Let S0 be the set of atoms to be specialised and let i = 0. 2. Apply the unfolding rule U to each element of Si: Γi = U ∗ P (Si). 3. Si+1 = abstract(Si ∪ leaves∪(... |

10 |
Syntactic currying: yet another approach to partial evaluation
- Holst
- 1989
(Show Context)
Citation Context ...lt as one might imagine at first sight: basically cogen turns out to be just a simple extension of a “binding-time analysis” for logic programs (something first discovered for functional languages in =-=[21]-=-). In this paper we will describe the first cogen written in this way for a logic programming language: a small subset of Prolog. The most noticeable advantages of the cogen approach is that the cogen... |

9 | Analyzing logic programs using “PROP”ositional logic programs and a Magic Wand - Codish, Demoen - 1995 |

6 |
An experiment in automatic selfapplicable partial evaluation of Prolog
- Bondorf, Frauendorf, et al.
- 1990
(Show Context)
Citation Context ...mixtus [45], or paddy [43]) has been made effectively self-applicable. On the other hand a partial deducer which specialises only purely declarative logic programs (like sage in [18] or the system in =-=[7]-=-) has itself to be written purely declaratively leading to slow systems and impractical compilers and compiler generators. So far the only practical compilers and compiler generators have been obtaine... |