scispace - formally typeset
Search or ask a question

Showing papers on "Heap (data structure) published in 2003"


Proceedings ArticleDOI
15 Jan 2003
TL;DR: It is shown how to efficiently obtain linear a priori bounds on the heap space consumption of first-order functional programs and that integral solutions to the linear programs derived correspond to programs that can be evaluated without any operating system support for memory management.
Abstract: We show how to efficiently obtain linear a priori bounds on the heap space consumption of first-order 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.

338 citations


Proceedings ArticleDOI
20 Oct 2003
TL;DR: Transparent runtime randomization (TRR) as mentioned in this paper dynamically and randomly relocates a program's stack, heap, shared libraries, and parts of its runtime control data structures inside the application memory address space.
Abstract: A large class of security attacks exploit software implementation vulnerabilities such as unchecked buffers. This paper proposes transparent runtime randomization (TRR), a generalized approach for protecting against a wide range of security attacks. TRR dynamically and randomly relocates a program's stack, heap, shared libraries, and parts of its runtime control data structures inside the application memory address space. Making a program's memory layout different each time it runs foils the attacker's assumptions about the memory layout of the vulnerable program and makes the determination of critical address values difficult if not impossible. TRR is implemented by changing the Linux dynamic program loader, hence it is transparent to applications. We demonstrate that TRR is effective in defeating real security attacks, including malloc-based heap overflow, integer overflow, and double-free attacks, for which effective prevention mechanisms are yet to emerge. Furthermore, TRR incurs less than 9% program startup overhead and no runtime overhead.

277 citations


Journal ArticleDOI
01 Jan 2003
TL;DR: Non-layered approaches to the design and implementation of network protocols are investigated for greater flexibility and control with fewer feature interaction problems and a specific non-layering paradigm called role-based architecture is proposed.
Abstract: Questioning whether layering is still an adequate foundation for networking architectures, this paper investigates non-layered approaches to the design and implementation of network protocols. The goals are greater flexibility and control with fewer feature interaction problems. The paper further proposes a specific non-layered paradigm called role-based architecture.

262 citations


Journal ArticleDOI
09 May 2003
TL;DR: The experience indicates that the type system presented is sufficiently expressive and requires little programming overhead, and that eliminating the RTSJ runtime checks using a static type system can significantly decrease the execution time of real-time programs.
Abstract: The Real Time Specification for Java (RTSJ) allows a program to create real-time threads with hard real-time constraints. Real-time threads use region-based memory management to avoid unbounded pauses caused by interference from the garbage collector. The RTSJ uses runtime checks to ensure that deleting a region does not create dangling references and that real-time threads do not access references to objects allocated in the garbage-collected heap. This paper presents a static type system that guarantees that these runtime checks will never fail for well-typed programs. Our type system therefore 1) provides an important safety guarantee for real-time programs and 2) makes it possible to eliminate the runtime checks and their associated overhead.Our system also makes several contributions over previous work on region types. For object-oriented programs, it combines the benefits of region types and ownership types in a unified type system framework. For multithreaded programs, it allows long-lived threads to share objects without using the heap and without memory leaks. For real-time programs, it ensures that real-time threads do not interfere with the garbage collector. Our experience indicates that our type system is sufficiently expressive and requires little programming overhead, and that eliminating the RTSJ runtime checks using a static type system can significantly decrease the execution time of real-time programs.

184 citations


Journal ArticleDOI
TL;DR: A new regime for granular flows in an inclined channel with a flow-rate-controlled system is observed, where the flow occurs atop a static granular heap whose angle is considerably higher than those usually exhibited by granular heaps.
Abstract: We observed experimentally a new regime for granular flows in an inclined channel with a flow-rate-controlled system. For high flow rates, the flow occurs atop a static granular heap whose angle is considerably higher than those usually exhibited by granular heaps. The properties of such superstable heaps (SSH) are drastically affected by a change in the channel width W. This indicates that the unusual stability of these heaps can be accounted for by the flowing layer and its friction on the sidewalls. A simple depth-averaged model, assuming Coulomb friction, shows that the SSH angle scales as h/W (W being the channel width), and that grain size plays no part.

168 citations


