JDK-8333375 : gtest CollectorPolicy.young_scaled_initial_ergo() inconsistent with code
  • Type: Bug
  • Component: hotspot
  • Sub-Component: gc
  • Affected Version: 23
  • Priority: P4
  • Status: Open
  • Resolution: Unresolved
  • Submitted: 2024-05-31
  • Updated: 2024-11-18
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.
Other
tbdUnresolved
Related Reports
Relates :  
Description
CollectorPolicy.young_scaled_initial_ergo()'s comment says

// If NewSize has been ergonomically set, the collector policy
// should use it for min but calculate the initial young size
// using NewRatio.

(https://github.com/openjdk/jdk/blob/master/test/hotspot/gtest/gc/shared/test_collectorPolicy.cpp#L224)


and code has comment that says:
      // If NewSize is set on the command line, we should use it as
      // the initial size, but make sure it is within the heap bounds.

(https://github.com/openjdk/jdk/blob/master/src/hotspot/share/gc/shared/genArguments.cpp#L258)

BTW, I believe CollectorPolicy gtest is fault, please refer to the discussion in JDK-8331675. I think we should convert them to something similar to https://github.com/openjdk/jdk/blob/master/test/hotspot/jtreg/gc/arguments/TestParallelGCErgo.java. GC experts, please confirm.

Comments
[~tschatzl ] Could you clarify if your comment refers to CollectorPolicy.young_min_ergo_vm test or CollectorPolicy suite. Thanks.
06-06-2024

The evaluation seems plausible.
03-06-2024