Skip to content

Comments

8352147: G1: TestEagerReclaimHumongousRegionsClearMarkBits test takes very long#24077

Closed
tschatzl wants to merge 1 commit intoopenjdk:masterfrom
tschatzl:submit/8352147-TestEagerReclaimHumongousRegionsClearMarkBits-refactor
Closed

8352147: G1: TestEagerReclaimHumongousRegionsClearMarkBits test takes very long#24077
tschatzl wants to merge 1 commit intoopenjdk:masterfrom
tschatzl:submit/8352147-TestEagerReclaimHumongousRegionsClearMarkBits-refactor

Conversation

@tschatzl
Copy link
Contributor

@tschatzl tschatzl commented Mar 17, 2025

Hi all,

please review this refactor of the TestEagerReclaimHumongousRegionsClearMarkBits test that runs way too long, and sometimes even causing timeouts in GHA.

So the problem is that TestEagerReclaimHumongousRegionsClearMarkBits checks whether after eager reclaim during marking the mark on the humongous object is cleared correctly. It does so with a trial-and-error approach allocating humongous objects and hoping that the faulty state somehow occurs.

This can take a long time, and although the test limits itself to 50s runtime, for some reason there can still be sporadic timeouts in some setups.

However for a long time it has been possible to halt concurrent mark just before completion, inducing the exact state needed for this test. So rewrite the test to be more targeted.

Testing: gha, running test locally

Thanks,
Thomas


Progress

  • Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue

Issue

  • JDK-8352147: G1: TestEagerReclaimHumongousRegionsClearMarkBits test takes very long (Enhancement - P4)

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/24077/head:pull/24077
$ git checkout pull/24077

Update a local copy of the PR:
$ git checkout pull/24077
$ git pull https://git.openjdk.org/jdk.git pull/24077/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 24077

View PR using the GUI difftool:
$ git pr show -t 24077

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/24077.diff

Using Webrev

Link to Webrev Comment

@bridgekeeper
Copy link

bridgekeeper bot commented Mar 17, 2025

👋 Welcome back tschatzl! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk
Copy link

openjdk bot commented Mar 17, 2025

@tschatzl This change now passes all automated pre-integration checks.

ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details.

After integration, the commit message for the final commit will be:

8352147: G1: TestEagerReclaimHumongousRegionsClearMarkBits test takes very long

Reviewed-by: iwalulya, ayang

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 90 new commits pushed to the master branch:

  • de58009: 8351468: C2: array fill optimization assigns wrong type to intrinsic call
  • a875733: 8352486: [ubsan] compilationMemoryStatistic.cpp:659:21: runtime error: index 64 out of bounds for type const struct unnamed struct
  • 5591f8a: 8351515: C2 incorrectly removes double negation for double and float
  • 56a4ffa: 8352597: [IR Framework] test bug: TestNotCompilable.java fails on product build
  • e23e0f8: 8352591: Missing UnlockDiagnosticVMOptions in VerifyGraphEdgesWithDeadCodeCheckFromSafepoints test
  • adfb120: 8351748: Add class init barrier to AOT-cached Method/Var Handles
  • ee1577b: 8352652: [BACKOUT] nsk/jvmti/ tests should fail when nsk_jvmti_setFailStatus() is called
  • df9210e: 8347706: jvmciEnv.cpp has jvmci includes out of order
  • 5dd0acb: 8352477: RISC-V: Print warnings when unsupported intrinsics are enabled
  • 334a1ee: 8351375: nsk/jvmti/ tests should fail when nsk_jvmti_setFailStatus() is called
  • ... and 80 more: https://git.openjdk.org/jdk/compare/86b24339dc05422f61e10023f97a9013e2c03a15...master

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

➡️ To integrate this PR with the above commit message to the master branch, type /integrate in a new comment.

@openjdk openjdk bot changed the title 8352147 8352147: G1: TestEagerReclaimHumongousRegionsClearMarkBits test takes very long Mar 17, 2025
@openjdk openjdk bot added the rfr Pull request is ready for review label Mar 17, 2025
@openjdk
Copy link

openjdk bot commented Mar 17, 2025

@tschatzl The following label will be automatically applied to this pull request:

  • hotspot-gc

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command.

@openjdk openjdk bot added the hotspot-gc hotspot-gc-dev@openjdk.org label Mar 17, 2025
@mlbridge
Copy link

mlbridge bot commented Mar 17, 2025

Webrevs

