Results 1  10
of
18
The Integration of Functions into Logic Programming: A Survey
, 1994
"... Functional and logic programming are the most important declarative programming paradigms, and interest in combining them has grown over the last decade. Early research concentrated on the definition and improvement of execution principles for such integrated languages, while more recently efficient ..."
Abstract

Cited by 40 (0 self)
 Add to MetaCart
Functional and logic programming are the most important declarative programming paradigms, and interest in combining them has grown over the last decade. Early research concentrated on the definition and improvement of execution principles for such integrated languages, while more recently efficient implementations of these execution principles have been developed so that these languages became relevant for practical applications. In this paper we survey the development of the operational semantics as well as
Synthesis of Directionality Information for Functional Logic Programs
 Proceedings of the Third International Workshop on Static Analysis, LNCS 724
, 1993
"... . Many Prolog systems offer the facility of calling external functions written in nonlogic programming languages. A basic requirement is often that the arguments of the functions must be ground at invocation time, otherwise an error is reported, or the call is delayed until the arguments are su ..."
Abstract

Cited by 18 (1 self)
 Add to MetaCart
(Show Context)
. Many Prolog systems offer the facility of calling external functions written in nonlogic programming languages. A basic requirement is often that the arguments of the functions must be ground at invocation time, otherwise an error is reported, or the call is delayed until the arguments are sufficiently instantiated. The drawback of the latter method is twofold: (1) the arguments might never be instantiated, and (2) the dynamic checks made by the delaying mechanism are expensive. This paper presents a method, which for a given program identifies a class of atomic goals for which (1) will not occur. Moreover, we describe a method for transforming a program into an equivalent program, for which dynamic delays are avoided. 1 Introduction In many Prolog systems, pure logic programs are enriched with mechanisms for invocation of builtin arithmetic and procedures written in nonlogic programming languages (like C). This is very useful, or even necessary, for writing realistic ...
Implementing encapsulated search for a lazy functional logic language
 In Proc. 4th Fuji International Symposium on Functional and Logic Programming (FLOPS’99
, 1999
"... Abstract. A distinguishing feature of logic and functional logic languages is their ability to perform computations with partial data and to search for solutions of a goal. Having a builtin search strategy is convenient but not always sufficient. For many practical applications the builtin search ..."
Abstract

Cited by 17 (2 self)
 Add to MetaCart
(Show Context)
Abstract. A distinguishing feature of logic and functional logic languages is their ability to perform computations with partial data and to search for solutions of a goal. Having a builtin search strategy is convenient but not always sufficient. For many practical applications the builtin search strategy (usually depthfirst search via global backtracking) is not well suited. Also the nondeterministic instantiation of unbound logic variables conflicts with the monadic I/O concept, which requires a singlethreaded use of the world. A solution to these problems is to encapsulate search via a primitive operator try, which returns all possible solutions to a search goal in a list. In the present paper we develop an abstract machine that aims at an efficient implementation of encapsulated search in a lazy functional logic language. 1
Functional logic overloading
, 2002
"... Functional logic overloading is a novel approach to userdefined overloading that extends Haskell’s concept of type classes in significant ways. Whereas type classes are conceptually predicates on types in standard Haskell, they are type functions in our approach. Thus, we can base type inference on ..."
Abstract

Cited by 16 (1 self)
 Add to MetaCart
(Show Context)
Functional logic overloading is a novel approach to userdefined overloading that extends Haskell’s concept of type classes in significant ways. Whereas type classes are conceptually predicates on types in standard Haskell, they are type functions in our approach. Thus, we can base type inference on the evaluation of functional logic programs. Functional logic programming provides a solid theoretical foundation for type functions and, at the same time, allows for programmable overloading resolution strategies by choosing different evaluation strategies for functional logic programs. Type inference with type functions is an instance of type inference with constrained types, where the underlying constraint system is defined by a functional logic program. We have designed a variant of Haskell which supports our approach to overloading, and implemented a prototype frontend for the language.
Detection And Optimization Of SuspensionFree Logic Programs
, 1996
"... the effects of head unification with the formal parameters ¯ x, given the abstract substitution ff describing the actual parameters, so as to obtain an initial abstract environment A 1 . 2. Let the abstract environment at the program point immediately before the literal q i (¯u i ) be denoted by A i ..."
Abstract

Cited by 15 (2 self)
 Add to MetaCart
the effects of head unification with the formal parameters ¯ x, given the abstract substitution ff describing the actual parameters, so as to obtain an initial abstract environment A 1 . 2. Let the abstract environment at the program point immediately before the literal q i (¯u i ) be denoted by A i , 1 i n. For i := 1 to n do: A 0 i := analyse call(q i ; A i ); A i+1 := extend abs env (A i ; A 0 i ); 3. Compute and return the abstract environment An+1 projected on the arguments in the head of the clause. A call to a procedure is analyzed by processing each clause for that procedure, in turn, as described above. For each clause, the analysis yields an abstract environment, and these can be "summarized"for example, using the join operator t on ASubto yield an abstract environment describing the substitutions that may be obtained when that call returns. In the following sections, we describe how the underlying analysis described above can be extended to detect situations ...
Analysis of Nonlinear Constraints in CLP(R)
 Proceedings of the Tenth International Conference on Logic Progra mming
, 1993
"... Solving nonlinear constraints over real numbers is a complex problem. Hence constraint logic programming languages like CLP(R) or Prolog III solve only linear constraints and delay nonlinear constraints until they become linear. This efficient implementation method has the disadvantage that sometime ..."
Abstract

Cited by 14 (0 self)
 Add to MetaCart
(Show Context)
Solving nonlinear constraints over real numbers is a complex problem. Hence constraint logic programming languages like CLP(R) or Prolog III solve only linear constraints and delay nonlinear constraints until they become linear. This efficient implementation method has the disadvantage that sometimes computed answers are unsatisfiable or infinite loops occur due to the unsatisfiability of delayed nonlinear constraints. These problems could be solved by using a more powerful constraint solver which can deal with nonlinear constraints like in RISCCLP(Real). Since such powerful constraint solvers are not very efficient, we propose a compromise between these two extremes. We characterize a class of CLP(R) programs for which all delayed nonlinear constraints become linear at run time. Programs belonging to this class can be safely executed with the efficient CLP(R) method while the remaining programs need a more powerful constraint solver. 1 Introduction The constraint logic programming ...
Avoiding Dynamic Delays in Functional Logic Programs
 In Programming Language Implementation and Logic Programming, number 714 in LNCS
, 1993
"... . In several functional logic programming languages, functional expressions must be evaluated before unification with another term, but this can only be done if the functional expression is ground. If the functional expression is nonground, then unification must be delayed until all the arguments ..."
Abstract

Cited by 12 (5 self)
 Add to MetaCart
. In several functional logic programming languages, functional expressions must be evaluated before unification with another term, but this can only be done if the functional expression is ground. If the functional expression is nonground, then unification must be delayed until all the arguments have become instantiated to ground terms. If the delaying mechanism uses dynamic tests, the program will be unnecessarily inefficient. We present an analysis method for statically determining at what point in the program a given functional expression can be evaluated. This analysis is then used for transforming a functional logic program into an equivalent program, in which most dynamic delays are avoided. We show that this transformation can lead to considerable improvements in performance, compared to a dynamic delaying strategy. 1 Introduction During the last decade, an immense amount of research has been done on combining logic programming with functional and equational languages. The d...
Mode Analysis of Functional Logic Programs
 In Proceedings of the International Conference on Logic Programming (ICLP 2005
, 1994
"... Abstract. Functional logic languages amalgamate functional and logic programming paradigms. They can be efficiently implemented by extending techniques known from logic programming. Such implementations can be largely improved if information about the runtime behavior, in particular the modes of fu ..."
Abstract

Cited by 10 (9 self)
 Add to MetaCart
Abstract. Functional logic languages amalgamate functional and logic programming paradigms. They can be efficiently implemented by extending techniques known from logic programming. Such implementations can be largely improved if information about the runtime behavior, in particular the modes of function calls, is available at compile time. In this paper we present a framework to derive such global information. The concrete operational semantics considered in this paper is normalizing innermost narrowing, which combines the deterministic reduction principle of functional languages with the nondeterministic search principle of logic languages. Due to the normalization process between narrowing steps, standard analysis frameworks for logic programming cannot be applied. Therefore we develop new techniques to correctly approximate the effect of the intermediate normalization process. 1 Introduction A lot of proposals have been made to amalgamate functional and logic programming languages (see [15] for a recent survey). Functional logic languages with a sound and complete operational semantics are based on narrowing (e.g., [9, 11, 25, 27]), a combination of the reduction principle of functional languages and the resolution principle of logic languages. Narrowing solves equations by finding appropriate values for variables occurring in goal equations. This is done by unifying an input term with the lefthand side of some rule and then replacing the instantiated input term by the instantiated righthand side of the rule. Example 1. The following rules define the addition of two natural numbers which are represented by terms built from 0 and s:
Efficient Analysis of Logic Programs with Dynamic Scheduling
 Proc. Twelfth International Logic Programming Symposium
, 1995
"... The first logic programming languages, such as Prolog, used a fixed lefttoright atom scheduling rule. Recent logic programming languages, however, usually provide more flexible scheduling in which computation generally proceeds lefttoright but in which some calls are dynamically "delayed&qu ..."
Abstract

Cited by 8 (1 self)
 Add to MetaCart
The first logic programming languages, such as Prolog, used a fixed lefttoright atom scheduling rule. Recent logic programming languages, however, usually provide more flexible scheduling in which computation generally proceeds lefttoright but in which some calls are dynamically "delayed" until their arguments are sufficiently instantiated to allow the call to run efficiently. Such languages include constraint logic programming languages in which constraints which are "too hard" are delayed and concurrent constraint languages in which delay on shared variables is used to provide asynchronous communication between processes. We give a new framework for the global analysis of logic programming languages with dynamic scheduling which is based on approximating the delayed atoms by a closure operator. We give an example analysis for groundness based on this framework, and give the results of an implementation which demonstrates the method is practical. 1 Introduction The first logic pr...
Towards the Global Optimization of Functional Logic Programs
 In Proc. 5th International Conference on Compiler Construction. LNCS 786:6882
, 1994
"... . Functional logic languages amalgamate functional and logic programming paradigms. They can be efficiently implemented by extending techniques known from logic programming. In this paper we show how global information about the call modes of functions can be used to optimize the compilation of ..."
Abstract

Cited by 6 (4 self)
 Add to MetaCart
(Show Context)
. Functional logic languages amalgamate functional and logic programming paradigms. They can be efficiently implemented by extending techniques known from logic programming. In this paper we show how global information about the call modes of functions can be used to optimize the compilation of functional logic programs. Since mode information has been successfully used to improve the implementation of pure logic programs and these techniques can be applied to implementations of functional logic programs as well, we concentrate on optimizations which are unique to the operational semantics of functional logic programs. We define a suitable notion of modes for functional logic programs and present compiletime techniques to optimize the normalization process during the execution of functional logic programs. 1 Introduction In recent years, a lot of proposals have been made to amalgamate functional and logic programming languages [7, 17]. Functional logic languages with a so...