1 INTRODUCTION ...............................................................................................................................5
1.1 OBJECT ALLOCATION ....................................................................................................................5
1.2 REACHABLE OBJECTS ...................................................................................................................5
1.3 GARBAGE COLLECTION ................................................................................................................6
1.3.1 Mark Phase .............................................................................................................................6
1.3.2 Sweep Phase............................................................................................................................7
1.3.3 Compaction Phase...................................................................................................................7
2 DATA AREAS .....................................................................................................................................8
2.1 AN OBJECT ...................................................................................................................................8
2.2 THE HEAP ...................................................................................................................................10
2.2.1 Setting the heap size ..............................................................................................................10
2.3 ALLOC BITS AND MARK BITS .......................................................................................................12
2.4 THE SYSTEM HEAP .....................................................................................................................13
2.5 THE FREE LIST ............................................................................................................................14
3 ALLOCATION..................................................................................................................................15
3.1 HEAP LOCK ALLOCATION ............................................................................................................15
3.1.1 Hints ......................................................................................................................................16
3.2 CACHE ALLOCATION ..................................................................................................................17
4 GARBAGE COLLECTION .............................................................................................................19
4.1 MARK PHASE ..............................................................................................................................19
4.1.1 Mark stack overflow ..............................................................................................................20
4.1.2 Parallel Mark ........................................................................................................................22
4.1.3 Concurrent Mark...................................................................................................................22
4.2 SWEEP PHASE .............................................................................................................................24
4.2.1 Parallel Bitwise Sweep..........................................................................................................24
4.3 COMPACTION PHASE...................................................................................................................25
4.3.1 Compaction Avoidance..........................................................................................................26
4.3.2 Incremental Compaction .......................................................................................................27
4.4 REFERENCE OBJECTS ..................................................................................................................30
4.4.1 JNI weak references ..............................................................................................................30
4.5 HEAP EXPANSION .......................................................................................................................31
4.6 HEAP SHRINKAGE .......................................................................................................................32
4.7 RESETTABLE JVM ......................................................................................................................32
4.8 VERBOSEGC.................................................................................................................................33
4.8.1 verbosegc output from a System.gc .......................................................................................33
4.8.2 verbosegc output from an allocation failure .........................................................................33
4.8.3 verbosegc for a heap expansion ............................................................................................34
4.8.4 verbosegc for a heap shrinkage.............................................................................................35
4.8.5 verbosegc for a compaction...................................................................................................35
4.8.6 verbosegc for concurrent mark kick-off.................................................................................36
4.8.7 verbosegc for a concurrent mark System.gc collection .........................................................37
4.8.8 verbosegc for a concurrent mark AF collection ....................................................................37
4.8.9 verbosegc for a concurrent mark AF collection with :Xgccon ..............................................38
4.8.10 verbosegc for a concurrent mark collection .....................................................................38
4.8.11 verbosegc for a concurrent mark collection with :Xgccon ...............................................39
4.8.12 verbosegc and resettable ..................................................................................................40
5 MESSAGES .......................................................................................................................................41
6 COMMAND LINE PARAMETERS................................................................................................54
APPENDIX A. NOTICES ...................................................................................................................58