Results 11  20
of
33
Abstract Interpretation of Functional Languages: From Theory to Practice
, 1991
"... Abstract interpretation is the name applied to a number of techniques for reasoning about programs by evaluating them over nonstandard domains whose elements denote properties over the standard domains. This thesis is concerned with higherorder functional languages and abstract interpretations with ..."
Abstract

Cited by 25 (0 self)
 Add to MetaCart
Abstract interpretation is the name applied to a number of techniques for reasoning about programs by evaluating them over nonstandard domains whose elements denote properties over the standard domains. This thesis is concerned with higherorder functional languages and abstract interpretations with a formal semantic basis. It is known how abstract interpretation for the simply typed lambda calculus can be formalised by using binary logical relations. This has the advantage of making correctness and other semantic concerns straightforward to reason about. Its main disadvantage is that it enforces the identification of properties as sets. This thesis shows how the known formalism can be generalised by the use of ternary logical relations, and in particular how this allows abstract values to deno...
Caching intermediate results for program improvement
 In Proceedings of the 1995 ACM SIGPLAN Symposium on Partial Evaluation and SemanticsBased Program Manipulation, PEPM ’95
, 1995
"... A systematic approach is given for symbolically caching intermediate results useful for deriving incremental programs from nonincremental programs. We exploit a number of program analysis and transformation techniques, centered around e ective c a c hing based on its utilization in deriving increme ..."
Abstract

Cited by 22 (6 self)
 Add to MetaCart
