JDK-8286467 : G1: Collection set pruning adds one region too many
  • Type: Bug
  • Component: hotspot
  • Sub-Component: gc
  • Affected Version: 19
  • Priority: P4
  • Status: New
  • Resolution: Unresolved
  • Submitted: 2022-05-10
  • Updated: 2022-05-11
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 19
19Unresolved
Related Reports
Relates :  
Description
The following if statement in the do_heap_region function of G1PruneRegionClosure:

>      if (_num_pruned > _max_pruned ||
>          _cur_wasted + reclaimable > _max_wasted) {
>          return true;
>      }

should be >=, otherwise one too many region than intended will be added.

Impact is limited, as the pruning is an inherently inexact and conservative heuristics driven process.

Reported by Tianqi Xia (https://mail.openjdk.java.net/pipermail/hotspot-gc-dev/2022-May/039287.html)
Comments
A pull request was submitted for review. URL: https://git.openjdk.java.net/jdk/pull/8645 Date: 2022-05-11 04:06:48 +0000
11-05-2022