Patent
18 Jun 2003
TL;DR: In this paper, a technique for reducing the number of write barriers executed in mutator code without compromising garbage collector performance is presented, where a compiler generates two forms of mutator codes, one with write barriers and a second without write barriers.
Abstract: A technique is provided for reducing the number of write barriers executed in mutator code without compromising garbage collector performance. Advantageously, a compiler generates two forms of a mutator code—a first version with write barriers and a second version substantially without write barriers. In operation, the first version of the code may be accessed by a vtable in a “mature” near-class and the second version may be accessed by a vtable in a “nascent” near-class. According to the invention, mapping of functionally equivalent points in the first and second versions of the mutator code may be facilitated by an associated pcmap. Further, each of the first and second versions may also be associated with a respective nr_map that facilitates mapping functionally equivalent points within different branches of guard code sequences corresponding to reference-writes to non-receiver objects.

155 citations


Journal ArticleDOI
09 May 2003
TL;DR: Initial experience shows that OUGs are effective to identify object accesses that potentially conflict at runtime and isolateAccesses that never cause a problem at runtime, and runtime instrumentation that checks for object races is sparse.
Abstract: A compiler for multi-threaded object-oriented programs needs information about the sharing of objects for a variety of reasons: to implement optimizations, to issue warnings, to add instrumentation to detect access violations that occur at runtime. An Object Use Graph (OUG) statically captures accesses from different threads to objects. An OUG extends the Heap Shape Graph (HSG), which is a compile-time abstraction for runtime objects (nodes) and their reference relations (edges). An OUG specifies for a specific node in the HSG a partial order of events relevant to the corresponding runtime object(s). Relevant events include read and write access, object escape, thread start and join.OUGs have been implemented in a Java compiler. Initial experience shows that OUGs are effective to identify object accesses that potentially conflict at runtime and isolate accesses that never cause a problem at runtime. The capabilities of OUGs are compared with an advanced program analysis that has been used for lock elimination. For the set of benchmarks investigated here, OUGs report only a fraction of shared objects as conflicting and reduce the number of compile-time reports in terms of allocation sites of conflicting objects by 28--92% (average 64%). For benchmarks of up to 30 KLOC, the time taken to construct OUGs is, with one exception, in the order of seconds.The information collected in the OUG has been used to instrument Java programs with checks for object races. OUGs provide precise information about object sharing and static protection, so runtime instrumentation that checks those cases that cannot be disambiguated at compile-time is sparse, and the total runtime overhead of checking for object races is only 3--86% (average 47%).

147 citations


Patent
10 Jan 2003
TL;DR: In this paper, a heap memory management method that not only improves processing performance of an application program but also reduces a program development cost and a computer system using the same method is provided.
Abstract: There are provided a heap memory management method that not only improves processing performance of an application program but also reduces a program development cost and a computer system using the same method. A live object copy process in minor collection of generational garbage collection is implemented through a calculate process of object live ratio, a compare process of object live ratio, and a live object copy process. The calculate process of object live ratio calculates a ratio of a size of a memory allocated to live objects of new objects to a size of a memory allocated to a new object during minor collection. The compare process of object live ratio compares a calculated object live ratio with a predetermined threshold. The live object copy process copies a live object directly to an old-generation heap instead of a new-generation heap when the object live ratio exceeds the threshold as a result of comparison. Further, an application programmer provides means for setting the threshold that decides a copy destination of the live object as a runtime parameter of a program and means for holding the set threshold in a memory.

129 citations


Proceedings Article
31 Oct 2003
TL;DR: This paper presents a technique that protects the heap management information and allows for run-time detection of heap-based overflows, and proposes a detection scheme that has been implemented as a patch to the GNU Lib C.
Abstract: Buffer overflows belong to the most common class of attacks on today's Internet. Although stack-based variants are still by far more frequent and well-understood, heap-based overflows have recently gained more attention. Several real-world exploits have been published that corrupt heap management information and allow arbitrary code execution with the privileges of the victim process.This paper presents a technique that protects the heap management information and allows for run-time detection of heap-based overflows. We discuss the structure of these attacks and our proposed detection scheme that has been implemented as a patch to the GNU Lib C. We report the results of our experiments, which demonstrate the detection effectiveness and performance impact of our approach. In addition, we discuss different mechanisms to deploy the memory protection.

