Results 1 - 10
of
12
Tagless Staged Interpreters for Typed Languages
- In the International Conference on Functional Programming (ICFP ’02
, 2002
"... Multi-stage programming languages provide a convenient notation for explicitly staging programs. Staging a definitional interpreter for a domain specific language is one way of deriving an implementation that is both readable and efficient. In an untyped setting, staging an interpreter "removes a co ..."
Abstract
-
Cited by 43 (11 self)
- Add to MetaCart
Multi-stage programming languages provide a convenient notation for explicitly staging programs. Staging a definitional interpreter for a domain specific language is one way of deriving an implementation that is both readable and efficient. In an untyped setting, staging an interpreter "removes a complete layer of interpretive overhead", just like partial evaluation. In a typed setting however, Hindley-Milner type systems do not allow us to exploit typing information in the language being interpreted. In practice, this can have a slowdown cost factor of three or more times.
A gentle introduction to multi-stage programming
- Domain-specific Program Generation, LNCS
, 2004
"... ..."
ML-like Inference for Classifiers
- In European Symposium on Programming, ESOP’04, D. Schmidt, Ed. Springer-Verlag LNCS 2986
, 2004
"... Environment classifiers were proposed as a new approach to typing multi-stage languages. Safety was established in the simply-typed and let-polymorphic settings. While the motivation for classifiers was the feasibility of inference, this was in fact not established. This paper starts with the ob ..."
Abstract
-
Cited by 22 (7 self)
- Add to MetaCart
Environment classifiers were proposed as a new approach to typing multi-stage languages. Safety was established in the simply-typed and let-polymorphic settings. While the motivation for classifiers was the feasibility of inference, this was in fact not established. This paper starts with the observation that inference for the full classifier-based system fails. We then identify a subset of the original system for which inference is possible. This subset, which uses implicit classifiers, retains significant expressivity (e.g. it can embed the calculi of Davies and Pfenning) and eliminates the need for classifier names in terms. Implicit classifiers were implemented in MetaOCaml, and no changes were needed to make an existing test suite acceptable by the new type checker.
Implicitly Heterogeneous Multi-Stage Programming
- Proceedings of the ACM International Conference on Generative Programming and Component Engineering (GPCE’05), volume 3676 of Lecture Notes In Computer Science
, 2005
"... Previous work on semantics-based multi-stage programming (MSP) language design focused on homogeneous designs, where the generating and the generated languages are the same. Homogeneous designs simply add a hygienic quasi-quotation and evaluation mechanism to a base language. An apparent disadva ..."
Abstract
-
Cited by 7 (1 self)
- Add to MetaCart
Previous work on semantics-based multi-stage programming (MSP) language design focused on homogeneous designs, where the generating and the generated languages are the same. Homogeneous designs simply add a hygienic quasi-quotation and evaluation mechanism to a base language. An apparent disadvantage of this approach is that the programmer is bound to both the expressivity and performance characteristics of the base language. This paper proposes a practical means to avoid this by providing specialized translations from subsets of the base language to di#erent target languages. This approach preserves the homogeneous "look" of multi-stage programs, and, more importantly, the static guarantees about the generated code. In addition, compared to an explicitly heterogeneous approach, it promotes reuse of generator source code and systematic exploration of the performance characteristics of the target languages.
Relating FFTW and Split-Radix
- Proceedings of the International Conference on Embedded Software and Systems (ICESS ’04), volume 3605 of Lecture Notes in Computer Science
, 2004
"... Recent work showed that staging and abstract interpretation can be used to derive correct families of combinatorial circuits, and illustrated this technique with an in-depth analysis of the Fast Fourier Transform (FFT) for sizes 2 . ..."
Abstract
-
Cited by 7 (4 self)
- Add to MetaCart
Recent work showed that staging and abstract interpretation can be used to derive correct families of combinatorial circuits, and illustrated this technique with an in-depth analysis of the Fast Fourier Transform (FFT) for sizes 2 .
Staged Notational Definitions
- GENERATIVE PROGRAMMING AND COMPONENT ENGINEERING (GPCE), LECTURE NOTES IN COMPUTER SCIENCE
, 2003
"... Recent work proposed defining type-safe macros via interpretation into a multi-stage language. The utility of this approach was illustrated with a language called MacroML, in which all type checking is carried out before macro expansion. Building on this work, the goal of this paper is to develo ..."
Abstract
-
Cited by 6 (3 self)
- Add to MetaCart
Recent work proposed defining type-safe macros via interpretation into a multi-stage language. The utility of this approach was illustrated with a language called MacroML, in which all type checking is carried out before macro expansion. Building on this work, the goal of this paper is to develop a macro language that makes it easy for programmers to reason about terms locally. We show that defining the semantics of macros in this manner helps in developing and verifying not only type systems for macro languages but also equational reasoning principles. Because the MacroML calculus is sensetive to renaming of (what appear locally to be) bound variables, we present a calculus of staged notational definitions (SND) that eliminates the renaming problem but retains MacroML's phase distinction. Additionally, SND incorporates the generality of Griffin's account of notational definitions. We exhibit a formal equational theory for SND and prove its soundness.
Generating heap-bounded programs in a functional setting
- In EMSOFT
, 2003
"... ? Supported by NSF grants ITR-0113569, CCR-0224244 and CCR-0229480. ..."
Abstract
-
Cited by 6 (0 self)
- Add to MetaCart
? Supported by NSF grants ITR-0113569, CCR-0224244 and CCR-0229480.
Preview: An untyped graphical calculus for resource-aware programming
- Rice University
, 2004
"... As visual programming languages become both more expressive and more popular in the domains of real-time and embedded software, the need for rigorous techniques for rea-soning about programs written in these languages becomes more pressing. Indeed, due to a subtle but fundamental mismatch between gr ..."
Abstract
-
Cited by 3 (1 self)
- Add to MetaCart
As visual programming languages become both more expressive and more popular in the domains of real-time and embedded software, the need for rigorous techniques for rea-soning about programs written in these languages becomes more pressing. Indeed, due to a subtle but fundamental mismatch between graphical and textual representations of pro-grams, semantic concepts established in the textual setting cannot be mapped to the graph-ical setting without a careful analysis of the connection between the two representations. Focusing on operational (as opposed to type-theoretic) aspects of Resource-aware Pro-gramming (RAP), we analyze the connection between graphical and textual representations of programs that can express both higher-order functions and staging constructs. After es-tablishing a precise connection between the two, we illustrate how this connection can be used to lift a reduction semantics from the textual to the graphical setting. I am very grateful for the dedication and support I received from my advisor Dr. Walid Taha while working on this thesis. I also want to thank the members of my thesis committee (Dr. Keith Cooper, Dr. Robert Cartwright, Dr. Peter Druschel, and Dr. Moshe Vardi) for their time and their interest in my work. Kedar Swadi, Samah Abu Mahmeed, and Roumen
The semantics of graphical languages
- 2006. Available in Informal Proceedings of DCC
, 2006
"... Visual notations are pervasive in circuit design, control systems, and increasingly in mainstream programming environments. Yet many of the foundational advances in programming language theory are taking place in the context of textual notations. In order to map such advances to the graphical world, ..."
Abstract
-
Cited by 2 (0 self)
- Add to MetaCart
Visual notations are pervasive in circuit design, control systems, and increasingly in mainstream programming environments. Yet many of the foundational advances in programming language theory are taking place in the context of textual notations. In order to map such advances to the graphical world, and to take the concerns of the graphical world into account when working with textual formalisms, there is a need for rigorous connections between textual and graphical expressions of computation. To this end, this paper presents a graphical calculus called Uccello. Our key insight is that Ariola and Blom’s work on sharing in the cyclic lambda calculus provides an excellent foundation for formalizing the semantics of graphical languages. As an example of what can be done with this foundation, we use it to extend a graphical language with staging constructs. In doing so, we provide the first formal account of sharing in a multi-stage calculus. 1.
Practical aspects of multi-stage programming, rice University
, 2004
"... Abstract. High-level languages offer abstraction mechanisms that can reduce development time and improve software quality. But abstraction mechanisms often have an accumulative runtime overhead that can discourage their use. Multi-stage programming (MSP) languages offer constructs that make it possi ..."
Abstract
-
Cited by 1 (0 self)
- Add to MetaCart
Abstract. High-level languages offer abstraction mechanisms that can reduce development time and improve software quality. But abstraction mechanisms often have an accumulative runtime overhead that can discourage their use. Multi-stage programming (MSP) languages offer constructs that make it possible to use abstraction mechanisms without paying a runtime overhead. This paper studies applying MSP to implementing dynamic programming (DP) problems. The study reveals that staging high-level implementations of DP algorithms naturally leads to a code explosion problem. In addition, it is common that high-level languages are not designed to deliver the kind of performance that is desirable in implementations of such algorithms. The paper proposes a solution to each of these two problems. Staged memoization is used for code explosion, and a kind of “offshoring ” translation is used to address the second. For basic DP problems, the performance of the resulting specialized C implementations is almost always better than the hand-written generic C implementations. 1