@tschatzl tschatzl marked this pull request as draft March 17, 2025 13:09
@openjdk openjdk bot removed the rfr Pull request is ready for review label Mar 17, 2025
@tschatzl tschatzl marked this pull request as ready for review March 17, 2025 13:23
@openjdk openjdk bot added the rfr Pull request is ready for review label Mar 17, 2025
@tschatzl tschatzl force-pushed the submit/8352147-TestEagerReclaimHumongousRegionsClearMarkBits-refactor branch from 240f01f to 86aa849 Compare March 17, 2025 13:47
@openjdk
Copy link

openjdk bot commented Mar 17, 2025

@tschatzl Please do not rebase or force-push to an active PR as it invalidates existing review comments. Note for future reference, the bots always squash all changes into a single commit automatically as part of the integration. See OpenJDK Developers’ Guide for more information.

@tschatzl tschatzl marked this pull request as draft March 17, 2025 13:53
@openjdk openjdk bot removed the rfr Pull request is ready for review label Mar 17, 2025
Hi all,

  please review this refactor of the TestEagerReclaimHumongousRegionsClearMarkBits test that runs way too long, and sometimes even causing timeouts in GHA.

So the problem is that TestEagerReclaimHumongousRegionsClearMarkBits checks whether after eager reclaim during marking the mark on the humongous object is cleared correctly. It does so with a trial-and-error approach allocating humongous objects and hoping that the faulty state somehow occurs.

This can take a long time, and although the test limits itself to 50s runtime, for some reason there can still be sporadic timeouts in some setups.

However for a long time it is possible to halt concurrent mark just before completion, inducing the exact state needed for this test. So rewrite the test to be more targeted.

Testing: gha, running test locally

Thanks,
  Thomas

* also check for actual region reclamation
* last minute typo
@tschatzl tschatzl force-pushed the submit/8352147-TestEagerReclaimHumongousRegionsClearMarkBits-refactor branch from 86aa849 to 8f3f5ae Compare March 17, 2025 13:57
@tschatzl tschatzl marked this pull request as ready for review March 17, 2025 15:43
@openjdk openjdk bot added the rfr Pull request is ready for review label Mar 17, 2025
Copy link
Member

@walulyai walulyai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Mar 17, 2025
@tschatzl
Copy link
Contributor Author

Thanks @walulyai @albertnetymk for your reviews
/integrate

@openjdk
Copy link

openjdk bot commented Mar 24, 2025

Going to push as commit 02a4ce2.
Since your change was applied there have been 90 commits pushed to the master branch:

  • de58009: 8351468: C2: array fill optimization assigns wrong type to intrinsic call
  • a875733: 8352486: [ubsan] compilationMemoryStatistic.cpp:659:21: runtime error: index 64 out of bounds for type const struct unnamed struct
  • 5591f8a: 8351515: C2 incorrectly removes double negation for double and float
  • 56a4ffa: 8352597: [IR Framework] test bug: TestNotCompilable.java fails on product build
  • e23e0f8: 8352591: Missing UnlockDiagnosticVMOptions in VerifyGraphEdgesWithDeadCodeCheckFromSafepoints test
  • adfb120: 8351748: Add class init barrier to AOT-cached Method/Var Handles
  • ee1577b: 8352652: [BACKOUT] nsk/jvmti/ tests should fail when nsk_jvmti_setFailStatus() is called
  • df9210e: 8347706: jvmciEnv.cpp has jvmci includes out of order
  • 5dd0acb: 8352477: RISC-V: Print warnings when unsupported intrinsics are enabled
  • 334a1ee: 8351375: nsk/jvmti/ tests should fail when nsk_jvmti_setFailStatus() is called
  • ... and 80 more: https://git.openjdk.org/jdk/compare/86b24339dc05422f61e10023f97a9013e2c03a15...master

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot added the integrated Pull request has been integrated label Mar 24, 2025
@openjdk openjdk bot closed this Mar 24, 2025
@openjdk openjdk bot removed ready Pull request is ready to be integrated rfr Pull request is ready for review labels Mar 24, 2025
@openjdk
Copy link

openjdk bot commented Mar 24, 2025

@tschatzl Pushed as commit 02a4ce2.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@tschatzl tschatzl deleted the submit/8352147-TestEagerReclaimHumongousRegionsClearMarkBits-refactor branch October 15, 2025 11:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

hotspot-gc hotspot-gc-dev@openjdk.org integrated Pull request has been integrated

Development

Successfully merging this pull request may close these issues.

3 participants