101 citations


Proceedings ArticleDOI
26 Oct 2003
TL;DR: This paper introduces a new hybrid collector that combines copying generational collection for the young objects and reference counting the old objects to achieve both goals, and restricts copying and reference count to the object demographics for which they perform well.
Abstract: General purpose garbage collectors have yet to combine short pause times with high throughput. For example, generational collectors can achieve high throughput. They have modest average pause times, but occasionally collect the whole heap and consequently incur long pauses. At the other extreme, concurrent collectors, including reference counting, attain short pause times but with significant performance penalties. This paper introduces a new hybrid collector that combines copying generational collection for the young objects and reference counting the old objects to achieve both goals. It restricts copying and reference counting to the object demographics for which they perform well. Key to our algorithm is a generalization of deferred reference counting we call Ulterior Reference Counting. Ulterior reference counting safely ignores mutations to select heap objects. We compare a generational reference counting hybrid with pure reference counting, pure mark-sweep, and hybrid generational mark-sweep collectors. This new collector combines excellent throughput, matching a high performance generational mark-sweep hybrid, with low maximum pause times.

97 citations


Journal ArticleDOI
11 Jun 2003
TL;DR: This paper presents a more detailed analysis of fragmentation than in previous work, and shows how the collector is able to bound fragmentation to acceptable limits, and bound both the time for collection and consequently the space overhead required much more tightly.
Abstract: Now that the use of garbage collection in languages like Java is becoming widely accepted due to the safety and software engineering benefits it provides, there is significant interest in applying garbage collection to hard real-time systems Past approaches have generally suffered from one of two major flaws: either they were not provably real-time, or they imposed large space overheads to meet the real-time boundsOur previous work [3] presented the Metronome, a mostly non-copying real-time collector The Metronome achieves worst-case pause times of 6 milliseconds while maintaining consistent mutator CPU utilization rates of 50% with only 15-21 times the maximum heap space required by the application, which is comparable with space requirements for stop-the-world collectorsHowever, that algorithm assumed a constant collection rate, ignored program-dependent characteristics, and lacked a precise specification for when to trigger collection or how much defragmentation to perform This paper refines the model by taking into account program properties such as pointer density, average object size, and locality of object size This allows us to bound both the time for collection and consequently the space overhead required much more tightly We show experimentally that most parameters usually are not subject to large variation, indicating that a small number of parameters will be sufficient to predict the time and space requirements accuratelyOur previous work also did not present the details of our approach to avoiding and undoing fragmentation In this paper we present a more detailed analysis of fragmentation than in previous work, and show how our collector is able to bound fragmentation to acceptable limits

Proceedings ArticleDOI
26 Oct 2003
TL;DR: A new garbage collector, referred to as the Mark-Compact-Compress (MCC) collector, that allows an application to run with a heap smaller than its footprint, and a set of memory management strategies to reduce heap footprint of embedded Java applications that execute under severe memory constraints.
Abstract: Java is becoming the main software platform for consumer and embedded devices such as mobile phones, PDAs, TV set-top boxes, and in-vehicle systems. Since many of these systems are memory constrained, it is extremely important to keep the memory footprint of Java applications under control.The goal of this work is to enable the execution of Java applications using a smaller heap footprint than that possible using current embedded JVMs. We propose a set of memory management strategies to reduce heap footprint of embedded Java applications that execute under severe memory constraints. Our first contribution is a new garbage collector, referred to as the Mark-Compact-Compress (MCC) collector, that allows an application to run with a heap smaller than its footprint. An important characteristic of this collector is that it compresses objects when heap compaction is not sufficient for creating space for the current allocation request. In addition to employing compression, we also consider a heap management strategy and associated garbage collector, called MCL (Mark-Compact-Lazy Allocate), based on lazy allocation of object portions. This new collector operates like the conventional Mark-Compact (MC) collector, but takes advantage of the observation that many Java applications create large objects, of which only a small portion is actually used. In addition, we also combine MCC and MCL, and present MCCL (Mark-Compact-Compress-Lazy Al-locate), which outperforms both MCC and MCL.We have implemented these collectors using KVM, and performed extensive experiments using a set of ten embedded Java applications. We have found our new garbage collection strategies to be useful in two main aspects. First, they reduce the minimum heap size necessary to execute an application without out-of-memory exception. Second, our strategies reduce the heap occupancy. That is, at a given time, they reduce the heap memory requirement of the application being executed. We have also conducted experiments with a more aggressive object compression strategy and discussed its main advantages.

