RFR 8232747: Shenandoah: Concurrent GC should deactivate SATB before processing weak roots

Aleksey Shipilev shade at redhat.com
Tue Oct 22 13:55:04 UTC 2019


On 10/22/19 3:38 PM, Zhengyu Gu wrote:
> This is the counterpart of JDK-8231999[1] for Shenandoah concurrent GC. Shenandoah needs to
> deactivate SATB barrier before processing weak roots, to avoid barrier side-effects on its paths.
> 
> Bug: https://bugs.openjdk.java.net/browse/JDK-8232747
> Webrev: http://cr.openjdk.java.net/~zgu/JDK-8232747/webrev.00/index.html

*) Mmm... In ShenandoahConcurrentMark::finish_mark_from_roots, there is a call:
  _heap->parallel_cleaning(full_gc);

  Does it mean new code would perform cleaning twice?

*) This comment relates to keeping has_forwarded_objects set on cancelled path:

   // If we needed to update refs, and concurrent marking has been cancelled,
   // we need to finish updating references.

...current placement loses that connection. Suggestion:

   // If this cycle was updating references and got cancelled, we need to keep
   // the flag on, for subsequent phases to deal with it.

*) Maybe we should inline stop_concurrent_marking everywhere to make the flow more obvious...

-- 
Thanks,
-Aleksey




More information about the hotspot-gc-dev mailing list