Results 1  10
of
62
NonFailure Analysis for Logic Programs
 ACM Transactions on Programming Languages and Systems
, 1997
"... We provide a method whereby, given mode and (upper approximation) type information, we can detect procedures and goals that can be guaranteed to not fail (i.e., to produce at least one solution or not terminate). The technique is based on an intuitively very simple notion, that of a (set of) tests & ..."
Abstract

Cited by 133 (14 self)
 Add to MetaCart
We provide a method whereby, given mode and (upper approximation) type information, we can detect procedures and goals that can be guaranteed to not fail (i.e., to produce at least one solution or not terminate). The technique is based on an intuitively very simple notion, that of a (set of) tests "covering" the type of a set of variables. We show that the problem of determining a covering is undecidable in general, and give decidability and complexity results for the Herbrand and linear arithmetic constraint systems. We give sound algorithms for determining covering that are precise and efficient in practice. Based on this information, we show how to identify goals and procedures that can be guaranteed to not fail at runtime. Applications of such nonfailure information include programming error detection, program transformations and parallel execution optimization, avoiding speculative parallelism and estimating lower bounds on the computational costs of goals, which can be used for ...
AbstractionCarrying Code
 In Proc. of LPAR’04, number 3452 in LNAI
, 2005
"... Abstract. ProofCarrying Code (PCC) is a general approach to mobile code safety in which programs are augmented with a certificate (or proof). The practical uptake of PCC greatly depends on the existence of a variety of enabling technologies which allow both to prove programs correct and to replace ..."
Abstract

Cited by 45 (20 self)
 Add to MetaCart
(Show Context)
Abstract. ProofCarrying Code (PCC) is a general approach to mobile code safety in which programs are augmented with a certificate (or proof). The practical uptake of PCC greatly depends on the existence of a variety of enabling technologies which allow both to prove programs correct and to replace a costly verification process by an efficient checking procedure on the consumer side. In this work we propose AbstractionCarrying Code (ACC), a novel approach which uses abstract interpretation as enabling technology. We argue that the large body of applications of abstract interpretation to program verification is amenable to the overall PCC scheme. In particular, we rely on an expressive class of safety policies which can be defined over different abstract domains. We use an abstraction (or abstract model) of the program computed by standard static analyzers as a certificate. The validity of the abstraction on the consumer side is checked in a singlepass by a very efficient and specialized abstractinterpreter. We believe that ACC brings the interpretation techniques to the area of mobile code safety. We have implemented and benchmarked ACC within the Ciao system preprocessor. The experimental results show that the checking phase is indeed faster than the proof generation phase, and that the sizes of certificates are reasonable. 1
Directional Type Checking of Logic Programs
 In Proceedings of the 1st International Static Analysis Symposium
, 1994
"... We present an algorithm for automatic type checking of logic programs with respect to directional types that describe both the structure of terms and the directionality of predicates. The type checking problem is reduced to a decidable problem on systems of inclusion constraints over set expressio ..."
Abstract

Cited by 44 (1 self)
 Add to MetaCart
