Browse Prior Art Database

An approach to identify and mark cold objects in Java

IP.com Disclosure Number: IPCOM000250627D
Publication Date: 2017-Aug-10
Document File: 2 page(s) / 8K

Publishing Venue

The IP.com Prior Art Database

This text was extracted from a Microsoft Word document.
This is the abbreviated version, containing approximately 52% of the total text.

An approach to identify and mark cold objects in Java

Abstract

Disclosed is a method to identify objects in Java* that are persistently marked but infrequently referenced. The method identifies these objects at runtime, and then consolidates the objects within a contiguous region of memory. Then, the objects can be paged out of main system memory onto a backing store.

Long-running Java* applications may preload and retain in the Java heap large numbers of objects that are persistently marked but infrequently referenced. The novel method described herein identifies these objects at runtime, and then consolidates the objects within a contiguous region of memory. Then, the objects can be paged out of main system memory onto a backing store.

The novel method harnesses Java mutator threads to periodically walk the associated stacks to collect references to heap objects and mark references to objects within instrumented regions of the Java heap as active, creating bit maps of each region. After period, the set of cold objects within the region is identified by subtracting the collection of active objects from the collection of live objects. These cold objects are then moved to a designated area within the heap (the cold area), which is identified to the operating system as containing infrequently used data and which is suitable for paging out to a backing store, thereby freeing system memory for occupation by more active objects.

This novel method is applicable to region-based heap management systems, in which the heap is partitioned into a large number of regions. Each mutator thread is required to periodically and frequently walk its own stack and report heap references found on each stack walk. A daemon thread collects these sampled references and maintains a record for each heap region of the number of references sampled since the last garbage collection cycle (the region activity count). Regions with high density and high activity counts are selected for instrumentation, which involves excluding those regions from partial garbage collection cycles (region pinning) and providing a 0-filled bit map to record active object references (activity map). The daemon thread updates the...