JDK-8184918 : Young gen length recalculation too aggressive
  • Type: Bug
  • Component: hotspot
  • Sub-Component: gc
  • Affected Version: 9,10
  • Priority: P3
  • Status: Closed
  • Resolution: Duplicate
  • Submitted: 2017-07-19
  • Updated: 2020-05-20
  • Resolved: 2020-05-20
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 15
15Resolved
Related Reports
Duplicate :  
Relates :  
Description
G1 has a feature to recalculate the young gen length according to changes in the remembered set concurrently to the mutator.

For that recalculation it uses the costs for scanning the remembered sets (among other things), that multiplies the number of remembered set entries of (a sample of) the current young gen with the costs for scanning a card.

The problem is that the costs for scanning a card are calculated with the costs of actually scanned cards, but the young gen sampling multiplies that by the sum of remembered set entries.

If the sum of remembered set entries for the young gen is significantly different from the number of actually scanned cards, the "base cost" for that recalculation is highly inflated, and so the young gen size is decreased a lot, impacting performance significantly due to too small young gen (frequent gcs) in these types of applications.

This is a day-one problem afaics, not seen before because it needs a certain type of application, where remembered set scan time is significant, and the amount of scanned card is significantly different from the number of cards in the remembered sets.
Comments
JDK-8231731 deals the source of these problems, i.e. improves cardinality estimations.
20-05-2020

Same issue.
18-05-2020