Two most basic Java recycling algorithms: Copy algorithm and tag cleanup algorithm replication algorithm: Two regions A and B, the initial object in a, the object that continues to survive is transferred to B. This is the new generation of the most commonly used algorithm tag cleanup: An area, mark the object to be recycled, and then recycled, must be fragmented, then the lead-out tag-collation algorithm: More defragmentation, the larger memory put larger objects two concepts: The Cenozoic and the old generation: the initial object, A permanent generation with short life cycles: long-existing objects The entire Java garbage collection is a collaboration between the new generation and older generations, which is called generational recycling. P.s:serial new Collector is for the generation of collectors, the use of the replication algorithm parallel New (parallel) collector, the Cenozoic use of replication algorithm, the old age using the tag collation parallel scavenge (parallel) collector, for the Cenozoic, Using the replication collection algorithm serial old (serial) collector, the new generation uses the replication, the older era uses the marking to organize the parallel (parallel) collector, according to the old age, marks organizes the CMS collector, based on the mark cleans up the G1 collector: The whole is based on the labeling collation, the partial adoption copy
Java Recovery algorithm