Results 1  10
of
15
Partial Evaluation for HigherOrder Languages with State
, 1996
"... We have designed and implemented an offline partial evaluator for a higherorder language with firstclass references. Its distinguishing feature over other partial evaluators is its ability to perform assignments to local and global references at specialization time for a higherorder language. The ..."
Abstract

Cited by 29 (7 self)
 Add to MetaCart
(Show Context)
We have designed and implemented an offline partial evaluator for a higherorder language with firstclass references. Its distinguishing feature over other partial evaluators is its ability to perform assignments to local and global references at specialization time for a higherorder language. The partial evaluator consists of a regionbased monovariant bindingtime analysis and a specializer in essentially continuationpassing storepassing style, thus generalizing typebased bindingtime analysis and continuationbased partial evaluation. The partial evaluator yields good results for realistic problems such as objectoriented programming, unification, and specializer generation. Keywords: higherorder programming, program transformation, partial evaluation, state Categories: D.1.1 Applicative (Functional) Programming, D.1.2 Automatic Programming, D.3.1 Formal Definitions and Theory, Semantics, D.3.2 Language Classifications, Applicative languages, D.3.4 Processors, I.2.2 Automatic...
A selfapplicable partial evaluator for the lambda calculus
 International Conference on Computer Languages
, 1990
"... This paper (essentially [12, Chapter 8]) describes partial evaluation for the lambda calculus, augmented with an explicit fixedpoint operator. The techniques used here diverge from those used in [12, Chapters 4, 5] and [11] in that they are not based on specialization of named program points. The a ..."
Abstract

Cited by 14 (4 self)
 Add to MetaCart
(Show Context)
This paper (essentially [12, Chapter 8]) describes partial evaluation for the lambda calculus, augmented with an explicit fixedpoint operator. The techniques used here diverge from those used in [12, Chapters 4, 5] and [11] in that they are not based on specialization of named program points. The algorithm essentially leaves some operators (applications, lambdas, etc.) untouched and reduces others as standard evaluation would do it. This simple scheme is able to handle programs that rely heavily on higherorder facilities. The requirements on bindingtime analysis are formulated via a type system and an ecient bindingtime analysis via constraint solving is outlined. The partial evaluator is proven correct.
A Typedirected, Online, Partial Evaluator for a Polymorphic Language
 In Proceedings of the Symposium on Partial Evaluation and SemanticsBased Program Manipulation
, 1997
"... Recently, Olivier Danvy introduced a new, simple method for implementing powerful partial evaluators, namely typedirected partial evaluation[9]. He introduced a partial evaluator for the simplytyped lambda calculus (x2). This paper explores the possibility of using the same techniques over a lambda ..."
Abstract

Cited by 12 (3 self)
 Add to MetaCart
Recently, Olivier Danvy introduced a new, simple method for implementing powerful partial evaluators, namely typedirected partial evaluation[9]. He introduced a partial evaluator for the simplytyped lambda calculus (x2). This paper explores the possibility of using the same techniques over a lambda calculus with a richer type system. We generalize and extend Danvy's work in four ways: 1. Our system handles a much richer language than that presented by Danvy, including all of the features functional programmers have come to expect, such as polymorphism (x5), inductive datatypes (x10), and recursion (x9). 2. Our system includes a new systematic treatment of primitive operators (x7) and the propagation of residualized code (x7.1). This question has either been ignored or treated in an adhoc manner in previous work. 3. Our system handles nonclosed terms (x6). This makes typedirected partial evaluation much more practically useful, and can easily be extended to work in languages wit...
Enforcing Safety Properties Using Type Specialization
 Proc. 10th European Symposium on Programming, Lecture Notes in Computer Science
, 2000
"... Type specialization can serve as a powerful tool in enforcing safety properties on foreign code. Using the specification of a monitoring interpreter, polyvariant type specialization can produce compiled code that is guaranteed to obey a specified safety policy. It propagates a security state at comp ..."
Abstract

Cited by 11 (3 self)
 Add to MetaCart
(Show Context)
Type specialization can serve as a powerful tool in enforcing safety properties on foreign code. Using the specification of a monitoring interpreter, polyvariant type specialization can produce compiled code that is guaranteed to obey a specified safety policy. It propagates a security state at compiletime and generates code for each different security state. The resulting code contains virtually no runtime operations on the security state, at the price of some code duplication. A novel extension of type specialization by intersection types limits the amount of code duplication considerably, thus making the approach practical. A few years back, mobile code was merely an exciting research subject. Meanwhile, the situation has changed dramatically and mobile code is about to invade our everyday lives. Many applications load parts of their code  or even thirdparty extension modules  from the network and run it on the local computer. Web browsers are the most prominent of these a...
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.
Monadic Type Systems: Pure Type Systems for Impure Settings (Preliminary Report)
 In Proceedings of the Second HOOTS Workshop
