{"title":"A compositional semantics for CHR","authors":"M. Gabbrielli, M. Meo","doi":"10.1145/1069774.1069794","DOIUrl":"https://doi.org/10.1145/1069774.1069794","url":null,"abstract":"Constraint Handling Rules (CHR) are a committed-choice declarative language which has been designed for writing constraint solvers. A CHR program consists of multi-headed guarded rules which allow one to rewrite constraints into simpler ones until a solved form is reached.CHR has received a considerable attention, both from the practical and from the theoretical side. Nevertheless, due the use of multi-headed clauses, there are several aspects of the CHR semantics which have not been clarified yet. In particular, no compositional semantics for CHR has been defined so far.In this paper we introduce a fix-point semantics which characterizes the input/output behavior of a CHR program and which is and-compositional, that is, which allows to retrieve the semantics of a conjunctive query from the semantics of its components. Such a semantics can be used as a basis to define incremental and modular analysis and verification tools.","PeriodicalId":238328,"journal":{"name":"Proceedings of the 7th ACM SIGPLAN international conference on Principles and practice of declarative programming","volume":"47 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2005-07-11","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"131319672","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
T. Schrijvers, Peter James Stuckey, Gregory J. Duck
{"title":"Abstract interpretation for constraint handling rules","authors":"T. Schrijvers, Peter James Stuckey, Gregory J. Duck","doi":"10.1145/1069774.1069795","DOIUrl":"https://doi.org/10.1145/1069774.1069795","url":null,"abstract":"Program analysis is essential for the optimized compilation of Constraint Handling Rules (CHRs) as well as the inference of behavioral properties such as confluence and termination. Up to now all program analyses for CHRs have been developed in an ad hoc fashion.In this work we bring the general program analysis methodology of abstract interpretation to CHRs: we formulate an abstract interpretation framework over the call-based operational semantics of CHRs. The abstract interpretation framework is non-obvious since it needs to handle the highly non-deterministic execution of CHRs. The use of the framework is illustrated with two instantiations: the CHR-specific late storage analysis and the more generally known groundness analysis. In addition, we discuss optimizations based on these analyses and present experimental results.","PeriodicalId":238328,"journal":{"name":"Proceedings of the 7th ACM SIGPLAN international conference on Principles and practice of declarative programming","volume":"108 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2005-07-11","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"114864282","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
{"title":"Security policy in a declarative style","authors":"R. Echahed, F. Prost","doi":"10.1145/1069774.1069789","DOIUrl":"https://doi.org/10.1145/1069774.1069789","url":null,"abstract":"We address the problem of controlling information leakage in a concurrent declarative programming setting. Our aim is to define verification tools in order to distinguish between authorized, or declared, information flows such as password testing (e.g., ATM, login processes, etc.) and non-authorized ones. In this paper, we first propose a way to define security policies as confluent and terminating rewrite systems. Such policies define how the privacy levels of information evolve. Then, we provide a formal definition of secure processes with respect to a given security policy. We also define an actual verification algorithm of secure processes based on constraint solving.","PeriodicalId":238328,"journal":{"name":"Proceedings of the 7th ACM SIGPLAN international conference on Principles and practice of declarative programming","volume":"40 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2005-07-11","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"129809967","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
{"title":"Optimization with mode-directed preferences","authors":"Hai-Feng Guo, B. Jayaraman, G. Gupta, Miao Liu","doi":"10.1145/1069774.1069797","DOIUrl":"https://doi.org/10.1145/1069774.1069797","url":null,"abstract":"Traditional constraint programming specifies an optimization problem by using a set of constraints and minimizing (or maximizing) objective functions. Unfortunately, general optimization problems may involve compound objectives whose optima are difficult to be represented by a simple minimization (or maximization). Even worse, for many applications, especially those defined over structural domains, it is difficult to specify any objective functions. In this paper we presents a declarative method for specifying generalized optimization problems based on comparison and selection among alternative solutions. The method introduces a formal predicate mode declaration for designating certain predicates as optimization predicates, and uses preference rules for stating the criteria for determining their optimal solutions. We illustrate their uses with two representative examples: one is matrix-chain multiplication from dynamic programming, and the other is ambiguity resolution for recursively-defined grammars. This paper also addresses how to extend a tabled Prolog system with preferences. The execution of logic programs with preferences is achieved in two steps. First, an automatic transformation is applied to embed the preferences into the problem specification to form an executable program. Second, the new program is then evaluated using tabled resolution, while the mode declaration provides a selection mechanism among the alternative solutions. We show that the transformation scheme preserves the semantics for each optimization predicate. Experimental results are shown to indicate that preferences provide a declarative approach without sacrificing efficiency.","PeriodicalId":238328,"journal":{"name":"Proceedings of the 7th ACM SIGPLAN international conference on Principles and practice of declarative programming","volume":"1 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2005-07-11","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"130281378","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
{"title":"Automatic type inference via partial evaluation","authors":"Aaron Tomb, C. Flanagan","doi":"10.1145/1069774.1069784","DOIUrl":"https://doi.org/10.1145/1069774.1069784","url":null,"abstract":"Type checking and type inference are fundamentally similar problems. However, the algorithms for performing the two operations, on the same type system, often differ significantly. The type checker is typically a straightforward encoding of the original type rules. For many systems, type inference is performed using a two-phase, constraint-based algorithm.We present an approach that, given the original type rules written as clauses in a logic programming language, automatically generates an efficient, two-phase, constraint-based type inference algorithm. Our approach works by partially evaluating the type checking rules with respect to the target program to yield a set of constraints suitable for input to an external constraint solver. This approach avoids the need to manually develop and verify a separate type inference algorithm, and is ideal for experimentation with and rapid prototyping of novel type systems.","PeriodicalId":238328,"journal":{"name":"Proceedings of the 7th ACM SIGPLAN international conference on Principles and practice of declarative programming","volume":"24 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2005-07-11","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"126863675","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
{"title":"Security analysis of network protocols: logical and computational methods","authors":"John C. Mitchell","doi":"10.1145/1069774.1069788","DOIUrl":"https://doi.org/10.1145/1069774.1069788","url":null,"abstract":"Security analysis of network protocols is a rich scientific area with two different foundations, one based on logic and symbolic computation, and one based on computational complexity theory. The symbolic approach has led to formal logics and automated tools that have been used successfully in a number of case studies. The computational approach yields more insight into the strength and vulnerabilities of protocols, but it involves explicit reasoning about probability and computational complexity. Ideally, we would like to combine the advantages of both and develop a simple, automatable method that captures intuitive high-level reasoning principles, yet accurately reflects the subtleties of probabilistic polynomial-time computation. This talk will summarize some of the main lines of prior work and discuss ways to bridge the gap between symbolic and computational analysis. A significant portion of the talk will focus on a high-level protocol logic whose provable statements are correct when regarded as assertions about probabilistic polynomial-time protocol execution in the face of probabilistic polynomial-time attack.","PeriodicalId":238328,"journal":{"name":"Proceedings of the 7th ACM SIGPLAN international conference on Principles and practice of declarative programming","volume":"19 3","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2005-07-11","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"133135354","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
{"title":"A resolution strategy for verifying cryptographic protocols with CBC encryption and blind signatures","authors":"V. Cortier, M. Rusinowitch, E. Zalinescu","doi":"10.1145/1069774.1069776","DOIUrl":"https://doi.org/10.1145/1069774.1069776","url":null,"abstract":"Formal methods have proved to be very useful for analyzing cryptographic protocols. However, most existing techniques apply to the case of abstract encryption schemes and pairing. In this paper, we consider more complex, less studied cryptographic primitives like CBC encryption and blind signatures. This leads us to introduce a new fragment of Horn clauses. We show decidability of this fragment using a combination of several resolution strategies.As a consequence, we obtain a new decidability result for a class of cryptographic protocols (with an unbounded number of sessions and a bounded number of nonces) that may use for example CBC encryption and blind signatures. We apply this result to fix the Needham-Schroeder symmetric key authentication protocol, which is known to be flawed when CBC mode is used.","PeriodicalId":238328,"journal":{"name":"Proceedings of the 7th ACM SIGPLAN international conference on Principles and practice of declarative programming","volume":"36 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2005-07-11","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"132318313","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
{"title":"Self-tuning resource aware specialisation for prolog","authors":"Stephen-John Craig, M. Leuschel","doi":"10.1145/1069774.1069777","DOIUrl":"https://doi.org/10.1145/1069774.1069777","url":null,"abstract":"The paper develops a self-tuning resource aware partial evaluation technique for Prolog programs, which derives its own control strategies tuned for the underlying computer architecture and Prolog compiler using a genetic algorithm approach. The algorithm is based on mutating the annotations of offline partial evaluation. Using a set of representative sample queries it decides upon the fitness of annotations, controlling the trade-off between code explosion, speedup gained and specialisation time. The user can specify the importance of each of these factors in determining the quality of the produced code, tailoring the specialisation to the particular problem at hand. We present experimental results for our implemented technique on a series of benchmarks. The results are compared against the aggressive termination based binding-time analysis and optimised using different measures for the quality of code. We also show that our technique avoids some classical pitfalls of partial evaluation.","PeriodicalId":238328,"journal":{"name":"Proceedings of the 7th ACM SIGPLAN international conference on Principles and practice of declarative programming","volume":"57 1 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2005-07-11","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"128006399","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
{"title":"Trace effects and object orientation","authors":"C. Skalka","doi":"10.1145/1069774.1069787","DOIUrl":"https://doi.org/10.1145/1069774.1069787","url":null,"abstract":"Trace effects are statically generated program abstractions, that can be model checked for verification of assertions in a temporal program logic. In this paper we develop a type and effect analysis for obtaining trace effects of Object Oriented programs in Featherweight Java. We observe that the analysis is significantly complicated by the interaction of trace behavior with inheritance and other Object Oriented features, particularly overridden methods, dynamic dispatch, and downcasting. We propose an expressive type and effect inference algorithm, combining polymorphism and subtyping/subeffecting constraints, to obtain a flexible trace effect analysis in an Object Oriented setting.","PeriodicalId":238328,"journal":{"name":"Proceedings of the 7th ACM SIGPLAN international conference on Principles and practice of declarative programming","volume":"1 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2005-07-11","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"129176173","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
{"title":"Inverting abstract unification for set-sharing","authors":"Xuan Li, Lunjin Lu","doi":"10.1145/1069774.1069786","DOIUrl":"https://doi.org/10.1145/1069774.1069786","url":null,"abstract":"This paper presents an inversion of the abstract unification operator for forward set-sharing analysis of logic programs. The inverted operator, called a backward abstract unification operator, computes all maximal pre-conditions for a given equation and its post-condition. It is a key operator in a backward analysis. The maximal preconditions are obtained by first calculating a superset of all preconditions and then generating all maximal pre-conditions from the superset. The latter step is transformed to the problem of finding all maximal models of a Boolean formula.","PeriodicalId":238328,"journal":{"name":"Proceedings of the 7th ACM SIGPLAN international conference on Principles and practice of declarative programming","volume":"11 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2005-07-11","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"114152355","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}