Depth first object copying for all GC?

Tangwei (Euler Architecture & Design Dept) tangwei6 at
Thu May 7 02:56:44 UTC 2015

Would you help to list the object copying policy for different GC?  Or pointing out where to find such information?


From: hotspot-gc-dev [mailto:hotspot-gc-dev-bounces at] On Behalf Of Jon Masamitsu
Sent: Thursday, May 07, 2015 8:23 AM
To: hotspot-gc-dev at
Subject: Re: Depth first object copying for all GC?

On 5/6/2015 4:34 AM, Tangwei (Euler Architecture & Design Dept) wrote:
Hi All,
  As a newbie in GC, I found some discussion on object copying order in following slides: breadth vs. depth.
It mentioned that "Any static policy will hurt some applications and help others". After searching, there is a BZ shows
the object copying order has been switched from breadth to depth for ParallelGC in OpenJDK, please correct if I am wrong.
Anyone can help to confirm if all GC in OpenJDK use depth first copying now?

No, not all the GC's use depth first copying.

Is there any performance consideration to choose depth first instead of controlling by option?

Yes, there is a performance cost to optionally using depth-first or breadth-first.
ParallelGC used to have such an option.  It made the code harder to maintain and,
as far as I can recall, there was very little use of the option.  We removed the
it.  I recall maybe 1 complaint about it.

Jon Improve object copying order in parallel scavenge


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the hotspot-gc-dev mailing list