Results 1  10
of
13
On the Complexity Analysis of Static Analyses
 Journal of the ACM
, 1999
"... . This paper argues that for many algorithms, and static analysis ..."
Abstract

Cited by 75 (3 self)
 Add to MetaCart
(Show Context)
. This paper argues that for many algorithms, and static analysis
ControlFlow Analysis and Type Systems
, 1995
"... . We establish a series of equivalences between type systems and controlflow analyses. Specifically, we take four type systems from the literature (involving simple types, subtypes and recursion) and conservatively extend them to reason about controlflow information. Similarly, we take four standa ..."
Abstract

Cited by 49 (1 self)
 Add to MetaCart
. We establish a series of equivalences between type systems and controlflow analyses. Specifically, we take four type systems from the literature (involving simple types, subtypes and recursion) and conservatively extend them to reason about controlflow information. Similarly, we take four standard controlflow systems and conservatively extend them to reason about type consistency. Our main result is that we can match up the resulting type and controlflow systems such that we obtain pairs of equivalent systems, where the equivalence is with respect to both type and controlflow information. In essence, type systems and controlflow analysis can be viewed as complementary approaches for addressing questions of type consistency and controlflow. Recent and independent work by Palsberg and O'Keefe has addressed the same general question. Our work differs from theirs in two respects. First, they only consider what happens when controlflow systems are used to reason about types. In co...
Lineartime Subtransitive Control Flow Analysis
, 1997
"... We present a lineartime algorithm for boundedtype programs that builds a directed graph whose transitive closure gives exactly the results of the standard (cubictime) ControlFlow Analysis (CFA) algorithm. Our algorithm can be used to list all functions calls from all call sites in (optimal) quadr ..."
Abstract

Cited by 49 (1 self)
 Add to MetaCart
We present a lineartime algorithm for boundedtype programs that builds a directed graph whose transitive closure gives exactly the results of the standard (cubictime) ControlFlow Analysis (CFA) algorithm. Our algorithm can be used to list all functions calls from all call sites in (optimal) quadratic time. More importantly, it can be used to give lineartime algorithms for CFAconsuming applications such as: ffl effects analysis: find the sideeffecting expressions in a program. ffl klimited CFA: for each callsite, list the functions if there are only a few of them ( k) and otherwise output "many". ffl calledonce analysis: identify all functions called from only one callsite. 1 Introduction The controlflow graph of a program plays a central role in compilation  it identifies the block and loop structure in a program, a prerequisite for many code optimizations. For firstorder languages, this graph can be directly constructed from a program because information about flow of ...
On the Cubic Bottleneck in Subtyping and Flow Analysis
, 1997
"... A variety of program analysis methods have worst case time complexity that grows cubicly in the length of the program being analyzed. Cubic complexity typically arises in control flow analyses and the inference of recursive types (including object types). It is often said that such cubic performance ..."
Abstract

Cited by 34 (6 self)
 Add to MetaCart
A variety of program analysis methods have worst case time complexity that grows cubicly in the length of the program being analyzed. Cubic complexity typically arises in control flow analyses and the inference of recursive types (including object types). It is often said that such cubic performance can not be improved because these analyses require "dynamic transitive closure". Here we prove linear time reductions from the problem of determining membership for languages defined by 2way nondeterministic pushdown automata (2NPDA) to problems of flow analysis and typability in the AmadioCardelli type system. An O(n 3 ) algorithm was given for 2NPDA acceptability in 1968 and is still the best known. The reductions are factored through the problem of "monotone closure" and we propose linear time reduction of the monotone closure as a method of establishing "monotone closure hardness" for program analysis problems. A subcubic procedure for a monotone closure hard problem would imply a ...
Cogen in Six Lines
 Proc. International Conference on Functional Programming
, 1996
"... We have designed and implemented a programgenerator generator (PGG) for an untyped higherorder functional programming language. The program generators perform continuationbased multilevel offline specialization and thus combine the most powerful and general offline partial evaluation techniques. ..."
Abstract

Cited by 31 (11 self)
 Add to MetaCart
We have designed and implemented a programgenerator generator (PGG) for an untyped higherorder functional programming language. The program generators perform continuationbased multilevel offline specialization and thus combine the most powerful and general offline partial evaluation techniques. The correctness of the PGG is ensured by deriving it from a multilevel specializer. Our PGG is extremely simple to implement due to the use of multilevel techniques and higherorder abstract syntax. Keywords: partial evaluation, multilevel computation, continuations. 1 Introduction An attractive feature of partial evaluation is the ability to generate generating extensions. A generating extension for a program p with two inputs inp s and inp d is a program pgen which accepts the static input inp s of p and produces a residual program p s which accepts the dynamic input inp d and produces the same result as JpK inp s inp d , provided both p and p s terminate. JpgenK inp ...
The Essence of LR Parsing
 In Proceedings of the ACM SIGPLAN Symposium on Partial Evaluation and SemanticsBased Program Manipulation