Proceedings ArticleDOI
26 Oct 2003
TL;DR: A mark-copy collection algorithm (MC) that extends generational copying collection and significantly reduces the heap space required to run a program and is significantly faster than mark-sweep in small and moderate size heaps is presented.
Abstract: Copying garbage collectors have a number of advantages over non-copying collectors, including cheap allocation and avoiding fragmentation. However, in order to provide completeness (the guarantee to reclaim each garbage object eventually), standard copying collectors require space equal to twice the size of the maximum live data for a program. We present a mark-copy collection algorithm (MC) that extends generational copying collection and significantly reduces the heap space required to run a program. MC reduces space overhead by 75--85% compared with standard copying garbage collectors, increasing the range of applications that can use copying garbage collection. We show that when MC is given the same amount of space as a generational copying collector, it improves total execution time of Java benchmarks significantly in tight heaps, and by 5--10% in moderate size heaps. We also compare the performance of MC with a (non-generational) mark-sweep collector and a hybrid copying/mark-sweep generational collector. We find that MC can run in heaps comparable in size to the minimum heap space required by mark-sweep. We also find that for most benchmarks MC is significantly faster than mark-sweep in small and moderate size heaps. When compared with the hybrid collector, MC improves total execution time by about 5% for some benchmarks, partly by increasing the speed of execution of the application code.

Proceedings ArticleDOI
11 Jun 2003
TL;DR: In this paper, the authors present a framework for statically reasoning about temporal heap safety properties, in which the verification process may be performed for a program object independently of other program objects.
Abstract: We present a framework for statically reasoning about temporal heap safety properties. We focus on local temporal heap safety properties, in which the verification process may be performed for a program object independently of other program objects. We apply our framework to produce new conservative static algorithms for compile-time memory management, which prove for certain program points that a memory object or a heap reference will not be needed further. These algorithms can be used for reducing space consumption of Java programs. We have implemented a prototype of our framework, and used it to verify compile-time memory management properties for several small, but interesting example programs, including JavaCard programs.

Proceedings ArticleDOI
26 Oct 2003
TL;DR: Object Equality Profiling is presented, a new technique for helping programmers discover optimization opportunities in programs that discovers opportunities for replacing a set of equivalent object instances with a single representative object.
Abstract: We present Object Equality Profiling (OEP), a new technique for helping programmers discover optimization opportunities in programs. OEP discovers opportunities for replacing a set of equivalent object instances with a single representative object. Such a set represents an opportunity for automatically or manually applying optimizations such as hash consing, heap compression, lazy allocation, object caching, invariant hoisting, and more. To evaluate OEP, we implemented a tool to help programmers reduce the memory usage of Java programs. Our tool performs a dynamic analysis that records all the objects created during a particular program run. The tool partitions the objects into equivalence classes, and uses collected timing information to determine when elements of an equivalence class could have been safely collapsed into a single representative object without affecting the behavior of that program run. We report the results of applying this tool to benchmarks, including two widely used Web application servers. Many benchmarks exhibit significant amounts of object equivalence, and in most benchmarks our profiler identifies optimization opportunities clustered around a small number of allocation sites. We present a case study of using our profiler to find simple manual optimizations that reduce the average space used by live objects in two SpecJVM benchmarks by 47% and 38% respectively.

Book
01 Jan 2003
TL;DR: In this article, the authors introduce a mathematical model and language for the formulation of assertions about objects and pointers, and suggest that a graphical calculus may help in reasoning about program correctness, which is based on a trace model of graphs using ideas from process algebra.
Abstract: Object-oriented programs [5, 6, 10] are notoriously prone to the following kinds of error, which could lead to increasingly severe problems in the presence of tasking: 1. Following a null pointer; 2. Deletion of an accessible object; 3. Failure to delete an inaccessible object; 4. Interference due to equality of pointers; and 5. Inhibition of optimisation due to fear of (4). Type disciplines and object classes are a great help in avoiding these errors. Stronger protection may be obtainable with the help of assertions, particularly invariants, which are intended to be true before and after each call of a method that updates the structure of the heap. This note introduces a mathematical model and language for the formulation of assertions about objects and pointers, and suggests that a graphical calculus [4] may help in reasoning about program correctness. It deals with both garbage-collected heaps and the other kind. The theory is based on a trace model of graphs, using ideas from process algebra; and our development seeks to exploit this analogy as a unifying principle.

