• Documents
  • Authors
  • Tables
  • Log in
  • Sign up
  • MetaCart
  • DMCA
  • Donate

CiteSeerX logo

Advanced Search Include Citations
Advanced Search Include Citations

A study in higher-order programming languages (1997)

by Morten Rhiger
Add To MetaCart

Tools

Sorted by:
Results 1 - 7 of 7

Type-directed partial evaluation

by Olivier Danvy - Proceedings of the Twenty-Third Annual ACM Symposium on Principles of Programming Languages , 1996
"... Abstract. Type-directed partial evaluation stems from the residualization of arbitrary static values in dynamic contexts, given their type. Its algorithm coincides with the one for coercing asubtype value into a supertype value, which itself coincides with the one of normalization in the-calculus. T ..."
Abstract - Cited by 219 (38 self) - Add to MetaCart
Abstract. Type-directed partial evaluation stems from the residualization of arbitrary static values in dynamic contexts, given their type. Its algorithm coincides with the one for coercing asubtype value into a supertype value, which itself coincides with the one of normalization in the-calculus. Type-directed partial evaluation is thus used to specialize compiled, closed programs, given their type. Since Similix, let-insertion is a cornerstone of partial evaluators for callby-value procedural programs with computational e ects. It prevents the duplication of residual computations, and more generally maintains the order of dynamic side e ects in residual programs. This article describes the extension of type-directed partial evaluation to insert residual let expressions. This extension requires the userto annotate arrowtypes with e ect information. It is achieved by delimiting and abstracting control, comparably to continuation-based specialization in direct style. It enables type-directed partial evaluation of e ectful programs (e.g.,ade nitional lambda-interpreter for an imperative language) that are in direct style. The residual programs are in A-normal form. 1
(Show Context)

Citation Context

