United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6921087 G1: remove per-GC-thread expansion tables from the fine-grain remembered sets
JDK-6921087 : G1: remove per-GC-thread expansion tables from the fine-grain remembered sets

Details
Type:
Enhancement
Submit Date:
2010-01-28
Status:
Resolved
Updated Date:
2013-06-26
Project Name:
JDK
Resolved Date:
2012-07-03
Component:
hotspot
OS:
generic
Sub-Component:
gc
CPU:
generic
Priority:
P5
Resolution:
Fixed
Affected Versions:
hs17
Fixed Versions:
hs24 (b15)

Related Reports
Backport:
Backport:
Backport:
Backport:

Sub Tasks

Description
In G1, the remembered set (RSet) of a heap region (say R) has three types: sparse, fine, and coarse. Fine-entries are organized in a hash table, with each entry (say E) corresponding to a region that potentially has references into R.

During GC pauses, if an entry E corresponds to a region that's a GC alloc region (i.e., we are copying objects into it), then the entry is "expanded". This means that the entry gets T - 1 extra tables (where T is the number of GC threads). This way, each such table can be updated by a GC thread without any synchronization (as each table can only be updated by only one GC thread). GC thread 0 still updates the "main" entry. At the end of the pause, all the expanded tables are collapsed and the information from them is propagated into the main table.

In the current version of G1, the expanded tables are not heavily used / used at all given that we try to defer the RSet updates (not do them immediately during a pause but defer them to the concurrent refinement threads).

Given that they are not used and add code complexity, it'd be helpful to remove them to simplify the RSet code.

                                    

Comments
EVALUATION

Cleanup changes provided by Thomas Schatzl as a pre-requesite for a change that chains PRTs (used in an RSet's fine grain entries) together into a doubly linked list. During freeing, this allows the PRTs in an RSet to be added to the global free list as a single operation.
                                     
2012-06-19
EVALUATION

http://hg.openjdk.java.net/hsx/hotspot-gc/hotspot/rev/7994a5a35fcf
                                     
2012-06-26



Hardware and Software, Engineered to Work Together