Results 1  10
of
89
Static Prediction of Heap Space Usage for Firstorder Functional Programs
 in Symposium on Principles of Programming Languages (POPL’03
, 2003
"... Categories and Subject Descriptors We show how to efficiently obtain linear a priori bounds on the heap space consumption of firstorder functional programs. The analysis takes space reuse by explicit deallocation into account and also furnishes an upper bound on the heap usage in the presence of ga ..."
Abstract

Cited by 167 (31 self)
 Add to MetaCart
(Show Context)
Categories and Subject Descriptors We show how to efficiently obtain linear a priori bounds on the heap space consumption of firstorder functional programs. The analysis takes space reuse by explicit deallocation into account and also furnishes an upper bound on the heap usage in the presence of garbage collection. It covers a wide variety of examples including, for instance, the familiar sorting algorithms for lists, including quicksort. The analysis relies on a type system with resource annotations. Linear programming (LP) is used to automatically infer derivations in this enriched type system. We also show that integral solutions to the linear programs derived correspond to programs that can be evaluated without any operating system support for memory management. The particular integer linear programs arising in this way are shown to be feasibly solvable under mild assumptions.
A Type System for Bounded Space and Functional inPlace Update
, 2000
"... We show how linear typing can be used to obtain functional programs which modify heapallocated data structures in place. We present this both as a "design pattern" for writing Ccode in a functional style and as a compilation process from linearly typed firstorder functional programs int ..."
Abstract

Cited by 99 (15 self)
 Add to MetaCart
(Show Context)
We show how linear typing can be used to obtain functional programs which modify heapallocated data structures in place. We present this both as a "design pattern" for writing Ccode in a functional style and as a compilation process from linearly typed firstorder functional programs into malloc()free C code. The main technical result is the correctness of this compilation. The crucial innovation over previous linear typing schemes consists of the introduction of a resource type # which controls the number of constructor symbols such as cons in recursive definitions and ensures linear space while restricting expressive power surprisingly little. While the space e#ciency brought about by the new typing scheme and the compilation into C can also be realised by with stateoftheart optimising compilers for functional languages such as Ocaml [16], the present method provides guaranteed bounds on heap space which will be of use for applications such as languages for embedd...
Hume: A DomainSpecific Language for RealTime Embedded Systems
 In Proc. Conf. Generative Programming and Component Engineering (GPCE ’03), Lecture Notes in Computer Science
, 2003
"... This paper describes Hume: a novel domainspecific language whose purpose is to explore the expressibility/costability spectrum in resourceconstrained systems, such as realtime embedded or control systems. ..."
Abstract

Cited by 83 (40 self)
 Add to MetaCart
(Show Context)
This paper describes Hume: a novel domainspecific language whose purpose is to explore the expressibility/costability spectrum in resourceconstrained systems, such as realtime embedded or control systems.
Speed: Precise and efficient static estimation of program computational complexity
 In POPL’09
, 2009
"... This paper describes an interprocedural technique for computing symbolic bounds on the number of statements a procedure executes in terms of its scalar inputs and userdefined quantitative functions of input datastructures. Such computational complexity bounds for even simple programs are usually ..."
Abstract

Cited by 69 (6 self)
 Add to MetaCart
(Show Context)
This paper describes an interprocedural technique for computing symbolic bounds on the number of statements a procedure executes in terms of its scalar inputs and userdefined quantitative functions of input datastructures. Such computational complexity bounds for even simple programs are usually disjunctive, nonlinear, and involve numerical properties of heaps. We address the challenges of generating these bounds using two novel ideas. We introduce a proof methodology based on multiple counter instrumentation (each counter can be initialized and incremented at potentially multiple program locations) that allows a given linear invariant generation tool to compute linear bounds individually on these counter variables. The bounds on these counters are then composed together to generate total bounds that are nonlinear and disjunctive. We also give an algorithm for automating this proof
Multivariate Amortized Resource Analysis
, 2010
"... We study the problem of automatically analyzing the worstcase resource usage of procedures with several arguments. Existing automatic analyses based on amortization, or sized types bound the resource usage or result size of such a procedure by a sum of unary functions of the sizes of the arguments. ..."
Abstract

Cited by 44 (5 self)
 Add to MetaCart
(Show Context)
We study the problem of automatically analyzing the worstcase resource usage of procedures with several arguments. Existing automatic analyses based on amortization, or sized types bound the resource usage or result size of such a procedure by a sum of unary functions of the sizes of the arguments. In this paper we generalize this to arbitrary multivariate polynomial functions thus allowing bounds of the form mn which had to be grossly overestimated by m 2 + n 2 before. Our framework even encompasses bounds like ∑ i,j≤n mimj where the mi are the sizes of the entries of a list of length n. This allows us for the first time to derive useful resource bounds for operations on matrices that are represented as lists of lists and to considerably improve bounds on other superlinear operations on lists such as longest common subsequence and removal of duplicates from lists of lists. Furthermore, resource bounds are now closed under composition which improves accuracy of the analysis of composed programs when some or all of the components exhibit superlinear resource or size behavior. The analysis is based on a novel multivariate amortized resource analysis. We present it in form of a type system for a simple firstorder functional language with lists and trees, prove soundness, and describe automatic type inference based on linear programming. We have experimentally validated the automatic analysis on a wide range of examples from functional programming with lists and trees. The obtained bounds were compared with actual resource consumption. All bounds were asymptotically tight, and the constants were close or even identical to the optimal ones.
A Direct Approach to ControlFlow Sensitive RegionBased Memory Management
, 2001
"... Regionbased memory management can be used to control dynamic memory allocations and deallocations safely and efficiently. Existing (directstyle) region systems that statically guarantee region safetyno dereferencing of dangling pointersare based on refinements of Tofte and Talpin's semi ..."
Abstract

Cited by 40 (1 self)
 Add to MetaCart
Regionbased memory management can be used to control dynamic memory allocations and deallocations safely and efficiently. Existing (directstyle) region systems that statically guarantee region safetyno dereferencing of dangling pointersare based on refinements of Tofte and Talpin's seminal work on region inference for managing heap memory in stacks of regions.
Termination Checking with Types
, 1999
"... The paradigm of typebased termination is explored for functional programming with recursive data types. The article introduces , a lambdacalculus with recursion, inductive types, subtyping and bounded quanti cation. Decorated type variables representing approximations of inductive types ..."
Abstract

Cited by 36 (6 self)
 Add to MetaCart
The paradigm of typebased termination is explored for functional programming with recursive data types. The article introduces , a lambdacalculus with recursion, inductive types, subtyping and bounded quanti cation. Decorated type variables representing approximations of inductive types are used to track the size of function arguments and return values. The system is shown to be type safe and strongly normalizing. The main novelty is a bidirectional type checking algorithm whose soundness is established formally.
RealTime FRP
 IN THE INTERNATIONAL CONFERENCE ON FUNCTIONAL PROGRAMMING (ICFP ’01
, 2001
"... Functional reactive programming (FRP) is a declarative programming paradigm where the basic notions are continuous, timevarying behaviors and discrete, eventbased reactivity. FRP has been used successfully in many reactive programming domains such as animation, robotics, and graphical user interfa ..."
Abstract

Cited by 36 (5 self)
 Add to MetaCart
Functional reactive programming (FRP) is a declarative programming paradigm where the basic notions are continuous, timevarying behaviors and discrete, eventbased reactivity. FRP has been used successfully in many reactive programming domains such as animation, robotics, and graphical user interfaces. The success of FRP in these domains encourages us to consider its use in realtime applications, where it is crucial that the cost of running a program be bounded and known before runtime. But previous work on the semantics and implementation of FRP was not explicitly concerned about the issues of cost. In fact, the resource consumption of FRP programs in the current implementation is often hard to predict. As a first step
Using Ambients to Control Resources
, 2002
"... Current software and hardware systems, being parallel and recon gurable, raise new safety and reliability problems, and the resolution of these problems requires new methods. Numerous proposals attempt at reducing the threat of bugs and preventing several kinds of attacks. In this paper, we dev ..."
Abstract

Cited by 36 (9 self)
 Add to MetaCart
Current software and hardware systems, being parallel and recon gurable, raise new safety and reliability problems, and the resolution of these problems requires new methods. Numerous proposals attempt at reducing the threat of bugs and preventing several kinds of attacks. In this paper, we develop an extension of the calculus of Mobile Ambients, named Controlled Ambients, that is suited for expressing such issues, speci cally Denial of Service attacks. We present a type system for Controlled Ambients, which makes resource control possible in our setting.
Memory Usage Verification for OO Programs
 In SAS 05
, 2005
"... Abstract. We present a new type system for an objectoriented (OO) language that characterizes the sizes of data structures and the amount of heap memory required to successfully execute methods that operate on these data structures. Key components of this type system include type assertions that us ..."
Abstract

Cited by 33 (3 self)
 Add to MetaCart
(Show Context)
Abstract. We present a new type system for an objectoriented (OO) language that characterizes the sizes of data structures and the amount of heap memory required to successfully execute methods that operate on these data structures. Key components of this type system include type assertions that use symbolic Presburger arithmetic expressions to capture data structure sizes, the effect of methods on the data structures that they manipulate, and the amount of memory that methods allocate and deallocate. For each method, we conservatively capture the amount of memory required to execute the method as a function of the sizes of the method’s inputs. The safety guarantee is that the method will never attempt to use more memory than its type expressions specify. We have implemented a type checker to verify memory usages of OO programs. Our experience is that the type system can precisely and effectively capture memory bounds for a wide range of programs. 1