Results 11 - 20
of
91
Semantics of Types for Mutable State
, 2004
"... Proof-carrying code (PCC) is a framework for mechanically verifying the safety of machine language programs. A program that is successfully verified by a PCC system is guaranteed to be safe to execute, but this safety guarantee is contingent upon the correctness of various trusted components. For in ..."
Abstract
-
Cited by 44 (5 self)
- Add to MetaCart
Proof-carrying code (PCC) is a framework for mechanically verifying the safety of machine language programs. A program that is successfully verified by a PCC system is guaranteed to be safe to execute, but this safety guarantee is contingent upon the correctness of various trusted components. For instance, in traditional PCC systems the trusted computing base includes a large set of low-level typing rules. Foundational PCC systems seek to minimize the size of the trusted computing base. In particular, they eliminate the need to trust complex, low-level type systems by providing machine-checkable proofs of type soundness for real machine languages. In this thesis, I demonstrate the use of logical relations for proving the soundness of type systems for mutable state. Specifically, I focus on type systems that ensure the safe allocation, update, and reuse of memory. For each type in the language, I define logical relations that explain the meaning of the type in terms of the oper-ational semantics of the language. Using this model of types, I prove each typing rule as a lemma. The major contribution is a model of System F with general references — that is, mutable cells that can hold values of any closed type including other references, functions, recursive types, and impredicative quantified types. The model is based on ideas from both possible worlds and the indexed model of Appel and McAllester. I show how the model of mutable references is encoded in higher-order logic. I also show how to construct an indexed possible-worlds model for a von Neumann machine. The latter is used in the Princeton Foundational PCC system to prove type safety for a full-fledged low-level typed assembly language. Finally, I present a semantic model for a region calculus that supports type-invariant references as well as memory reuse. iii
Time and Space Profiling for Non-Strict, Higher-Order Functional Languages
- In 22'nd ACM Symposium on Principles of Programming Languages
, 1995
"... We present the first profiler for a compiled, non-strict, higher-order, purely functional language capable of measuring time as well as space usage. Our profiler is implemented in a production-quality optimising compiler for Haskell, has low overheads, and can successfully profile large application ..."
Abstract
-
Cited by 39 (7 self)
- Add to MetaCart
We present the first profiler for a compiled, non-strict, higher-order, purely functional language capable of measuring time as well as space usage. Our profiler is implemented in a production-quality optimising compiler for Haskell, has low overheads, and can successfully profile large applications. A unique feature of our approach is that we give a formal specification of the attribution of execution costs to cost centres. This specification enables us to discuss our design decisions in a precise framework. Since it is not obvious how to map this specification onto a particular implementation, we also present an implementation-oriented operational semantics, and prove it equivalent to the specification. 1 Motivation and overview Everyone knows the importance of profiling tools: the best way to improve a program's performance is to concentrate on the parts of the program which are eating the lion's share of the total space and time resources. One would expect profiling tools to be ...
Benchmarking implementations of lazy functional languages II - Two years later
- In 6th Functional programming languages and computer architecture
, 1993
"... Six implementations of different lazy functional languages are compared using a common benchmark of a dozen medium-sized programs. The experiments that were carried out two years ago have been repeated to chart progress in the development of these compilers. The results have been extended to include ..."
Abstract
-
Cited by 33 (5 self)
- Add to MetaCart
Six implementations of different lazy functional languages are compared using a common benchmark of a dozen medium-sized programs. The experiments that were carried out two years ago have been repeated to chart progress in the development of these compilers. The results have been extended to include all three major Haskell compilers. Over the last two years, the Glasgow Haskell compiler has been improved considerably. The other compilers have also been improved, but to a lesser extent. The Yale Haskell compiler is slower than the Glasgow and Chalmers Haskell compilers. The compilation speed of the Clean compiler is still unrivalled. Another extension is a comparison of results on different architectures so as to look at architectural influences on the benchmarking procedure. A high-end architecture should be avoided for benchmarking activities, as its behaviour is uneven. It is better to use a midrange machine if possible. 1 Introduction In the previous benchmark paper [10], which wi...
Type-Preserving Compilation of Featherweight Java
, 2001
"... We present an efficient encoding of core Java constructs in a simple, implementable typed intermediate language. The encoding, after type erasure, has the same operational behavior as a standard implementation using vtables and selfapplication for method invocation. Classes inherit super-class metho ..."
Abstract
-
Cited by 33 (8 self)
- Add to MetaCart
We present an efficient encoding of core Java constructs in a simple, implementable typed intermediate language. The encoding, after type erasure, has the same operational behavior as a standard implementation using vtables and selfapplication for method invocation. Classes inherit super-class methods with no overhead. We support mutually recursive classes while preserving separate compilation. Our strategy extends naturally to a significant subset of Java, including interfaces and privacy. The formal translation using Featherweight Java allows comprehensible type-preservation proofs and serves as a starting point for extending the translation to new features.
Strongly Typed Flow-Directed Representation Transformations (Extended Abstract)
- In ICFP ’97 [ICFP97
, 1997
"... We present a new framework for transforming data representations in a strongly typed intermediate language. Our method allows both value producers (sources) and value consumers (sinks) to support multiple representations, automatically inserting any required code. Specialized representations can be ..."
Abstract
-
Cited by 29 (13 self)
- Add to MetaCart
We present a new framework for transforming data representations in a strongly typed intermediate language. Our method allows both value producers (sources) and value consumers (sinks) to support multiple representations, automatically inserting any required code. Specialized representations can be easily chosen for particular source/sink pairs. The framework is based on these techniques: 1. Flow annotated types encode the "flows-from" (source) and "flows-to" (sink) information of a flow graph. 2. Intersection and union types support (a) encoding precise flow information, (b) separating flow information so that transformations can be well typed, (c) automatically reorganizing flow paths to enable multiple representations. As an instance of our framework, we provide a function representation transformation that encompasses both closure conversion and inlining. Our framework is adaptable to data other than functions.
Functional Implementations of Continuous Modeled Animation (Expanded Version)
, 1998
"... Animation is a temporally continuous phenomenon, but is typically programmed in terms of a discrete sequence of changes. The use of discreteness serves to accommodate the machine that is presenting an animation, rather than the person modeling an animation with the help of a computer. Using a co ..."
Abstract
-
Cited by 27 (6 self)
- Add to MetaCart
Animation is a temporally continuous phenomenon, but is typically programmed in terms of a discrete sequence of changes. The use of discreteness serves to accommodate the machine that is presenting an animation, rather than the person modeling an animation with the help of a computer. Using a continuous model of time for animation allows for natural specification, avoiding some artificial details, but is difficult to implement with generality, robustness and efficiency. This paper presents and motivates continuous modeled animation, and sketches out a naive functional implementation for it. An examination of some of the practical problems with this implementation leads to several alternate representations, all of which have difficulties in themselves, some quite subtle. We hope that the insights and techniques discussed in this paper lead to still better representations, so that animation may be specified in natural terms without significant loss of performance.
Principality and Type Inference for Intersection Types Using Expansion Variables
, 2003
"... Principality of typings is the property that for each typable term, there is a typing from which all other typings are obtained via some set of operations. Type inference is the problem of finding a typing for a given term, if possible. We define an intersection type system which has principal typ ..."
Abstract
-
Cited by 24 (12 self)
- Add to MetaCart
Principality of typings is the property that for each typable term, there is a typing from which all other typings are obtained via some set of operations. Type inference is the problem of finding a typing for a given term, if possible. We define an intersection type system which has principal typings and types exactly the strongly normalizable #-terms. More interestingly, every finite-rank restriction of this system (using Leivant's first notion of rank) has principal typings and also has decidable type inference.
Parametric Polymorphism for XML
, 2004
"... Although several type systems have been investigated for XML, parametric polymorphism is rarely treated. This well-established typing discipline can also be useful in XML processing in particular for programs involving "parametric schemas," i.e., schemas parameterized over other schemas (e.g., SOA ..."
Abstract
-
Cited by 23 (3 self)
- Add to MetaCart
Although several type systems have been investigated for XML, parametric polymorphism is rarely treated. This well-established typing discipline can also be useful in XML processing in particular for programs involving "parametric schemas," i.e., schemas parameterized over other schemas (e.g., SOAP). The
Dynamic Typing for Distributed Programming in Polymorphic Languages
- ACM Transactions on Programming Languages and Systems
, 1996
"... While static typing is widely accepted as being necessary for secure program execution, dynamic typing is also viewed as being essential in some applications. Dynamics have been proposed as a way of introducing dynamic typing into statically typed languages, with particular application to programmin ..."
Abstract
-
Cited by 21 (5 self)
- Add to MetaCart
While static typing is widely accepted as being necessary for secure program execution, dynamic typing is also viewed as being essential in some applications. Dynamics have been proposed as a way of introducing dynamic typing into statically typed languages, with particular application to programming in distributed environments. However proposals for incorporating dynamics into languages with parametric polymorphism, such as ML, have serious shortcomings. A new approach is presented to extending ML-like languages with dynamic typing. This approach has particular usefulness for programming in distributed environments, where many of the practical applications of dynamic typing arise. At the heart of the approach is the use of type-based computation, where polymorphic functions may analyse the structure of their type arguments. This approach solves several open problems with the use of traditional dynamics in polymorphic languages. Type-based computation is also the basis for programmer-d...
Visualising Granularity in Parallel Programs: A Graphical Winnowing System for Haskell
- In HPFC'95 --- High Performance Functional Computing
, 1995
"... To take advantage of distributed-memory parallel machines it is essential to have good control of task granularity. This paper describes a fairly accurate parallel simulator for Haskell, based on the Glasgow compiler, and complementary tools for visualising task granularities. Together these tools a ..."
Abstract
-
Cited by 21 (9 self)
- Add to MetaCart
To take advantage of distributed-memory parallel machines it is essential to have good control of task granularity. This paper describes a fairly accurate parallel simulator for Haskell, based on the Glasgow compiler, and complementary tools for visualising task granularities. Together these tools allow us to study the effects of various annotations on task granularity on a variety of simulated parallel architectures. They also provide a more precise tool for the study of parallel execution than has previously been available for Haskell programs. These tools have already confirmed that thread migration is essential in parallel systems, demonstrated a close correlation between thread execution times and total heap allocations, and shown that fetching data synchronously normally gives better overall performance than asynchronous fetching, if data is fetched on demand. 1 Introduction Our aim is to produce fast, cost-effective implementations of lazy functional languages. One way to impro...

