JDK-8306696 : Remove MetaspaceReclaimPolicy=aggressive and obsolete MetaspaceReclaimPolicy
  • Type: Enhancement
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 21
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2023-04-22
  • Updated: 2023-05-04
  • Resolved: 2023-04-28
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 21
21 b21Fixed
Related Reports
Relates :  
Relates :  
Relates :  
Description
The diagnostic setting MetaspaceReclaimPolicy=aggressive is very rarely used, and I would like to remove it. This is a part of a larger effort to simplify metaspace coding and cut down on testing time, in preparation for upcoming changes to Metaspace with Lilliput. 

MetaspaceReclaimPolicy had recently been demoted from an official to a diagnostic switch (see CSR JDK-8302130). See also the CSR text for a more in-depth explanation of what this switch does, its history, and why it could be removed for good.

The switch has not that much impact on RSS reduction but has the side effect of increasing VMA fragmentation compared to the default setting since it reduces the size of metaspace commit granules from 64K to 16K. The settings used by default (MetaspaceReclaimPolicy=balanced) are proven now in the field and can be used without alternatives (since any alternative has to be tested).

Since this would remove the last valid value for MetaspaceReclaimPolicy apart from its default "balanced" value, it makes sense to obsolete MetaspaceReclaimPolicy at the same time.

This allows us to cut down on Metaspace testing quite a bit since it removes one permutation from the test set.



Comments
Changeset: 0b5c504a Author: Thomas Stuefe <stuefe@openjdk.org> Date: 2023-04-28 06:08:24 +0000 URL: https://git.openjdk.org/jdk/commit/0b5c504ad00c3a2b64bbb049934ce069fac1d5a3
28-04-2023

A pull request was submitted for review. URL: https://git.openjdk.org/jdk/pull/13597 Date: 2023-04-22 07:35:29 +0000
22-04-2023