Book ChapterDOI
07 Apr 2003
TL;DR: This paper presents a framework for the verification of Java-like programs that make extensive use of the heap to allocate-and deallocate-new objects and threads and presents an abstract-interpretation algorithm that automatically verifies temporal properties expressed using the logic.
Abstract: This paper addresses the problem of establishing temporal properties of programs written in languages, such as Java, that make extensive use of the heap to allocate-and deallocate-new objects and threads. Establishing liveness properties is a particularly hard challenge. One of the crucial obstacles is that heap locations have no static names and the number of heap locations is unbounded. The paper presents a framework for the verification of Java-like programs. Unlike classical model checking, which uses propositional temporal logic, we use first-order temporal logic to specify temporal properties of heap evolutions; this logic allows domain changes to be expressed, which permits allocation and deallocation to be modelled naturally. The paper also presents an abstract-interpretation algorithm that automatically verifies temporal properties expressed using the logic.

01 Jul 2003
TL;DR: In this article, the authors define the class of heap monotonic typestates, which enable sound checking algorithms without the need for non-aliasing regimes of pointers, and prove that a data structure can evolve over time in a manner that only makes their representation invariants grow stronger, never weaker.
Abstract: The paper defines the class of heap monotonic typestates. The monotonicity of such typestates enables sound checking algorithms without the need for non-aliasing regimes of pointers. The basic idea is that data structures evolve over time in a manner that only makes their representation invariants grow stronger, never weaker. This assumption guarantees that existing object references with particular typestates remain valid in all program futures, while still allowing objects to attain new stronger typestates. The system is powerful enough to establish properties of circular data structures.

Book ChapterDOI
07 Apr 2003
TL;DR: This paper shows how a suite of optimizations based on a special treatment of relations that are known to be functional, and target all steps results in much improved scalability.
Abstract: A method for finding bugs in object-oriented code is presented. It is capable of checking complex user-defined structural properties - that is, of the configuration of objects on the heap - and generates counterexample traces with no false alarms. It requires no annotation beyond the specification to be checked, and is fully automatic. The method relies on a three-step translation: from code to a formula in a first-order relational logic, then to a propositional formula, and finally to conjunctive normal form. An off-the-shelf SAT solver is then used to find a solution that constitutes a counter example. This underlying scheme, presented previously, does not scale readily. In this paper, we show how a suite of optimizations results in much improved scalability. The optimizations are based on a special treatment of relations that are known to be functional, and target all steps. The effect of the optimizations is demonstrated by application to the analysis of a red-black tree implementation.

Proceedings ArticleDOI
13 Nov 2003
TL;DR: A program that is amenable to a buffer overflow attack and several Linux programs are used as examples to demonstrate the effectiveness and overhead of the repositioning of stack allocated arrays at compile time using TXL.
Abstract: Buffer overflows are the most common source of securityvulnerabilities in C programs. This class of vulnerability,which is found in both legacy and modern software, coststhe software industry hundreds of millions of dollars peryear.The most common type of buffer overflow is the run-timestack overflow. It is common because programmersoften use stack allocated arrays. This enables the attackerto change a program's control flow by writing beyond theboundary of an array onto a return address on the run-timestack. If the arrays are repositioned to the heap at compiletime, none of these attacks succeed. Furthermore, repositioningbuffers to the heap should perturb the heap memoryenough to prevent many heap overflows as well.We have created a tool called Gemini that repositionsstack allocated arrays at compile time using TXL. Thetransformation preserves the semantics of the program witha small performance penalty. This paper discusses thesemantics-preserving transformation of stack allocated arraysto heap allocated "pointers to arrays". A program thatis amenable to a buffer overflow attack and several Linuxprograms are used as examples to demonstrate the effectivenessand overhead of our technique.

