Results 1  10
of
20
Transformation of Logic Programs
 Handbook of Logic in Artificial Intelligence and Logic Programming
, 1998
"... Program transformation is a methodology for deriving correct and efficient programs from specifications. In this chapter, we will look at the so called 'rules + strategies' approach, and we will report on the main techniques which have been introduced in the literature for that approach, in the case ..."
Abstract

Cited by 34 (3 self)
 Add to MetaCart
Program transformation is a methodology for deriving correct and efficient programs from specifications. In this chapter, we will look at the so called 'rules + strategies' approach, and we will report on the main techniques which have been introduced in the literature for that approach, in the case of logic programs. We will also present some examples of program transformation, and we hope that through those examples the reader may acquire some familiarity with the techniques we will describe.
Unfold/fold transformations of CCP programs
 ACM Transactions on Programming Languages and Systems
, 1998
"... We introduce a transformation system for concurrent constraint programming (CCP). We define suitable applicability conditions for the transformations which guarantee that the input/output CCP semantics is preserved also when distinguishing deadlocked computations from successful ones and when consid ..."
Abstract

Cited by 19 (5 self)
 Add to MetaCart
We introduce a transformation system for concurrent constraint programming (CCP). We define suitable applicability conditions for the transformations which guarantee that the input/output CCP semantics is preserved also when distinguishing deadlocked computations from successful ones and when considering intermediate results of (possibly) nonterminating computations. The system allows us to optimize CCP programs while preserving their intended meaning: In addition to the usual benefits that one has for sequential declarative languages, the transformation of concurrent programs can also lead to the elimination of communication channels and of synchronization points, to the transformation of nondeterministic computations into deterministic ones, and to the crucial saving of computational space. Furthermore, since the transformation system preserves the deadlock behavior of programs, it can be used for proving deadlock freeness of a given program with respect to a class of queries. To this aim it is sometimes sufficient to apply our transformations and to specialize the resulting program with respect to the given queries in such a way that the obtained program is trivially deadlock free.
Transformation Rules for Locally Stratified Constraint Logic Programs
, 2004
"... We propose a set of transformation rules for constraint logic programs with negation. We assume that every program is locally strati ed and, thus, it has a unique perfect model. We give sucient conditions which ensure that the proposed set of transformation rules preserves the perfect model of ..."
Abstract

Cited by 14 (13 self)
 Add to MetaCart
We propose a set of transformation rules for constraint logic programs with negation. We assume that every program is locally strati ed and, thus, it has a unique perfect model. We give sucient conditions which ensure that the proposed set of transformation rules preserves the perfect model of the programs. Our rules extend in some respects the rules for logic programs and constraint logic programs already considered in the literature and, in particular, they include a rule for unfolding a clause with respect to a negative literal.
A Transformation System for CLP with Dynamic Scheduling and ccp
 In Proc. of the ACM Sigplan PEPMâ€™97
, 1997
"... In this paper we study unfold/fold transformations for constraint logic programs (CLP) with dynamic scheduling and for concurrent constraint programming (ccp). We define suitable applicability conditions for this transformations which ensure us that the original and the transformed program have the ..."
Abstract

Cited by 11 (2 self)
 Add to MetaCart
In this paper we study unfold/fold transformations for constraint logic programs (CLP) with dynamic scheduling and for concurrent constraint programming (ccp). We define suitable applicability conditions for this transformations which ensure us that the original and the transformed program have the same results of successful computations and have the same deadlocked derivations. The possible applications of these results are twofold. On one hand we can use the unfold/fold system to optimize CLP and ccp programs while preserving their intended meaning and in particular without the risk of introducing deadlocks. On the other hand, unfold/fold transformations can be used for proving deadlock freedom for a class of queries in a given program: to this aim it is sufficient to specialize the program with respect to the given queries in such a way that the resulting program is trivially deadlock free. As shown by several interesting examples, this yields a methodology for proving deadlock free...
Automated Strategies for Specializing Constraint Logic Programs
 LOPSTR 2000, LNCS 2042
