RFR: Fix ShenandoahPurgeSATBTask

earthling-amzn github.com+71722661+earthling-amzn at openjdk.java.net
Thu Mar 18 15:45:57 UTC 2021


On Thu, 18 Mar 2021 14:54:02 GMT, Zhengyu Gu <zgu at openjdk.org> wrote:

> ShenandoahPurgeSATBTask looks wrong.
> 
> 1) Thread's token should be claimed by task, not by closure
> 2) Threads::threads_do() is single thread version.
> 
> Note: It can be improved by only iterating JavaThread with ShenandoahJavaThreadsIterator, but it needs phase time ...

Thanks for catching this! For what it's worth, I followed the pattern from `ShenandoahSATBAndRemarkThreadsClosure` in `shenandoahConcurrentMark.cpp`, do you think the code there needs a similar change?

-------------

PR: https://git.openjdk.java.net/shenandoah/pull/23


More information about the shenandoah-dev mailing list