Abstract

Java is popular. However, when using Java's garbage collection (GC) functions, the space-time performance of Java programs could suffer. Memory space can be traded for time performance or vice versa, but this might not always work because of the proliferation of new system and device types nowadays. Despite the increasing speed of processing hardware, the performance of garbage-collected systems is still a problem. GC cannot be separated from the rest of the memory management system. In this research, we introduce a new memory management system, called STEMA, which provides better cache locality and reduced memory fragmentation to improve the total execution time and space requirement of Java programs. STEMA focuses on frequently instantiated types, called prolific types, for object allocation and co-location decisions. STEMA identifies prolific types on-the-fly with a low overhead online type sampling mechanism so that the results can be used immediately to improve the performance of memory management functions. STEMA co-locates objects of prolific types in a special reusable memory space to improve the cache locality of Java programs. The idea of co-location is based on the observation that objects of the same type are more likely to be accessed together during program execution. STEMA uses the past to predict the future—it monitors the memory blocks allocated to each prolific type and retains a suitable amount of returned memory blocks for efficient future allocation of objects of the type. Reusing of previously used but retained blocks reduces the cost of allocation. We evaluate STEMA with 15 benchmarks. Experimental results show that STEMA performs better than the mark-sweep collector, the copying mark-sweep hybrid collector and the semispace collector (included in the MMTk of the Jikes RVM) on average over all heap ranges. STEMA also achieves a better space-time performance than the generational collector in cases where the heap is relatively small. The performance of garbage-collected systems by and large is application dependent. Thus, we also propose an offline profiling framework that can be used to effectively expose the behavior and properties of Java programs. Using the framework, we have identified 10 properties of prolific type objects. STEMA is designed based on these properties. We have also discovered some object properties which are useful for other memory management optimizations.

Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call