...of use. Type-directed partial evaluation wassrst developed in Scheme, and amounted to achieving specialization by Scheme evaluation [14{16]. Andrzej Filinski, and then Zhe Yang [59] and Morten Rhiger =-=[49, 50]-=- found how to express it in a Hindley-Milner type setting, i.e., in ML and in Haskell, thus achieving specialization by ML and Haskell evaluation. In addition, the Hindley-Milner typing system ensures...

Online Type-Directed Partial Evaluation for Dynamically-Typed Languages

by Eijiro Sumii, Naoki Kobayashi - Computer Software , 1999
"... This article presents an alternative method of type-directed partial evaluation, which is simpler and more efficient than previous methods. Unlike previous methods, it is straightforwardly applicable to functional languages with various powerful type systems. As an extreme instance, this article mai ..."
Abstract - Cited by 6 (1 self) - Add to MetaCart
This article presents an alternative method of type-directed partial evaluation, which is simpler and more efficient than previous methods. Unlike previous methods, it is straightforwardly applicable to functional languages with various powerful type systems. As an extreme instance, this article mainly deals with a dynamically-typed functional language like Scheme. The key idea is to extend primitive value destructors such as function application and pair destruction (car and cdr), so that they generate residual code when their operands are dynamic. It unnecessitates an operation in type-directed partial evaluation called reflection, which was the major cause of complication and inefficiency in previous methods. We formalize our method as an extension of two-level -calculus, and prove it correct. Furthermore, we show that our type-directed partial evaluator can be derived from a simple online syntax-directed partial evaluator with higher-order abstract syntax, by the same transformatio...
(Show Context)

Citation Context

...a waste of the memory (for storing the intermediate data structure) and the time (for traversing it by pattern matching). We can remove the overhead by composing the constructors with the destructors =-=[13, 15]-=-. fun rHAbs f = HAbs(fn x =? f x) fun rHApp(t1, t2) = let val t1' = t1 val t2' = t2 in (case t1' of HAbs f =? f t2' ---s=? HApp(t1', t2')) end We can simplify these composed constructors by j-reductio...

Deriving a Statically Typed Type-Directed Partial Evaluator

by Morten Rhiger - In Danvy [12 , 1999
"... Type-directed partial evaluation was originally implemented in Scheme, a dynamically typed language. It has also been implemented in ML, a statically Hindley-Milner typed language. This note shows how the latter implementation can be derived from the former through a functional representation of ind ..."
Abstract - Cited by 5 (2 self) - Add to MetaCart
Type-directed partial evaluation was originally implemented in Scheme, a dynamically typed language. It has also been implemented in ML, a statically Hindley-Milner typed language. This note shows how the latter implementation can be derived from the former through a functional representation of inductively dened types. 1 Introduction Type-directed partial evaluation is an approach to specializing a term written in a higher-order language. Such a higher-order term is specialized by normalizing it with respect to its type. Normalization is done by eta-expanding the term in a two-level lambda-calculus and statically betareducing the expanded term. The two stages | eta-expansion and beta-reduction | share an intermediate result: a two-level term. We consider two versions of the type-directed partial evaluation algorithm: (i) If the two-level term is represented as a value of an inductively dened data type then the algorithm can be implemented in any (Turing complete) language. In thi...
(Show Context)

Citation Context

...The present work was carried out in the fall of 1997 and, according to Olivier Danvy, it is the third independent implementation of type-directed partial evaluation in a Hindley-Milner typed language =-=[7-=-]. Kristoer Rose implemented type-directed partial evaluation in Haskell in the spring of 1998 using type classes [8]. Haskell's type classes permit overloaded functions, i.e., functions that have sev...

Two Flavors of Offline Partial Evaluation

by Simon Helsen, Peter Thiemann , 1998
"... Type-directed partial evaluation is a new approach to program specialization for functional programming languages. Its merits with respect to the traditional offline partial evaluation approach have not yet been fully explored. We present a comparison of type-directed partial evaluation with standa ..."
Abstract - Cited by 3 (0 self) - Add to MetaCart
Type-directed partial evaluation is a new approach to program specialization for functional programming languages. Its merits with respect to the traditional offline partial evaluation approach have not yet been fully explored. We present a comparison of type-directed partial evaluation with standard offline partial evaluation in both a qualitative and quantitative way. For the latter we use implementations of both approaches in Scheme. Both approaches yield equivalent results in comparable time.
(Show Context)

Citation Context

...y more powerful and yield strictly better results than traditional methods. To match these results, a traditional partial evaluator must revert to multiple passes including aggressive post-processing =-=[39]-=-. The rest of the paper is structured as follows. In Sec. 2 we introduce traditional partial evaluation as well as TDPE. Section 3 formulates important aspects of specialization and puts them into per...

This document in subdirectoryRS/98/9/ Encoding Types in ML-like Languages (preliminary version)

by Zhe Yang, Zhe Yang , 1998
"... Reproduction of all or part of this work is permitted for educational or research use on condition that this copyright notice is included in any copy. See back inner page for a list of recent BRICS Report Series publications. Copies may be obtained by contacting: BRICS ..."
Abstract - Add to MetaCart
Reproduction of all or part of this work is permitted for educational or research use on condition that this copyright notice is included in any copy. See back inner page for a list of recent BRICS Report Series publications. Copies may be obtained by contacting: BRICS
(Show Context)

Citation Context

...typed language such as ML or Haskell. The author answered the challenge in 1996, which, according to Danvy, is the first solution after Filinski’s. The third person to have solved it is Morten Rhiger =-=[26]-=-. Since then, Kristoffer Rose has programmed it in Haskell, using type classes [27]. An interesting common pattern shared by type-directed partial evaluation and the embedding/projection-based approac...

This document in subdirectoryRS/98/13/ Compiling Actions by Partial Evaluation, Revisited

by Olivier Danvy, Morten Rhiger, Olivier Danvy, Morten Rhiger
"... ..."
Abstract - Add to MetaCart
Abstract not found

This document in subdirectoryRS/97/53/ Online Type-Directed

by Olivier Danvy, Olivier Danvy , 1997
"... Reproduction of all or part of this work is permitted for educational or research use on condition that this copyright notice is included in any copy. See back inner page for a list of recent BRICS Report Series publications. Copies may be obtained by contacting: BRICS ..."
Abstract - Add to MetaCart
Reproduction of all or part of this work is permitted for educational or research use on condition that this copyright notice is included in any copy. See back inner page for a list of recent BRICS Report Series publications. Copies may be obtained by contacting: BRICS
(Show Context)

Citation Context

...d, are hygienic macros 2 where abstract syntax is accessed by pattern matching. In this section, we briefly present a domain-specific language over residual terms, designed jointly with Morten Rhiger =-=[34]-=-. This language follows Kohlbecker and Dybvig’s lead, with a special form case-syntax (see Figure 5) providing access to residual terms by pattern matching. Dynamic versions of primitive operators are...

Powered by: Apache Solr
  • About CiteSeerX
  • Submit and Index Documents
  • Privacy Policy
  • Help
  • Data
  • Source
  • Contact Us

Developed at and hosted by The College of Information Sciences and Technology

© 2007-2019 The Pennsylvania State University