United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
JDK-7046558 : G1: concurrent marking optimizations

Details
Type:
Enhancement
Submit Date:
2011-05-19
Status:
Closed
Updated Date:
2011-11-25
Project Name:
JDK
Resolved Date:
2011-09-30
Component:
hotspot
OS:
generic
Sub-Component:
gc
CPU:
generic
Priority:
P4
Resolution:
Fixed
Affected Versions:
hs21
Fixed Versions:
hs22 (b03)

Related Reports
Backport:
Backport:

Sub Tasks

Description
There are some simple optimizations we can do do improve the performance of the concurrent marking phase.

- CMOopClosure, which is used to scan objects during marking, is not specialized. By specializing it we will be able to get a nice performance boost. We should also rename it with a G1-specific name (say: G1CMOopClosure) given that its declaration will move to an .hpp file.

- There are a couple of methods in the fast path that will benefit from getting inlined. These are CMTask::deal_with_reference() and CMTask::push()

- We are using the wrong bitmap operations! In the parallel case we are using par_at_put() which in turn calls either par_set_bit() or par_clear_bit(). We should call the latter directly (which will also be inlined, par_at_put() is not). Ditto for at_put() and set_bit() / clear_bit().

- There are places where we can use the slightly more efficient heap_region_containing_raw(), instead of heap_region_containing(), as we know that the address is in the G1 heap.

- When we check whether an object is live or not we should first check whether it's marked on the bitmap and, only if it's not, get its containing region.

                                    

Comments
EVALUATION

See Description
                                     
2011-05-19
EVALUATION

http://hg.openjdk.java.net/hsx/hotspot-gc/hotspot/rev/842b840e67db
                                     
2011-06-14
EVALUATION

http://hg.openjdk.java.net/hsx/hotspot-comp/hotspot/rev/842b840e67db
                                     
2011-07-08
EVALUATION

http://hg.openjdk.java.net/hsx/hotspot-rt/hotspot/rev/842b840e67db
                                     
2011-07-08
EVALUATION

See main CR
                                     
2011-09-12



Hardware and Software, Engineered to Work Together