RFR: 8373022: serviceability/sa/ClhsdbScanOops.java assumes no GC should occur [v2]

Joel Sikström jsikstro at openjdk.org
Fri Dec 5 11:07:34 UTC 2025


> Hello,
> 
> If the initial heap size is set too low in serviceability/sa/ClhsdbScanOops.java, a GC migh run, which will interfere with the test and might cause it to fail. 
> 
> The test is scanning the oops in a region of the heap, and after a GC that region appears to be empty, so the output that the test expects is not present. Running the test with a larger explicit InitialHeapSize gives enough headroom to not run a GC.
> 
> Testing: 
> * serviceability/sa/ClhsdbScanOops.java originally failed when run with `-XX:InitialRAMPercentage=0` (which is the new default). We now explicitly set `-XX:InitialHeapSize=100M`. I've rerun the test 10 times with Serial and Parallel for each test and they all pass.

Joel Sikström has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains five additional commits since the last revision:

 - Remove ClhsdbScanOops.java from ProblemList
 - Merge branch 'master' into JDK-8373022_initialheapsize_test_no_gc
 - Remove InitialHeapSize from MethodInvokeWithTraceOnTest
 - Spell fix
 - 8373022: Increase initial heap size for test which assumes no GC

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/28637/files
  - new: https://git.openjdk.org/jdk/pull/28637/files/97f53447..0f85529d

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=28637&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=28637&range=00-01

  Stats: 8457 lines in 271 files changed: 6033 ins; 1546 del; 878 mod
  Patch: https://git.openjdk.org/jdk/pull/28637.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/28637/head:pull/28637

PR: https://git.openjdk.org/jdk/pull/28637


More information about the serviceability-dev mailing list