Journal ArticleDOI
TL;DR: A flexible framework for combined heap and thread symmetry reductions in explicit-state model checking that can be tuned to trade run-time overhead for precision and applied to any non-deterministic heap object diagram is defined.

Proceedings ArticleDOI
15 Jan 2003
TL;DR: It is shown that a language based on ordered types can use the property of adjacency to give an exact account of the layout of data in memory.
Abstract: Ordered type theory is an extension of linear type theory in which variables in the context may be neither dropped nor re-ordered. This restriction gives rise to a natural notion of adjacency. We show that a language based on ordered types can use this property to give an exact account of the layout of data in memory. The fuse constructor from ordered logic describes adjacency of values in memory, and the mobility modal describes pointers into the heap. We choose a particular allocation model based on a common implementation scheme for copying garbage collection and show how this permits us to separate out the allocation and initialization of memory locations in such a way as to account for optimizations such as the coalescing of multiple calls to the allocator.

Journal ArticleDOI
11 Jun 2003
TL;DR: A set of techniques for reducing the memory consumption of object-oriented programs that include analysis algorithms and optimizations that use the results of these analyses to eliminate fields with constant values, reduce the sizes of fields based on the range of values that can appear in each field, and eliminates fields with common default values or usage patterns.
Abstract: We present a set of techniques for reducing the memory consumption of object-oriented programs. These techniques include analysis algorithms and optimizations that use the results of these analyses to eliminate fields with constant values, reduce the sizes of fields based on the range of values that can appear in each field, and eliminate fields with common default values or usage patterns. We apply these optimizations both to fields declared by the programmer and to implicit fields in the runtime object header. Although it is possible to apply these techniques to any object-oriented program, we expect they will be particularly appropriate for memory-limited embedded systems.We have implemented these techniques in the MIT FLEX compiler system and applied them to the programs in the SPECjvm98 benchmark suite. Our experimental results show that our combined techniques can reduce the maximum live heap size required for the programs in our benchmark suite by as much as 40%. Some of the optimizations reduce the overall execution time; others may impose modest performance penalties.

Posted Content
TL;DR: This article shows how three-valued structures that arise in shape analysis can be characterized using formulas in first-order logic with transitive closure, and defines a nonstandard (“supervaluational”) semantics for three- valued first- order logic that is more precise than a conventional three- valuation semantics.
Abstract: Shape analysis concerns the problem of determining "shape invariants" for programs that perform destructive updating on dynamically allocated storage. In recent work, we have shown how shape analysis can be performed, using an abstract interpretation based on 3-valued first-order logic. In that work, concrete stores are finite 2-valued logical structures, and the sets of stores that can possibly arise during execution are represented (conservatively) using a certain family of finite 3-valued logical structures. In this paper, we show how 3-valued structures that arise in shape analysis can be characterized using formulas in first-order logic with transitive closure. We also define a non-standard ("supervaluational") semantics for 3-valued first-order logic that is more precise than a conventional 3-valued semantics, and demonstrate that the supervaluational semantics can be effectively implemented using existing theorem provers.

Patent
15 May 2003
TL;DR: In this paper, the authors describe methods, systems, and media for managing dynamic memory in the context of a heap pool, where the goal is to allocate dynamic storage from the heap pool to tasks received that are associated with one of the identified nodes.
Abstract: Methods, systems, and media for managing dynamic memory are disclosed. Embodiments may disclose identifying nodes with having memory for dynamic storage, and reserving a portion of the memory from the identified nodes for a heap pool. After generating a heap pool, embodiments may allocate dynamic storage from the heap pool to tasks received that are associated with one of the identified nodes. More specifically, embodiments identify the node or home node associated with the task, the amount of dynamic storage requested by the task, and create a heap object in the node associated with the task to provide the requested dynamic storage. Some embodiments involve de-allocating the dynamic storage assigned to the task upon receipt of an indication that the task is complete and the dynamic storage is no longer needed for the task. Several of such embodiments return the de-allocated dynamic storage to the heap pool for reuse.

