Full GC

 

(1) When you call System.gc, the system proposes the implementation of Full GC, but not necessarily execution

(2) years old and insufficient space ------ such as continuous large objects directly into the old year

(3) the method area space shortage

  (4) promotion failed and concurrent mode failure CMS GC when

(5) made in the implementation of a series of checks minor gc

When the execution Minor GC, JVM checks to see if the old era largest contiguous free space is larger than the total size of all current new generation of objects.
If so, then executed directly Minor GC (this time there is no risk of execution).
If less than a, JVM checks to see if the open space allocation guarantee mechanism, if not open directly into an Executive Full GC.
If you turn, the JVM will check whether old's largest contiguous free space is larger than the average size of the previous promotion to the old era, if less than the execution instead perform Full GC. --------
If Minor GC will be greater than the execution fails if Minor GC will perform Full GC

 

Large objects directly into the old year:
    the so-called large object refers to a Java object requires a lot of contiguous memory space. For example: long string or array. Virtual machines provide a -XX: PretenureSizeThreshold parameters. So larger than this -XX: Object PretenureSizeThreshold set the value of the direct allocation in the old era.

Guess you like

Origin www.cnblogs.com/ZoHy/p/11490409.html