, 1997
"... Pure type systems and computational monads are two parameterized frameworks that have proved to be quite useful in both theoretical and practical applications. We join the foundational concepts of both of these to obtain monadic type systems. Essentially, monadic type systems inherit the parameteriz ..."
Abstract

Cited by 9 (2 self)
 Add to MetaCart
Pure type systems and computational monads are two parameterized frameworks that have proved to be quite useful in both theoretical and practical applications. We join the foundational concepts of both of these to obtain monadic type systems. Essentially, monadic type systems inherit the parameterized higherorder type structure of pure type systems and the monadic term and type structure used to capture computational effects in the theory of computational monads. We demonstrate that monadic type systems nicely characterize previous work and suggest how they can support several new theoretical and practical applications. A technical foundation for monadic type systems is laid by recasting and scaling up the main results from pure type systems (confluence, subject reduction, strong normalisation for particular classes of systems, etc.) and from operational presentations of computational monads (notions of operational equivalence based on applicative similarity, coinduction proof techni...
Program Generation, Termination, and Bindingtime Analysis
, 2002
"... Recent research suggests that the goal of fully automatic and reliable program generation for a broad range of applications is coming nearer to feasibility. However, several interesting and challenging problems remain to be solved before it becomes a reality. Solving them is also necessary, if we ho ..."
Abstract

Cited by 6 (0 self)
 Add to MetaCart
Recent research suggests that the goal of fully automatic and reliable program generation for a broad range of applications is coming nearer to feasibility. However, several interesting and challenging problems remain to be solved before it becomes a reality. Solving them is also necessary, if we hope ever to elevate software engineering from its current state (a highlydeveloped handiwork) into a successful branch of engineering, capable of solving a wide range of new problems by systematic, wellautomated and wellfounded methods.
Interpreting Specialization in Type Theory
"... We define the static semantics of offline partial evaluation for the simplytyped lambda calculus using a translation into a MartinLöfstyle type theory with suitable extensions. Our approach clarifies that the distinction between specializationtime and runtime computation in partial evaluation c ..."
Abstract

Cited by 3 (1 self)
 Add to MetaCart
We define the static semantics of offline partial evaluation for the simplytyped lambda calculus using a translation into a MartinLöfstyle type theory with suitable extensions. Our approach clarifies that the distinction between specializationtime and runtime computation in partial evaluation can model the phase distinction between compiletime and runtime computation in a module language. Working backwards from that connection, we define partial evaluation for a core language with modules.
FirstClass Polyvariant Functions and CoArity Raising
"... In partial evaluation, a polyvariant function is specialized to different specialized versions, depending on the calling context. Usually, polyvariance is limited to named, toplevel functions. We lift this restriction in a partial evaluator for a higherorder functional languages to obtain firstcl ..."
Abstract

Cited by 3 (0 self)
 Add to MetaCart
In partial evaluation, a polyvariant function is specialized to different specialized versions, depending on the calling context. Usually, polyvariance is limited to named, toplevel functions. We lift this restriction in a partial evaluator for a higherorder functional languages to obtain firstclass polyvariant functions. These functions are partially static and specialize to a memoization table. Arity raising splits a partially static parameter of a function into its dynamic components. Coarity raising is the dual to arity raising. It splits a partially static result of a function into its dynamic components. A specializer that performs coarity raising can transform a function returning one result into a function that returns any number of results, including zero. This technique enables polyvariant functions to return partially static results. We demonstrate the use of these techniques in combination by specializing a typed interpreter for a simplytyped applied lambda calculus s...
Enforcing Safety Properties by Program Specialization (Extended Abstract)
 URL citeseer.nj.nec.com/thiemann00enforcing.html
, 2000
"... Program specialization can serve as a powerful tool in enforcing safety properties. From the specifications of a safety policy and a suitably instrumented interpreter, a partial evaluator can produce a certifying compiler. The generated code from such a compiler is guaranteed to enforce the specifie ..."
Abstract

Cited by 2 (0 self)
 Add to MetaCart
(Show Context)
Program specialization can serve as a powerful tool in enforcing safety properties. From the specifications of a safety policy and a suitably instrumented interpreter, a partial evaluator can produce a certifying compiler. The generated code from such a compiler is guaranteed to enforce the specified safety policy. The compiler can work in two modes. In homogeneous mode, every construct of the source program is compiled once and augmented to process a security state at runtime. The compiler optimizes these runtime operations. In heterogeneous more, the security state is a compiletime value and the compiler generates code for each different security state. The resulting code contains virtually no runtime operations on the security state, at the price of moderate code duplication. Two different specialization technologies serve as our vehicles. Traditional partial evaluation is sufficient t...