Results 1 -
9 of
9
The Narrowing-Driven Approach to Functional Logic Program Specialization
- New Generation Computing
, 2002
"... Partial evaluation is a semantics-based program optimization technique which has been investigated within di#erent programming paradigms and applied to a wide variety of languages. Recently, a partial evaluation framework for functional logic programs has been proposed. ..."
Abstract
-
Cited by 32 (18 self)
- Add to MetaCart
Partial evaluation is a semantics-based program optimization technique which has been investigated within di#erent programming paradigms and applied to a wide variety of languages. Recently, a partial evaluation framework for functional logic programs has been proposed.
Efficient Local Unfolding with Ancestor Stacks for Full Prolog
- In Proc. of LOPSTR’04
, 2005
"... Abstract. The integration of powerful partial evaluation methods into practical compilers for logic programs is still far from reality. This is related both to 1) efficiency issues and to 2) the complications of dealing with practical programs. Regarding efficiency, the most successful unfolding rul ..."
Abstract
-
Cited by 16 (13 self)
- Add to MetaCart
Abstract. The integration of powerful partial evaluation methods into practical compilers for logic programs is still far from reality. This is related both to 1) efficiency issues and to 2) the complications of dealing with practical programs. Regarding efficiency, the most successful unfolding rules used nowadays are based on structural orders applied over (covering) ancestors, i.e., a subsequence of the atoms selected during a derivation. Unfortunately, maintaining the structure of the ancestor relation during unfolding introduces significant overhead. We propose an efficient, practical local unfolding rule based on the notion of covering ancestors which can be used in combination with any structural order and allows a stack-based implementation without losing any opportunities for specialization. Regarding the second issue, we propose assertion-based techniques which allow our approach to deal with real programs that include (Prolog) built-ins and external predicates in a very extensible manner. Finally, we report on our implementation of these techniques in a practical partial evaluator, embedded in a state of the art compiler which uses global analysis extensively (the Ciao compiler and, specifically, its preprocessor CiaoPP). The performance analysis of the resulting system shows that our techniques, in addition to dealing with practical programs, are also significantly more efficient in time and somewhat more efficient in memory than traditional tree-based implementations. 1
Non-Leftmost Unfolding in Partial Evaluation of Logic Programs with Impure Predicates
- In Proc. of LOPSTR’05. Springer LNCS 3901
, 2006
"... Abstract. Partial evaluation of logic programs which contain impure predicates poses non-trivial challenges. Impure predicates include those which produce side-effects, raise errors (or exceptions), and those whose truth value varies according to the degree of instantiation of arguments 4. In partic ..."
Abstract
-
Cited by 13 (10 self)
- Add to MetaCart
Abstract. Partial evaluation of logic programs which contain impure predicates poses non-trivial challenges. Impure predicates include those which produce side-effects, raise errors (or exceptions), and those whose truth value varies according to the degree of instantiation of arguments 4. In particular, non-leftmost unfolding steps can produce incorrect results since the independence of the computation rule no longer holds in the presence of impure predicates. Existing proposals allow non-leftmost unfolding steps, but at the cost of accuracy: bindings and failure are not propagated backwards to predicates which are potentially impure. In this work we propose a partial evaluation scheme which substantially reduces the situations in which such backpropagation has to be avoided. With this aim, our partial evaluator takes into account the information about purity of predicates expressed in terms of assertions. This allows achieving some optimizations which are not feasible using existing partial evaluation techniques. We argue that our proposal goes beyond existing ones in that it is a) accurate, since the classification of pure vs impure is done at the level of atoms instead of predicates, b) extensible, as the information about purity can be added to programs using assertions without having to modify the partial evaluator itself, and c) automatic, since (backwards) analysis can be used to automatically infer the required assertions. Our approach has been implemented in the context of CiaoPP, the abstract interpretation-based preprocessor of the Ciao logic programming system. 1
A Partial Evaluation Framework for Curry Programs
, 1999
"... In this work, we develop a partial evaluation technique for residuating functional logic programs, which generalize the concurrent computation models for logic programs with delays to functional logic programs. We show how to lift the nondeterministic choices from run time to specialization time. We ..."
Abstract
-
Cited by 8 (5 self)
- Add to MetaCart
In this work, we develop a partial evaluation technique for residuating functional logic programs, which generalize the concurrent computation models for logic programs with delays to functional logic programs. We show how to lift the nondeterministic choices from run time to specialization time. We ascertain the conditions under which the original and the transformed program have the same answer expressions for the considered class of queries as well as the same floundering behavior. All these results are relevant for program optimization in Curry, a functional logic language which is intended to become a standard in this area. Preliminary empirical evaluation of the specialized Curry programs demonstrates that our technique also works well in practice and leads to substantial performance improvements. To our knowledge, this work is the first attempt to formally define and prove correct a general scheme for the partial evaluation of functional logic programs with delays.
Properties of Input-Consuming Derivations
, 1999
"... We study the properties of input-consuming derivations of moded logic programs. Input-consuming derivations do not employ a fixed selection rule, and can be used to model the behavior of logic programs using dynamic scheduling and employing constructs such as delay declarations. We consider the clas ..."
Abstract
-
Cited by 7 (4 self)
- Add to MetaCart
We study the properties of input-consuming derivations of moded logic programs. Input-consuming derivations do not employ a fixed selection rule, and can be used to model the behavior of logic programs using dynamic scheduling and employing constructs such as delay declarations. We consider the class of nicely-moded programs and queries. We show that for these programs one part of the well-known Switching Lemma holds also for input-consuming derivations. Furthermore, we provide conditions which guarantee that all input-consuming derivations starting in a Nicely-Moded query are finite. The method presented here is easy to apply and generalizes other related works.
Partial Evaluation of Concurrent Constraint Languages
- ACM Computing Surveys
, 1998
"... this paper we will substantiate our claims. ..."
Properties of Input-Consuming Derivations
, 1999
"... We study the properties of input-consuming derivations of moded logic programs. Input-consuming derivations do not employ a fixed selection rule, and can be used to model the behavior of logic programs using dynamic scheduling and employing constructs such as delay declarations. We consider the clas ..."
Abstract
- Add to MetaCart
We study the properties of input-consuming derivations of moded logic programs. Input-consuming derivations do not employ a fixed selection rule, and can be used to model the behavior of logic programs using dynamic scheduling and employing constructs such as delay declarations. We consider the class of nicely-moded programs and queries. We show that for these programs one part of the well-known Switching Lemma holds also for input-consuming derivations. Furthermore, we provide conditions which guarantee that all input-consuming derivations starting in a Nicely-Moded query are finite. The method presented here is easy to apply and generalizes other related works.
LicenseScript -- A Language and Framework for Calculating Licenses on
- IEEE JSAC: Special Issue on Dense WDM Networks
, 2002
"... The project LicenseScript develops and demonstrates an integrated framework for analysis and design of secure information delivery systems. The contributions of this project are the demonstration of new analysis and design methods in at least two of the following concrete application areas: (1) Digi ..."
Abstract
- Add to MetaCart
The project LicenseScript develops and demonstrates an integrated framework for analysis and design of secure information delivery systems. The contributions of this project are the demonstration of new analysis and design methods in at least two of the following concrete application areas: (1) Digital Rights Management (DRM), (2) wireless sensor networks (WSNs), (3) privacy protection.
Specialization of Functional Logic Programs with Dynamic Scheduling
"... In this work, we develop a partial evaluation technique for residuating functional logic programs, which generalize the concurrent computation models for logic programs with delays to functional logic programs. We show how to lift the nondeterministic choices from run time to specialization time. ..."
Abstract
- Add to MetaCart
In this work, we develop a partial evaluation technique for residuating functional logic programs, which generalize the concurrent computation models for logic programs with delays to functional logic programs. We show how to lift the nondeterministic choices from run time to specialization time. We ascertain the conditions under which the original and the transformed program have the same answer expressions for the considered class of queries as well as the same floundering behavior. All these results are relevant for program optimization in Curry, a functional logic language which is intended to become a standard in this area. Preliminary empirical evaluation of the specialized Curry programs demonstrates that our technique also works well in practice and leads to substantial performance improvements. To our knowledge, this work is the first attempt to formally define and prove correct a general scheme for the partial evaluation of functional logic programs with delays.

