Results 1  10
of
10
The essence of monotonic state
, 2009
"... We extend a static typeandcapability system with new mechanisms for expressing the promise that a certain abstract value evolves monotonically with time; for enforcing this promise; and for taking advantage of this promise to establish nontrivial properties of programs. These mechanisms are inde ..."
Abstract

Cited by 14 (4 self)
 Add to MetaCart
We extend a static typeandcapability system with new mechanisms for expressing the promise that a certain abstract value evolves monotonically with time; for enforcing this promise; and for taking advantage of this promise to establish nontrivial properties of programs. These mechanisms are independent of the treatment of mutable state, but combine with it to offer a flexible account of “monotonic state”. To demonstrate their use, we present a simple yet challenging example, namely monotonic integer counters. We then show how an implementation of thunks in terms of references can be assigned types that reflect time complexity properties, in the style of Danielsson (2008). This offers a foundational explanation of Danielsson’s system and, at the same time, extends it to a calculus with mutable state. Last, we sketch an application to hashconsing.
RealTime Deques, Multihead Turing Machines, and Purely Functional Programming
 In Conference on Functional Programming Languages and Computer Architecture
, 1993
"... We answer the following question: Can a deque (double ended queue) be implemented in a purely functional language such that each push or pop operation on either end of a queue is accomplished in O(1) time in the worst case? The answer is yes, thus solving a problem posted by Gajewska and Tarjan [1 ..."
Abstract

Cited by 12 (1 self)
 Add to MetaCart
We answer the following question: Can a deque (double ended queue) be implemented in a purely functional language such that each push or pop operation on either end of a queue is accomplished in O(1) time in the worst case? The answer is yes, thus solving a problem posted by Gajewska and Tarjan [14] and by Ponder, McGeer, and Ng [25], and refining results of Sarnak [26] and Hoogerwoord [18]. We term such a deque realtime, since its constant worstcase behavior might be useful in real time programs (assuming realtime garbage collection [3], etc.) Furthermore, we show that no restriction of the functional language is necessary, and that push and pop operations on previous versions of a deque can also be achieved in constant time. We present a purely functional implementation of real time deques and its complexity analysis. We then show that the implementation has some interesting implications, and can be used to give a realtime simulation of a multihead Turing machine in a purel...
Amortized Resource Analysis with Polynomial Potential A Static Inference of Polynomial Bounds for Functional Programs (Extended Version)
"... Abstract. In 2003, Hofmann and Jost introduced a type system that uses a potentialbased amortized analysis to infer bounds on the resource consumption of (firstorder) functional programs. This analysis has been successfully applied to many standard algorithms but is limited to bounds that are line ..."
Abstract

Cited by 11 (5 self)
 Add to MetaCart
Abstract. In 2003, Hofmann and Jost introduced a type system that uses a potentialbased amortized analysis to infer bounds on the resource consumption of (firstorder) functional programs. This analysis has been successfully applied to many standard algorithms but is limited to bounds that are linear in the size of the input. Here we extend this system to polynomial resource bounds. An automatic amortized analysis is used to infer these bounds for functional programs without further annotations if a maximal degree for the bounding polynomials is given. The analysis is generic in the resource and can obtain good bounds on heapspace, stackspace and time usage.
Fast Meldable Priority Queues
, 1995
"... We present priority queues that support the operations MakeQueue, FindMin, Insert and Meld in worst case time O(1) and Delete and DeleteMin in worst case time O(log n). They can be implemented on the pointer machine and require linear space. The time bounds are optimal for all implementations wh ..."
Abstract

Cited by 11 (2 self)
 Add to MetaCart
We present priority queues that support the operations MakeQueue, FindMin, Insert and Meld in worst case time O(1) and Delete and DeleteMin in worst case time O(log n). They can be implemented on the pointer machine and require linear space. The time bounds are optimal for all implementations where Meld takes worst case time o(n).
Fully Persistent Arrays for Efficient Incremental Updates and Voluminous Reads
 4th European Symposium on Programming
, 1992
"... The array update problem in a purely functional language is the following: once an array is updated, both the original array and the newly updated one must be preserved to maintain referential transparency. We devise a very simple, fully persistent data structure to tackle this problem such that ..."
Abstract

Cited by 5 (2 self)
 Add to MetaCart
The array update problem in a purely functional language is the following: once an array is updated, both the original array and the newly updated one must be preserved to maintain referential transparency. We devise a very simple, fully persistent data structure to tackle this problem such that ffl each incremental update costs O(1) worstcase time, ffl a voluminous sequence of r reads cost in total O(r) amortized time, and ffl the data structure use O(n + u) space, where n is the size of the array and u is the total number of updates. A sequence of r reads is voluminous if r is \Omega\Gamma n) and the sequence of arrays being read forms a path of length O(r) in the version tree. A voluminous sequence of reads may be mixed with updates without affecting either the performance of reads or updates. An immediate consequence of the above result is that if a functional program is singlethreaded, then the data structure provides a simple and efficient implementation of funct...
Amortized Constant Relaxed Rebalancing Using Standard Rotations
 Acta Informatica
, 1998
"... The idea of relaxed balance is to uncouple the rebalancing in search trees from the updating in order to speed up request processing in mainmemory databases during bursts of updates. This paper contains the first proof that amortized constant time rebalancing can be obtained in a relaxed binary sea ..."
Abstract