We present an algorithm for automatic type checking of logic programs with respect to directional types that describe both the structure of terms and the directionality of predicates. The type checking problem is reduced to a decidable problem on systems of inclusion constraints over set expressions. We discuss some properties of the reduction algorithm, complexity, and present a proof of correctness. 1 1 Introduction Most logic programming languages are untyped. In Prolog, for example, it is considered meaningful to apply any nary predicate to any ntuple of terms. However, it is generally accepted that static type checking has great advantages in detecting programming errors early and for generating efficient executable code. Motivated at least in part by the success of type systems for procedural and functional languages, there is currently considerable interest in finding appropriate definitions of type and welltyping for logic languages. This paper explores the type checki...
Program Development Using Abstract Interpretation (and The Ciao System Preprocessor
 In 10th International Static Analysis Symposium (SAS’03), number 2694 in LNCS
, 2003
"... Abstract. The technique of Abstract Interpretation has allowed the development of very sophisticated global program analyses which are at the same time provably correct and practical. We present in a tutorial fashion a novel program development framework which uses abstract interpretation as a funda ..."
Abstract

Cited by 32 (23 self)
 Add to MetaCart
(Show Context)
Abstract. The technique of Abstract Interpretation has allowed the development of very sophisticated global program analyses which are at the same time provably correct and practical. We present in a tutorial fashion a novel program development framework which uses abstract interpretation as a fundamental tool. The framework uses modular, incremental abstract interpretation to obtain information about the program. This information is used to validate programs, to detect bugs with respect to partial specifications written using assertions (in the program itself and/or in system libraries), to generate and simplify runtime tests, and specialization, parallelization, and resource usage control, all in a provably correct way. In the case of validation and debugging, the assertions can refer to a variety of program points such as procedure entry, procedure exit, points within procedures, or global computations. The system can reason with much richer information than, for example, traditional types. This includes data structure shape (including pointer sharing), bounds on data structure sizes, and other operational variable instantiation properties, as well as procedurelevel properties such as determinacy, termination, nonfailure, and bounds on resource consumption (time or space cost). CiaoPP, the preprocessor of the Ciao multiparadigm programming system, which implements the described functionality, will be used to illustrate the fundamental ideas.
More Precise Yet Efficient Type Inference for Logic Programs
, 2002
"... Abstract. Type analyses of logic programs which aim at inferring the interpretationbased type analyzers for logic programs, built on either topdown or bottomup interpretation of the program. In this setting, we discuss the widening operator, arguably a crucial one. We present a new widening which ..."
Abstract

Cited by 25 (1 self)
 Add to MetaCart
(Show Context)
Abstract. Type analyses of logic programs which aim at inferring the interpretationbased type analyzers for logic programs, built on either topdown or bottomup interpretation of the program. In this setting, we discuss the widening operator, arguably a crucial one. We present a new widening which is more precise than those previously proposed. Practical results with our analysis domain are also presented, showing that it also allows for efficient analysis. 1
Determinacy Analysis for Logic Programs Using Mode and Type Information
 In Proceedings of the 14th International Symposium on Logicbased Program Synthesis and Transformation (LOPSTR’04), number 3573 in LNCS
, 2004
"... Abstract. We propose an analysis for detecting procedures and goals that are deterministic (i.e. that produce at most one solution), or predicates whose clause tests are mutually exclusive (which implies that at most one of their clauses will succeed) even if they are not deterministic (because they ..."
Abstract

Cited by 14 (5 self)
 Add to MetaCart
(Show Context)
Abstract. We propose an analysis for detecting procedures and goals that are deterministic (i.e. that produce at most one solution), or predicates whose clause tests are mutually exclusive (which implies that at most one of their clauses will succeed) even if they are not deterministic (because they call other predicates that can produce more than one solution). Applications of such determinacy information include detecting programming errors, performing certain highlevel program transformations for improving search efficiency, optimizing low level code generation and parallel execution, and estimating tighter upper bounds on the computational costs of goals and data sizes, which can be used for program debugging, resource consumption and granularity control, etc. We have implemented the analysis and integrated it in the CiaoPP system, which also infers automatically the mode and type information that our analysis takes as input. Experiments performed on this implementation show that the analysis is fairly accurate and efficient.
Automata on DAG Representations of Finite Trees
, 1999
"... We introduce a new class of finite automata. They are usual bottomup tree automata that run on DAG representations of finite trees. We prove that the emptiness problem for this class of automata is NPcomplete. Using these automata we prove the decidability of directional type checking for logic ..."
Abstract

Cited by 14 (0 self)
 Add to MetaCart
We introduce a new class of finite automata. They are usual bottomup tree automata that run on DAG representations of finite trees. We prove that the emptiness problem for this class of automata is NPcomplete. Using these automata we prove the decidability of directional type checking for logic programs, and thus we improve earlier results by Aiken and Lakshman. We also show an application of these automata in solving systems of set constraints, which gives a new view on the satisfiability problem for set constraints with negative constraints. Keywords Tree Automata, Directed Acyclic Graphs, Types in Logic Programming, Semantics of Logic Programs, Set Constraints 1 Introduction We introduce a new class of finite automata, which we call automata on tdags. They are usual bottomup tree automata that run on DAG representations of ground terms over given signature. The class of languages recognizable by these automata contains all DAG representations of regular sets of terms...
Typebased {XML} Processing in Logic Programming
 In PADL 2003
, 2003
"... In this paper we propose a typebased framework for using logic programming for XML processing. We transform XML documents into terms and DTDs into regular types. We implemented a standard type inference algorithm for logic programs and use the types corresponding to the DTDs as additional type ..."
Abstract

Cited by 13 (2 self)
 Add to MetaCart
(Show Context)
In this paper we propose a typebased framework for using logic programming for XML processing. We transform XML documents into terms and DTDs into regular types. We implemented a standard type inference algorithm for logic programs and use the types corresponding to the DTDs as additional type declarations for logic programs for XML processing. Due to the correctness of the type inference this makes it possible to use logic programs as an implicitly typed processing language for XML with static type (in this case DTDs) validation. As far as we know this is the first work adding type validation at compile time to the use of logic programming for XML processing.