RFR: 8213224: Move code related to GC threads calculation out of AdaptiveSizePolicy (original) (raw)

Man Cao manc at google.com
Tue Nov 20 23:56:02 UTC 2018


Friendly ping.

-Man

On Mon, Nov 5, 2018 at 6:30 PM Man Cao <manc at google.com> wrote:

Hi, Thanks for the review! I moved those 3 functions and created a new WorkerPolicy class as suggested. New webrev: https://cr.openjdk.java.net/~manc/8213224/webrev.01/ There's a Sparc-specific heuristic for VMVersion::calcparallelworkerthreads(). I added a function AbstractVMVersion::parallelworkerthreadsdenominator() in order to keep this behavior and minimize relevant code in VMVersion class. I also changed "unsigned int" to "uint", for the functions from VMVersion. Now the change in workerManager.hpp is only trivial code movement and improving #include statements. Thanks, Man

On Mon, Nov 5, 2018 at 12:20 AM Per Liden <per.liden at oracle.com> wrote:

Hi, On 11/1/18 6:49 PM, Man Cao wrote: > Hi all, > > Could anyone review this cleanup change? > In addition to straight code movement, it removes unnecessary dependency > on adaptiveSizePolicy.hpp in G1 code, and removed unnecessary include > statements in adaptiveSizePolicy.hpp/cpp. > > Webrev: https://cr.openjdk.java.net/~manc/8213224/webrev.00/ > RFE: https://bugs.openjdk.java.net/browse/JDK-8213224 Removing these function from AdaptiveSizePolicy might be a good idea, but I'm not sure they fit very well into the WorkerManager class, which is a backend for AbstractWorkGang and GCTaskManager. These functions might fit better into a new WorkerPolicy class. Such a class could also be the new home for these function (which currently sit is an very odd place): AbstractVMVersion::nofparallelworkerthreads(); AbstractVMVersion::parallelworkerthreads(); AbstractVMVersion::calcparallelworkerthreads(); cheers, Per > Tested on submit repo with the help from JC (CCed). > > Thanks, > Man



More information about the hotspot-gc-dev mailing list