Journal ArticleDOI
TL;DR: 3-bit reference counting can eliminate the need to invoke the garbage collector in all tested applications and reduces the amount of memory usage by 77 percent, and the hardware cost of the proposed design is very modest.
Abstract: Java possesses many advantages for embedded system development, including fast product deployment, portability, security, and a small memory footprint. As Java makes inroads into the market for embedded systems, much effort is being invested in designing real-time garbage collectors. The proposed garbage-collected memory module, a bitmap-based processor with standard DRAM cells is introduced to improve the performance and predictability of dynamic memory management functions that include allocation, reference counting, and garbage collection. As a result, memory allocation can be done in constant time and sweeping can be performed in parallel by multiple modules. Thus, constant time sweeping is also achieved regardless of heap size. This is a major departure from the software counterparts where sweeping time depends largely on the size of the heap. In addition, the proposed design also supports limited-field reference counting, which has the advantage of distributing the processing cost throughout the execution. However, this cost can be quite large and results in higher power consumption due to frequent memory accesses and the complexity of the main processor. By doing reference counting operation in a coprocessor, the processing is done outside of the main processor. Moreover, the hardware cost of the proposed design is very modest (about 8000 gates). Our study has shown that 3-bit reference counting can eliminate the need to invoke the garbage collector in all tested applications. Moreover, it also reduces the amount of memory usage by 77 percent.

Journal ArticleDOI
TL;DR: It is shown how to efficiently obtain linear a priori bounds on the heap space consumption of first-order functional programs by taking space reuse by explicit deallocation into account.
Abstract: We show how to efficiently obtain linear a priori bounds on the heap space consumption of first-order functional programs.The analysis takes space reuse by explicit deallocation into account and al...

Journal Article
TL;DR: This paper describes a general approach for optimized live heap space andLive heap space-bound analyses for garbage-collected languages based on program analysis and transformations and is fully automatic.
Abstract: This paper describes a general approach for optimized live heap space and live heap space-bound analyses for garbage-collected languages. The approach is based on program analysis and transformations and is fully automatic. In our experience, the space-bound analysis generally produces accurate (tight) upper bounds in the presence of partially known input structures. The optimization drastically improves the analysis efficiency. The analyses have been implemented and experimental results confirm their accuracy and efficiency.

Book ChapterDOI
30 Jul 2003
TL;DR: An open issue on dictionaries dating back to the sixthies is closed, showing that bounds can be simultaneously achieved in the worst case for searching and updating by suitably maintaining a permutation of the n keys in the array.
Abstract: We close an open issue on dictionaries dating back to the sixthies. An array of n keys can be sorted so that searching takes O(log n) time. Alternatively, it can be organized as a heap so that inserting and deleting keys take O(log n) time. We show that these bounds can be simultaneously achieved in the worst case for searching and updating by suitably maintaining a permutation of the n keys in the array. The resulting data structure is called implicit as it uses just O(1) extra memory cells beside the n cells for the array. The data structure is also cache-oblivious, attaining O(logB n) block transfers in the worst case for any (unknown) value of the block size B, without wasting any single cell of memory at any level of the memory hierarchy.

Proceedings ArticleDOI
11 Jun 2003
TL;DR: A heap analysis algorithm that characterizes how programs access regions within recursive data structures, such as sublists within lists or subtrees within trees, and expresses heap access information using labels on the nodes of the shape graphs, making the analysis more efficient.
Abstract: This paper presents a heap analysis algorithm that characterizes how programs access regions within recursive data structures, such as sublists within lists or subtrees within trees. The analysis precisely computes cyclicity, reachability, and heap access region information for programs with destructive updates.The algorithm uses a shape graph abstraction of the heap that identifies connected, single-entry heap regions, whose entries are directly accessible from the stack. The edges of the shape graphs encode reachability information. This yields a more compact heap representation compared to the existing abstractions, making the analysis more efficient. Furthermore, the algorithm expresses heap access information using labels on the nodes of the shape graphs. The labels characterize the concrete locations that abstract nodes represent and make it possible to compare the sets of concrete locations modeled by nodes in different shape graphs. The labels allow the analysis to express the heap access information with respect to the nodes at a particular program point, for instance at the beginning of the current procedure. Our analysis is able to precisely and efficiently compute heap access region information for complex heap manipulations such as a recursive quicksort program that sorts a list in-place, using destructive updates.