I know there are different garbage collection algorithms. Those are Copy collection and Mark Compact collection, Incremental collection. I have a query now. Which algorithm is used in JVM? Why there are different algorithm available?
I know there are different garbage collection algorithms. Those are Copy collection and Mark
Share
First off, there is more than one version of the JVM.
I believe most major JVM’s are using a generational garbage collection by default. They may also use a hybrid strategy however.
Here are some links on major JVM’s using generational garbage collection:
Here is a great article I found that indicates Jrockit uses a marking strategy:
Comparison of three Major JVM’s