RFR (S): 8073204: Determining the desired PLAB size adjusts to the the number of threads at the wrong place
ysr1729 at gmail.com
Mon Apr 6 22:40:42 UTC 2015
Hi Sangheon --
Does the number of GC workers ever change dynamically within a stop-world
If not, you might save a little work by just doing the division once when
you decide the number of
workers at the start of the copying phase, and then use that value for the
remainder of the copying
phase of the collection when you know the number of workers won't change.
However, that is just a
nit, I am sure the work involved in calculating the value at each PLAB
refill shouldn't typically be a
big deal either way.
I might rename the _desired_plab_sz field to clarify that it's the net
value, say by calling it
_desired_net_plab_sz. (Alternatively, you could change the name of the
desired_plab_sz(int) to desired_plab_size_for_n_workers(int), but the
former seems better,
since the parameter already signals the intention for the latter.)
looks good to me otherwise.
-- ramki (openjdk: ysr)
On Mon, Apr 6, 2015 at 2:40 PM, Sangheon Kim <sangheon.kim at oracle.com>
> Hi all,
> Please review this change to determine the desired PLAB size for current
> gc worker threads.
> Currently we calculate an optimal PLAB size with current number of gc
> When the number of workers changes dynamically (-XX:+UseDynamicNumberOfGCThreads),
> the desired PLAB size returned(by desired_plab_sz()) is still tuned to the
> number of gc workers that has been used previously.
> This change is first calculate the desired PLAB value for a single gc
> worker and then return desired PLAB size according to the current number of
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the hotspot-gc-dev