Results 1 -
5 of
5
Binding-Time Analysis for Mercury
- 16th International Conference on Logic Programming, pages 500 { 514
, 1999
"... . In this paper, we describe a binding-time analysis (BTA) for a statically typed and strongly moded pure logic programming language, in casu Mercury. Binding-time analysis is the key concept in achieving o-line program specialisation: the analysis starts from a description of the program's inpu ..."
Abstract
-
Cited by 8 (4 self)
- Add to MetaCart
. In this paper, we describe a binding-time analysis (BTA) for a statically typed and strongly moded pure logic programming language, in casu Mercury. Binding-time analysis is the key concept in achieving o-line program specialisation: the analysis starts from a description of the program's input available for specialisation, and propagates this information throughout the program, deriving directives for when and how to perform specialisation. 1
Typed static analysis: Application to groundness analysis of Prolog and lambda-Prolog
- Journal of Functional and Logic Programming
, 1999
"... We enrich the domain Pos used for the static analysis of Prolog programs by combining it with types. We adopt the prescriptive view on typing, and we assume that programs are well-typed in an already existing type system. Typed static analysis of Typed Prolog programs gives access to more refined pr ..."
Abstract
-
Cited by 6 (1 self)
- Add to MetaCart
We enrich the domain Pos used for the static analysis of Prolog programs by combining it with types. We adopt the prescriptive view on typing, and we assume that programs are well-typed in an already existing type system. Typed static analysis of Typed Prolog programs gives access to more refined properties than untyped analysis because types give information on the inductive structure of terms that untyped static analysis does not discover. The increased refinement is not in variables assigned to true (e.g., variable recognized as bound to ground terms), but rather in variables not assigned to true; theycan be assigned a more informative value than false. For instance, the proposed analysis can show that a variable is bound to a nil-terminated list whose elements are not necessarily ground. We contend that this kind of property is sometimes more useful than groundness. Because 1 of constructors of compound types, e.g., list, the typed abstract domain can be infinite, but we show that if the so-called head-condition is satisfied by the analyzed program, then only a finite part of the domain is used. 1
Rapid Prototyping using Formal Specifications
- In Proceedings of the 21st Australasian Computer Science Conference
, 1998
"... . There is growing interest in animating formal specifications for the purpose of better understanding the requirements and for validating the specification. Formal specifications in a non-executable language offer challenges for animation systems, for example, dealing effectively with infinite data ..."
Abstract
-
Cited by 6 (1 self)
- Add to MetaCart
. There is growing interest in animating formal specifications for the purpose of better understanding the requirements and for validating the specification. Formal specifications in a non-executable language offer challenges for animation systems, for example, dealing effectively with infinite data sets, sensibly animating functions which are not computable and determining a sensible set of inputs and outputs for arbitrary relations. In this paper we examine these issues in the context of animating Z specifications in the logic programming language Mercury. In particular we outline how information for making a non-executable Z specification executable can be derived using static analysis techniques from logic programming. We present analysis algorithms for deriving control (mode) and representation (subtype) information and show how these analyses are used in a tool for deriving Mercury programs from Z specifications. Finally we compare our approach with existing systems for animating...
The Divide-and-Conquer Subgoal-Ordering Algorithm for Speeding up Logic Inference
- Journal of Artificial Intelligence Research
, 1998
"... It is common to view programs as a combination of logic and control: the logic part defines what the program must do, the control part -- how to do it. The Logic Programming paradigm was developed with the intention of separating the logic from the control. Recently, extensive research has been cond ..."
Abstract
-
Cited by 1 (1 self)
- Add to MetaCart
It is common to view programs as a combination of logic and control: the logic part defines what the program must do, the control part -- how to do it. The Logic Programming paradigm was developed with the intention of separating the logic from the control. Recently, extensive research has been conducted on automatic generation of control for logic programs. Only a few of these works considered the issue of automatic generation of control for improving the efficiency of logic programs. In this paper we present a novel algorithm for automatic finding of lowest-cost subgoal orderings. The algorithm works using the divide-and-conquer strategy. The given set of subgoals is partitioned into smaller sets, based on co-occurrence of free variables. The subsets are ordered recursively and merged, yielding a provably optimal order. We experimentally demonstrate the utility of the algorithm by testing it in several domains, and discuss the possibilities of its cooperation with other existing meth...
Analysing Modes and Subtypes in Z Specifications
, 1998
"... Poor requirements are the cause of a large proportion of defects in released software. Requirements can be improved by using mathematical modelling techniques. These have a number of advantages and a single major disadvantage--it is difficult to demonstrate a formal specification to a client or u ..."
Abstract
- Add to MetaCart
Poor requirements are the cause of a large proportion of defects in released software. Requirements can be improved by using mathematical modelling techniques. These have a number of advantages and a single major disadvantage--it is difficult to demonstrate a formal specification to a client or user. One proposed solution to this problem is to automatically derive (executable) prototypes of a system from a formal specification by using analysis. This process is known as animation. In this report we focus on the analyses used in an animation tool for the specification language Z. Specifically, we look at mode and subtype analyses. More extensive motivation and discussion of other aspects of the tool can be found elsewhere. Contents 1 Introduction 2 2 Overview 3 3 Mode Analysis 6 3.1 Specification : : : : : : : : : : : : : : : : : : : : : : : : : : : : : : : : : : 8 3.2 Problems with the specification : : : : : : : : : : : : : : : : : : : : : : : : 9 3.3 Using topological sorti...