A systematic approach is given for symbolically caching intermediate results useful for deriving incremental programs from nonincremental programs. We exploit a number of program analysis and transformation techniques, centered around e ective c a c hing based on its utilization in deriving incremental programs, in order to increase the degree of incrementality not otherwise achievable by using only the return values of programs that are of direct interest. Our method can be applied straightforwardly to provide a systematic approach to program improvement via caching. 1
Constructor Specialization
 In Schmidt [25
"... In the section on "challenging problems" in the proceedings from the first international workshop on partial evaluation and mixed computation [BEJ88] a question is stated: "Can PE be used to generate new specialized data types, in a way analogous to generating specialized functions". Since then litt ..."
Abstract

Cited by 16 (2 self)
 Add to MetaCart
In the section on "challenging problems" in the proceedings from the first international workshop on partial evaluation and mixed computation [BEJ88] a question is stated: "Can PE be used to generate new specialized data types, in a way analogous to generating specialized functions". Since then little has been done to address this problem. In [Lau89], new types are indeed generated, but they are all simpler versions of the types in the original program. It is, e.g. not possible to have types with more constructors than the types in the original program. I propose to alleviate this by means of constructor specialization. Constructors are specialized with respect to the static parts of their arguments, just like residual functions. I show how this is done and argue that it makes it possible to get good results from partial evaluation in cases where the traditional methods fail to produce satisfactory results. The discussion is centered around a small subset of Standard ML, but the idea a...
Eliminating dead code on recursive data
 Science of Computer Programming
, 1999
"... Abstract. This paper describes a general and powerful method for dead code analysis and elimination in the presence of recursive data constructions. We represent partially dead recursive data using liveness patterns based on general regular tree grammars extended with the notion of live and dead, an ..."
Abstract

Cited by 14 (4 self)
 Add to MetaCart
Abstract. This paper describes a general and powerful method for dead code analysis and elimination in the presence of recursive data constructions. We represent partially dead recursive data using liveness patterns based on general regular tree grammars extended with the notion of live and dead, and we formulate the analysis as computing liveness patterns at all program points based on program semantics. This analysis yields a most precise liveness pattern for the data at each program point, which is signi cantly more precise than results from previous methods. The analysis algorithm takes cubic time in terms of the size of the program in the worst case but is very e cient in practice, as shown by our prototype implementation. The analysis results are used to identify and eliminate dead code. The general framework for representing and analyzing properties of recursive data structures using general regular tree grammars applies to other analyses as well. 1
Higherorder Bindingtime Analysis
 In ACM Symposium on Partial Evaluation and SemanticsBased Program Manipulation (PEPM'93
, 1993
"... The partial evaluation process requires a bindingtime analysis. Bindingtime analysis seeks to determine which parts of a program's result is determined when some part of the input is known. Domain projections provide a very general way to encode a description of which parts of a data structure are ..."
Abstract

Cited by 13 (2 self)
 Add to MetaCart
The partial evaluation process requires a bindingtime analysis. Bindingtime analysis seeks to determine which parts of a program's result is determined when some part of the input is known. Domain projections provide a very general way to encode a description of which parts of a data structure are static (known), and which are dynamic (not static). For firstorder functional languages Launchbury [Lau91a] has developed an abstract interpretation technique for bindingtime analysis in which the basic abstract value is a projection. Unfortunately this technique does not generalise easily to higherorder languages. This paper develops such a generalisation: a projectionbased abstract interpretation suitable for higherorder bindingtime analysis. Launchbury [Lau91b] has shown that bindingtime analysis and strictness analysis are equivalent problems at first order, and for projectionbased analyses have exactly the same safety condition. We argue that the same is true at higher order, ...
Online Offline Partial Evaluation: Semantic Specifications and Correctness Proofs
 Yale University
, 1993
"... This paper presents semantic specifications and correctness proofs for both online and offline partial evaluation of strict firstorder functional programs. To do so, our strategy consists of defining a core semantics as a basis for the specification of three nonstandard evaluations: instrumented ..."
Abstract

Cited by 9 (1 self)
 Add to MetaCart
This paper presents semantic specifications and correctness proofs for both online and offline partial evaluation of strict firstorder functional programs. To do so, our strategy consists of defining a core semantics as a basis for the specification of three nonstandard evaluations: instrumented evaluation, online and offline partial evaluation. We then use the technique of logical relations to prove the correctness of both online and offline partial evaluation semantics. The contributions of this work are as follows. 1. We provide a uniform framework to defining and proving correct both online and offline partial evaluation. 2. This work required a formal specification of online partial evaluation with polyvariant specialization. We define criteria for its correctness with respect to an instrumented standard semantics. As a byproduct, online partial evaluation appears to be based on a fixpoint iteration process, just like bindingtime analysis. 3. We show that bindingtime...
Projections for Polymorphic FirstOrder Strictness Analysis
 Math. Struct. in Comp. Science
, 1991
"... this paper, that results from this kind of analysis are, in a sense, polymorphic. This confirms an earlier conjecture [19], and shows how the technique can be applied to firstorder polymorphic functions. The paper is organised as follows. In the next section, we review projectionbased strictness a ..."
Abstract

Cited by 6 (1 self)
 Add to MetaCart
this paper, that results from this kind of analysis are, in a sense, polymorphic. This confirms an earlier conjecture [19], and shows how the technique can be applied to firstorder polymorphic functions. The paper is organised as follows. In the next section, we review projectionbased strictness analysis very briefly. In Section 3 we introduce the types we will be working with: they are the objects of a category. We show that parameterised types are functors, with certain cancellation properties. In Section 4 we define strong and weak polymorphism: polymorphic functions in programming languages are strongly polymorphic, but we will need to use projections with a slightly weaker property. We prove that, under certain conditions, weakly polymorphic functions are characterised by any nontrivial instance. We can therefore analyse one monomorphic instance of a polymorphic function using existing techniques, and apply the results to every instance. In Section 5 we choose a finite set of projections for each type, suitable for use in a practical compiler. We call these specially chosen projections contexts, and we show examples of factorising contexts for compound types in order to facilitate application of the results of Section 4. We give a number of examples of polymorphic strictness analysis. Finally, in Section 6 we discuss related work and draw some conclusions. 2. Projections for Strictness Analysis
Implementing Projectionbased Strictness Analysis
 In Glasgow Workshop on Functional Programming
, 1992
"... Projectionbased backwards strictness analysis has been understood for some years. Surprisingly, even though the method is fairly simple and quite general, no reports of its implementation have appeared. This paper describes ideas underlying our prototype implementation of the analysis for a simple ..."
Abstract

Cited by 5 (1 self)
 Add to MetaCart
Projectionbased backwards strictness analysis has been understood for some years. Surprisingly, even though the method is fairly simple and quite general, no reports of its implementation have appeared. This paper describes ideas underlying our prototype implementation of the analysis for a simple programming language. The implementation serves as a case study before applying the method in the Glasgow Haskell compiler. 1 Introduction The method of projectionbased backwards strictness analysis for firstorder, lazy functional languages was first presented by Wadler and Hughes [8] in 1987. Since then it has been generalised by Hughes [4] and Hughes and Launchbury [3] to work for userdefined types and for polymorphism. Yet, to our knowledge, it has never been implemented even though the method is fairly simple and quite general. The time has come for projectionbased strictness analysis to meet practice. This paper describes a prototype implementation. Initially we expected that build...
A Note on the Choice of Domains for ProjectionBased Program Analysis
 In Functional Programming: Proceedings of the 1991 Glasgow Workshop
, 1992
"... Various nonstandard interpretations of functional programs have been proposed in which the basic nonstandard values are projections. We show that every stable function is completely determined by an appropriate abstract value in the backward analysis, and that every continuous function is complete ..."
Abstract

Cited by 3 (3 self)
 Add to MetaCart
Various nonstandard interpretations of functional programs have been proposed in which the basic nonstandard values are projections. We show that every stable function is completely determined by an appropriate abstract value in the backward analysis, and that every continuous function is completely determined by an appropriate value in the forward analysis. 1 Introduction Strictness analysis by abstract (or nonstandard) interpretation is an important part of several compilers for lazy functional languages [1, 2], and a wide variety of strictness analysis techniques have been proposed. The term forward is used to describe abstract interpretations in which the goal is to discover information about an entire expression given information at its leaves, while backward describes interpretations in which information flows in the other direction: the goal is to determine information at the leaves of an expression, given information about the entire expression. The development of backward ...