Results 1 - 10
of
10
Higher-order logic programming
- HANDBOOK OF LOGIC IN AI AND LOGIC PROGRAMMING, VOLUME 5: LOGIC PROGRAMMING. OXFORD (1998
"... ..."
A Notation for Lambda Terms I: A Generalization of Environments
- THEORETICAL COMPUTER SCIENCE
, 1994
"... A notation for lambda terms is described that is useful in contexts where the intensions of these terms need to be manipulated. This notation uses the scheme of de Bruijn for eliminating variable names, thus obviating ff-conversion in comparing terms. This notation also provides for a class of terms ..."
Abstract
-
Cited by 31 (12 self)
- Add to MetaCart
A notation for lambda terms is described that is useful in contexts where the intensions of these terms need to be manipulated. This notation uses the scheme of de Bruijn for eliminating variable names, thus obviating ff-conversion in comparing terms. This notation also provides for a class of terms that can encode other terms together with substitutions to be performed on them. The notion of an environment is used to realize this `delaying' of substitutions. The precise mechanism employed here is, however, more complex than the usual environment mechanism because it has to support the ability to examine subterms embedded under abstractions. The representation presented permits a fi-contraction to be realized via an atomic step that generates a substitution and associated steps that percolate this substitution over the structure of a term. The operations on terms that are described also include ones for combining substitutions so that they might be performed simultaneously. Our notatio...
A Fine-Grained Notation for Lambda Terms and Its Use in Intensional Operations
- Journal of Functional and Logic Programming
, 1996
"... We discuss issues relevant to the practical use of a previously proposed notation for lambda terms in contexts where the intensions of such terms have to be manipulated. This notation uses the `nameless' scheme of de Bruijn, includes expressions for encoding terms together with substitutions to be p ..."
Abstract
-
Cited by 22 (8 self)
- Add to MetaCart
We discuss issues relevant to the practical use of a previously proposed notation for lambda terms in contexts where the intensions of such terms have to be manipulated. This notation uses the `nameless' scheme of de Bruijn, includes expressions for encoding terms together with substitutions to be performed on them and contains a mechanism for combining such substitutions so that they can be effected in a common structure traversal. The combination mechanism is a general one and consequently difficult to implement. We propose a simplification to it that retains its functionality in situations that occur commonly in fi-reduction. We then describe a system for annotating terms to determine if they can be affected by substitutions generated by external fi-contractions. These annotations can lead to a conservation of space and time in implementations of reduction by permitting substitutions to be performed trivially in certain situations. The use of the resulting notation in the reduction...
Scoping Constructs In Logic Programming: Implementation Problems And Their Solution
, 1995
"... Machine (WAM). The provision of implications in goals results in the possibility of program clauses being added to the program for the purpose of solving specific subgoals. A naive scheme based on asserting and retracting program clauses does not suffice for implementing such additions for two reaso ..."
Abstract
-
Cited by 19 (9 self)
- Add to MetaCart
Machine (WAM). The provision of implications in goals results in the possibility of program clauses being added to the program for the purpose of solving specific subgoals. A naive scheme based on asserting and retracting program clauses does not suffice for implementing such additions for two reasons. First, it is necessary to also support the resurrection of an earlier existing program in the face of backtracking. Second, the possibility for implication goals to be surrounded by quantifiers requires a consideration of the parameterization of program clauses by bindings for their free variables. Devices for supporting these additional requirements are described as also is the integration of these devices into the WAM. Further extensions to the machine are outlined for handling higher-order additions to the language. The ideas Work on this paper has been partially supported by NSF Grants CCR-89-05825 and CCR-- 92-08465. Address correspondence to Gopalan Nadathur, Department of Compute...
Implementing Polymorphic Typing in a Logic Programming Language
- COMPUTER LANGUAGES
, 1993
"... Introducing types into a logic programming language leads to the need for typed unification within the computation model. In the presence of polymorphism and higher-order features, this aspect forces analysis of types at run-time. We propose extensions to the Warren Abstract Machine (WAM) that permi ..."
Abstract
-
Cited by 17 (10 self)
- Add to MetaCart
Introducing types into a logic programming language leads to the need for typed unification within the computation model. In the presence of polymorphism and higher-order features, this aspect forces analysis of types at run-time. We propose extensions to the Warren Abstract Machine (WAM) that permit such analysis to be done with reasonable efficiency. Much information about the structures of types is present at compile-time, and we show that this information can be used to considerably reduce the work during execution. We illustrate our ideas in the context of a typed version of Prolog. We describe a modified representation for terms, new instructions and additional data areas that in conjunction with existing WAM structures suffice to implement this language. The nature of compiled code is illustrated through examples, and the kind of run-time overheads that are incurred for processing types is analyzed, especially in those cases where others have shown that type checking can be eliminated during execution. The ideas
A Notation for Lambda Terms II: Refinements and Applications
, 1994
"... Issues that are relevant to the representation of lambda terms in contexts where their intensions have to be manipulated are examined. The basis for such a representation is provided by the suspension notation for lambda terms that is described in a companion paper. This notation obviates ff-conver ..."
Abstract
-
Cited by 12 (2 self)
- Add to MetaCart
Issues that are relevant to the representation of lambda terms in contexts where their intensions have to be manipulated are examined. The basis for such a representation is provided by the suspension notation for lambda terms that is described in a companion paper. This notation obviates ff-conversion in the comparison of terms by using the `nameless' scheme of de Bruijn and also permits a delaying of substitutions by including a class of terms that encode other terms together with substitutions to be performed on them. The suspension notation contains a mechanism for `merging' substitutions so that they can be effected in a common structure traversal. The mechanism is cumbersome to implement in its full generality and a simplification to it is considered. In particular, the old merging operations are eliminated in favor of new ones that capture some of their functionality and that permit a simplified syntax for terms. The resulting notation is refined by the addition of annotations ...
Proof-Theoretic Foundation of Compilation in Logic Programming Languages
- Proceedings of the Joint International Conference and Symposium on Logic Programming (JICSLP’98
"... Commercial implementations of logic programming languages are engineered Appeared in the Proceedings of the 1998 Joint International Conference and Symposium on Logic Programming --- JICSLP'98 (J. Jaffar editor), pp ??--??, MIT Press, Manchester, UK, 16--19 June 1998. around a compiler based on War ..."
Abstract
-
Cited by 9 (1 self)
- Add to MetaCart
Commercial implementations of logic programming languages are engineered Appeared in the Proceedings of the 1998 Joint International Conference and Symposium on Logic Programming --- JICSLP'98 (J. Jaffar editor), pp ??--??, MIT Press, Manchester, UK, 16--19 June 1998. around a compiler based on Warren's Abstract Machine (WAM) or a variant of it. In spite of various correctness proofs, the logical machinery relating the proof-theoretic specification of a logic programming language and its compiled form is still poorly understood. In this paper, we propose a logicindependent definition of compilation for logic programming languages. We apply this methodology to derive the first cut of a compiler and the corresponding abstract machine for the language of hereditary Harrop formulas and then for its linear refinement. 1 Introduction Compiled logic programs run over an order of magnitude faster than their interpreted source and constitute therefore a key step to combining the advantages of...
Implementing a Notion of Modules in the Logic Programming Language Prolog
- In Evelina Lamma and Paola Mello, editors, Extensions of Logic Programming: Proceedings of the Third International Workshop
, 1993
"... Issues concerning the implementation of a notion of modules in the higher-order logic programming language Prolog are examined. A program in this language is a composite of type declarations and procedure definitions. The module construct that is considered permits large collections of such declarat ..."
Abstract
-
Cited by 7 (1 self)
- Add to MetaCart
Issues concerning the implementation of a notion of modules in the higher-order logic programming language Prolog are examined. A program in this language is a composite of type declarations and procedure definitions. The module construct that is considered permits large collections of such declarations and definitions to be decomposed into smaller units. Mechanisms are provided for controlling the interaction of these units and for restricting the visibility of names used within any unit. The typical interaction between modules has both a static and a dynamic nature. The parsing of expressions in a module might require declarations in a module that it interacts with, and this information must be available during compilation. Procedure definitions within a module might utilize procedures presented in other modules and support must be provided for making the appropriate invocation during execution. Our concern here is largely with the dynamic aspects of module interaction. We describe a...
Realizing Modularity in λProlog
- THE JOURNAL OF FUNCTIONAL AND LOGIC PROGRAMMING
, 1999
"... The language λProlog incorporates a module notion that permits the space of names and procedure declarations to be decomposed into smaller units. Interactions between these units can take place through either an accumulation or importation process. There are both static and dynamic e#ects to such in ..."
Abstract
-
Cited by 2 (2 self)
- Add to MetaCart
The language λProlog incorporates a module notion that permits the space of names and procedure declarations to be decomposed into smaller units. Interactions between these units can take place through either an accumulation or importation process. There are both static and dynamic e#ects to such interactions: The parsing of expressions may require names declared in another module, and executable code may utilize procedures defined elsewhere. We describe a method for implementing this feature for modular programming that is based on the separate compilation of each module into an appropriate fragment of code. The dynamic semantics of module importation involves enhancing existing program contexts with the procedures defined in other modules. This effect is achieved through a run-time process for including the compiler-generated code for such procedures. Our implementation method partitions the code space into distinct chunks ...
On the Parallel Implementation of the Higher-Order Logic Language Prolog
"... Higher-order logic languages seem particularly suitable to be implemented on parallel architectures for at lest two reasons. On one hand, they offer more opportunities for parallelization than first-order logic languages. On the other hand, the greater computational costs of higher-order unificat ..."
Abstract
- Add to MetaCart
Higher-order logic languages seem particularly suitable to be implemented on parallel architectures for at lest two reasons. On one hand, they offer more opportunities for parallelization than first-order logic languages. On the other hand, the greater computational costs of higher-order unification of typed -terms should allow the exploitation of parallelism with a larger granularity, possibly leading to higher efficiency. In spite of their potential interest, there are a few implementations of higher-order logic languages, and, to our knowledge, no experience has been made about their parallelization, up to now. We report here a preliminary study about parallelization of an interpreter for the higher-order logic language Prolog. Starting from the available experience in parallelizing first-order logic languages, the possible sources of parallelism in execution of Prolog programs are presented, and a characterization for their actual exploitation on parallel hardware given....