Cited by 4 (3 self)
 Add to MetaCart
The idea of relaxed balance is to uncouple the rebalancing in search trees from the updating in order to speed up request processing in mainmemory databases during bursts of updates. This paper contains the first proof that amortized constant time rebalancing can be obtained in a relaxed binary search tree using only standard single and double rotations. 1 Introduction The idea of relaxed balance is to uncouple the rebalancing in search trees from the updating in order to speed up request processing in mainmemory databases. The motivation is twofold: If search and update requests for a search tree come in bursts (possibly from several external sources), the search tree may occasionally not be able to process the requests as fast as it might be desirable. For this reason, it would be convenient to be able to "turn off" rebalancing for a short period of time in order to speed up the request processing. However, when the burst is over, the tree should be rebalanced again, while search...
Amortized Resource Analysis with Polymorphic Recursion and Partial BigStep Operational Semantics  Extended Version
"... This paper studies the problem of statically determining upper bounds on the resource consumption of firstorder functional programs. A previous work approached the problem with an automatic typebased amortized analysis for polynomial resource bounds. The analysis is parametric in the resource and ..."
Abstract

Cited by 4 (3 self)
 Add to MetaCart
This paper studies the problem of statically determining upper bounds on the resource consumption of firstorder functional programs. A previous work approached the problem with an automatic typebased amortized analysis for polynomial resource bounds. The analysis is parametric in the resource and can be instantiated to heap space, stack space, or clock cycles. Experiments with a prototype implementation have shown that programs are analyzed efficiently and that the computed bounds exactly match the measured worstcase resource behavior for many functions. This paper describes the inference algorithm that is used in the implementation of the system. It can deal with resourcepolymorphic recursion which is required in the type derivation of many functions. The computation of the bounds is fully automatic if a maximal degree of the polynomials is given. The soundness of the inference is proved with respect to a novel operational semantics for partial evaluations to show that the inferred bounds hold for terminating as well as nonterminating computations. A corollary is that runtime bounds also establish the termination of programs.
Relaxed MultiWay Trees with Group Updates
 In Proceedings of the twentieth ACM SIGMODSIGACTSIGART symposium on Principles of database systems
, 2000
"... Data structures with relaxed balance dier from standard structures in that rebalancing can be delayed and interspersed with updates. This gives extra exibility in both sequential and parallel applications. We study the version of multiway trees called (a; b)trees (which includes Btrees) with ..."
Abstract

Cited by 2 (0 self)
 Add to MetaCart
Data structures with relaxed balance dier from standard structures in that rebalancing can be delayed and interspersed with updates. This gives extra exibility in both sequential and parallel applications. We study the version of multiway trees called (a; b)trees (which includes Btrees) with the operations insertion, deletion, and group insertion. The latter has applications in for instance document databases and WWW search engines. We prove that we obtain the optimal asymptotic rebalancing complexities of amortized constant time for insertion and deletion and amortized logarithmic time in the size of the group for group insertion. These results hold even for the relaxed version. Our results also demonstrate that a binary tree scheme with the same complexities can be designed. This is an improvement over the existing results. 1 Introduction We focus on the type of multiway trees usually referred to as (a; b)trees [8, 15], and in particular, we adopt the relaxed (a...
On Space Bounded Server Algorithms
, 1993
"... This paper studies space bounded algorithms, i.e., algorithms that use a constant amount of scratch space, for the kserver problem. The paper first shows a characterization of the set of space bounded algorithms that are competitive in finite metric spaces. The result yields a method for (1) effec ..."
Abstract

Cited by 1 (0 self)
 Add to MetaCart
This paper studies space bounded algorithms, i.e., algorithms that use a constant amount of scratch space, for the kserver problem. The paper first shows a characterization of the set of space bounded algorithms that are competitive in finite metric spaces. The result yields a method for (1) effectively deciding if a given space bounded algorithm is competitive in a given finite metric space, and (2) for designing competitive space bounded algorithms in finite metric spaces. The above results are then refined, in particular using the geometry of metric spaces, to develop two methods for obtaining an upper bound on competitive factors of arbitrary space bounded algorithms. One of these methods is then used to show that any algorithm, employing the Least Recently Used strategy, is linearly competitive on a uniform metric space. 1 Introduction Online problems arise quite often, and quite naturally in computer science. The dynamic nature of these problems demands algorithms for these p...
Languages, Theory
"... We extend a static typeandcapability system with new mechanisms for expressing the promise that a certain abstract value evolves monotonically with time; for enforcing this promise; and for taking advantage of this promise to establish nontrivial properties of programs. These mechanisms are indep ..."
Abstract
 Add to MetaCart
We extend a static typeandcapability system with new mechanisms for expressing the promise that a certain abstract value evolves monotonically with time; for enforcing this promise; and for taking advantage of this promise to establish nontrivial properties of programs. These mechanisms are independent of the treatment of mutable state, but combine with it to offer a flexible account of “monotonic state”. We apply these mechanisms to solve two reasoning challenges that involve mutable state. First, we show how an implementation of thunks in terms of references can be assigned types that reflect time complexity properties, in the style of Danielsson (2008). Second, we show how an implementation of hashconsing can be assigned a specification that conceals the existence of an internal state yet guarantees that two pieces of input data receive the same code if and only if they are equal.