RFR (XS): Make sure new_active_workers is used

Zhengyu Gu zgu at redhat.com
Tue Apr 18 13:00:02 UTC 2017


Good to me.

-Zhengyu

On 04/18/2017 08:55 AM, Aleksey Shipilev wrote:
> Static code analysis complains this store is not used:
>
>   uint new_active_workers = total_workers;
>
> This is because the line below overwrites it. I suppose we should change that line:
>
> diff -r 1be7a284a52f src/share/vm/gc/shenandoah/shenandoahCollectorPolicy.cpp
> --- a/src/share/vm/gc/shenandoah/shenandoahCollectorPolicy.cpp	Mon Apr 17
> 18:24:45 2017 +0200
> +++ b/src/share/vm/gc/shenandoah/shenandoahCollectorPolicy.cpp	Tue Apr 18
> 14:53:37 2017 +0200
> @@ -1016,7 +1016,7 @@
>    uint max_active_workers =
>      MAX2(active_workers_by_JT, active_workers_by_liveset);
>
> -  new_active_workers = MIN2(max_active_workers, total_workers);
> +  new_active_workers = MIN2(max_active_workers, new_active_workers);
>
>    // Increase GC workers instantly but decrease them more
>    // slowly.
>
> Thanks,
> -Aleksey
>


More information about the shenandoah-dev mailing list