, 1995
"... Partial evaluation can turn a generalparser into a parser generator. The generated parsers surpass those produced by traditional parser generators in speed and compactness. We use an inherently functional approach to implement general LR(k) parsers and specialize them using the partial evaluator Si ..."
Abstract

Cited by 19 (6 self)
 Add to MetaCart
(Show Context)
Partial evaluation can turn a generalparser into a parser generator. The generated parsers surpass those produced by traditional parser generators in speed and compactness. We use an inherently functional approach to implement general LR(k) parsers and specialize them using the partial evaluator Similix. The functional implementation of LR parsing allows for concise implementation of the algorithmsthemselves and requires only straightforwardchanges to achieve good specialization results. In contrast, a traditional, stackbased implementation of a general LR parser requires significant structural changes to make it amenable to satisfactory specialization. 1 Introduction We present two inherently functional implementations of general LR(k) parsers: a directstyle firstorder textbook version and one using continuationpassing style (CPS) for statetransitions. Neither requires the handling of an explicit parsing stack. These parsers, when specialized with respect to a grammar and lookah...
Termination Analysis and SpecializationPoint Insertion in Offline Partial Evaluation
 ACM Trans. Program. Lang. Syst
, 2004
"... interpretation or constraint solving analyses may be used to detect both modalities of sizechange behavior, and can be found in the literature [Chin and Khoo 2002; Hughes et al. 1996]. We develop analyses for the current context in Section 5, in the style of Jones et al. [1993, Section 14.3]. ..."
Abstract

Cited by 16 (2 self)
 Add to MetaCart
(Show Context)
interpretation or constraint solving analyses may be used to detect both modalities of sizechange behavior, and can be found in the literature [Chin and Khoo 2002; Hughes et al. 1996]. We develop analyses for the current context in Section 5, in the style of Jones et al. [1993, Section 14.3].
Towards Partial Evaluation of Full Scheme
 Reflection 96
, 1996
"... We present a bindingtime analysis for Scheme which enables an offline partial evaluator to successfully treat Scheme's reflective features eval, apply, and the control operator call/cc. Additionally, our analysis empowers the specializer to select the most efficient representation for each obj ..."
Abstract

Cited by 14 (4 self)
 Add to MetaCart
We present a bindingtime analysis for Scheme which enables an offline partial evaluator to successfully treat Scheme's reflective features eval, apply, and the control operator call/cc. Additionally, our analysis empowers the specializer to select the most efficient representation for each object. This removes some limitations of previous specializers regarding the use of higherorder functions. The theoretical development is backed by an implementation. Keywords: partial evaluation of reflective language features, metacomputation The programming language Scheme [20] is an ideal vehicle for metacomputation, specifically for partial evaluation. Part of the appropriateness of Scheme for metacomputation tasks derives from its reflective features: eval [27], which reflects the external representation of, say, a procedure to a functional value, apply, which reflects lists to argument lists, and call/cc 1 , which makes the continuation of the current expression available as a proced...
Type Specialisation for Imperative Languages
 PROC. INTERNATIONAL CONFERENCE ON FUNCTIONAL PROGRAMMING
, 1997
"... We extend type specialisation to a computational lambda calculus with firstclass references. The resulting specialiser has been used to specialise a selfinterpreter for this typed computational lambda calculus optimally. Furthermore, this specialiser can perform operations on references at special ..."
Abstract

Cited by 9 (6 self)
 Add to MetaCart
We extend type specialisation to a computational lambda calculus with firstclass references. The resulting specialiser has been used to specialise a selfinterpreter for this typed computational lambda calculus optimally. Furthermore, this specialiser can perform operations on references at specialisation time, when possible.
A Unified Framework for BindingTime Analysis
 Colloquium on Formal Approaches in Software Engineering (FASE '97), volume 1214 of Lect
, 1997
"... . Bindingtime analysis is a crucial part of offline partial evaluation. It is often specified as a nonstandard type system. Many typebased bindingtime analyses are reminiscent of simple type systems with additional features like recursive types. We make this connection explicit by expressing bind ..."
Abstract

Cited by 7 (3 self)
 Add to MetaCart
(Show Context)
. Bindingtime analysis is a crucial part of offline partial evaluation. It is often specified as a nonstandard type system. Many typebased bindingtime analyses are reminiscent of simple type systems with additional features like recursive types. We make this connection explicit by expressing bindingtime analysis with annotated type systems that separate the concerns of type inference from those of bindingtime annotation. The separation enables us to explore a design space for bindingtime analysis by varying the underlying type system and the annotation strategy independently. The result is a classification of different monovariant bindingtime analyses which allows us to compare their relative power. Due to the systematic approach we uncover some novel analyses. A partial evaluator separates the computation of a source program into two or more stages [7, 20]. Using the (static) input of the first stage it transforms a source program into a specialized residual program. Application...