"... We consider the problem of specializing constraint logic programs w.r.t. constrained queries. We follow a transformational approach based on rules and strategies. The use of the rules ensures that the specialized program is equivalent to the initial program w.r.t. a given constrained query. The stra ..."
Abstract

Cited by 10 (8 self)
 Add to MetaCart
We consider the problem of specializing constraint logic programs w.r.t. constrained queries. We follow a transformational approach based on rules and strategies. The use of the rules ensures that the specialized program is equivalent to the initial program w.r.t. a given constrained query. The strategies guide the application of the rules so to derive an efficient specialized program. In this paper we address various issues concerning the development of an automated transformation strategy. In particular, we consider the problems of when and how we should unfold, replace constraints, introduce generalized clauses, and apply the contextual constraint replacement rule. We propose a solution to these problems by adapting to our framework various techniques developed in the field of constraint programming, partial evaluation, and abstract interpretation. In particular, we use: (i) suitable solvers for simplifying constraints, (ii) wellquasiorders for ensuring the termination...
Transformation of Constraint Logic Programs for Software Specialization and Verification
, 2002
"... ..."
Specialization with Clause Splitting for Deriving Deterministic Constraint Logic Programs
 In Proc. IEEE Conference on Systems, Man and Cybernetics, Hammamet
, 2002
"... The reduction of nondeterminism can increase efficiency when specializing programs. We consider constraint logic programs and we propose a technique which by making use of a new transformation rule, called clause splitting, allows us to generate efficient, specialized programs which are deterministi ..."
Abstract

Cited by 5 (5 self)
 Add to MetaCart
The reduction of nondeterminism can increase efficiency when specializing programs. We consider constraint logic programs and we propose a technique which by making use of a new transformation rule, called clause splitting, allows us to generate efficient, specialized programs which are deterministic. We have applied our technique to the specialization of pattern matching programs.
Program Derivation = Rules + Strategies
 Computational Logic: Logic Programming and Beyond (Essays in honour of Bob Kowalski, Part I), Lecture Notes in Computer Science 2407
, 2001
"... In a seminal paper [38] Prof. Robert Kowalski advocated the paradigm Algorithm = Logic + Control which was intended to characterize program executions. Here we want to illustrate the corresponding paradigm Program Derivation = Rules + Strategies which is intended to characterize program derivations, ..."
Abstract

Cited by 4 (2 self)
 Add to MetaCart
In a seminal paper [38] Prof. Robert Kowalski advocated the paradigm Algorithm = Logic + Control which was intended to characterize program executions. Here we want to illustrate the corresponding paradigm Program Derivation = Rules + Strategies which is intended to characterize program derivations, rather than executions. During program execution, the Logic component guarantees that the computed results are correct, that is, they are true facts in the intended model of the given program, while the Control component ensures that those facts are derived in an efficient way. Likewise, during program derivation, the Rules component guarantees that the derived programs are correct and the Strategies component ensures that the derived programs are efficient.
On the Correctness of the Replacement Operation for CLP Modules
, 1996
"... In this paper we study the replacement transformation for Constraint Logic Programming modules. We define new applicability conditions that guarantee the correctness of the operation also wrt module's composition: under these conditions, the original and the transformed modules have the same observa ..."
Abstract

Cited by 4 (3 self)
 Add to MetaCart
In this paper we study the replacement transformation for Constraint Logic Programming modules. We define new applicability conditions that guarantee the correctness of the operation also wrt module's composition: under these conditions, the original and the transformed modules have the same observable properties also when they are composed with other modules. The applicability conditions are not bound to a specific notion of observable. Here we consider three distinct such notions. Two are operational and are based on the computed constraints; the third is the algebraic one based on the least model. We show that our transformation method can be applied in any of these distinct contexts, thus providing a parametric approach. 1 Introduction Constraint Logic Programming (CLP for short) is a powerful declarative programming paradigm in which constraints are primitive elements and the computation is specified by a logical inference rule. CLP has already been successfully employed in many ...