RFR: 8280384: Parallel: Remove VMThread specific ParCompactionManager

Thomas Schatzl tschatzl at openjdk.java.net
Mon Jan 24 10:45:26 UTC 2022


Hi all,

   can I have reviews for this change? Parallel GC allocates `ParallelGCThreads+1` `ParCompactionManagers`, the last one only used for work in the VM thread. That `ParCompactionManager``s task queue is also not wired into the work stealing mechanism (i.e. the `TaskQueueSet`). This causes unnecessary code duplication when printing statistics for something which is mostly not used at all.

The suggestion is to remove that unnecessarily allocated task queue as it seems unnecessary: this special handling for an apparently uncommon case prevents factoring out task queue statistics code, and use the 0'th `ParcompactionManager` for these tasks which the code states to be just fine (and it is). In e.g. G1 we also just use the 0'th "worker id" and associated data structures when doing work in the VM thread directly.

Testing: tier1-5

Thanks,
  Thomas

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

Commit messages:
 - Merge branch 'master' into 8280384-vmthread-parcompactionmanager
 - Remove unnecessary assert
 - Fixes
 - Remove VMThread ParCompactionManager

Changes: https://git.openjdk.java.net/jdk/pull/7195/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=7195&range=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8280384
  Stats: 50 lines in 7 files changed: 2 ins; 28 del; 20 mod
  Patch: https://git.openjdk.java.net/jdk/pull/7195.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/7195/head:pull/7195

PR: https://git.openjdk.java.net/jdk/pull/7195



More information about the hotspot-gc-dev mailing list