-
Notifications
You must be signed in to change notification settings - Fork 5.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
8330051: Small ObjectMonitor spinning code cleanups #18730
Conversation
👋 Welcome back coleenp! A progress list of the required criteria for merging this PR into |
@coleenp 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:
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 231 new commits pushed to the
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 |
Webrevs
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are some changes in behavior that I've flagged in this pass.
They might actually be okay, but I have to mull on it. For now I'm
not yet ready to approve.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the knowledgable review and comments.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good to me. Maybe one name change nit. I don't need to see the updated version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. Introducing TryLockResult
really improves the readability.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the if
/break
update. Looks good!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thumbs up!
Thank you Dan, Fredrik, Erik and Axel for your reviews and comments. |
Going to push as commit ee7b2e9.
Your commit was automatically rebased without conflicts. |
Please review this patch that refactors some functions in the adaptive spinning code and moves the Knobs to where they're used and can be modified for experiments in the following code. Also changed 'goto's to a 'break'. I didn't change the names of TrySpin or TryLock, since all the names in this file are this style.
The only non-cosmetic change is for the pre-spin. If the TryLock returns that a CAS failed, then the pre-spin ends, which shouldn't make a difference wrt to performance because the pre-spin is only for 10 iterations, but somehow my numbers are a little bit better for both Dacapo pmd and xalan.
Tested with tier1-7.
Progress
Issue
Reviewers
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/18730/head:pull/18730
$ git checkout pull/18730
Update a local copy of the PR:
$ git checkout pull/18730
$ git pull https://git.openjdk.org/jdk.git pull/18730/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 18730
View PR using the GUI difftool:
$ git pr show -t 18730
Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/18730.diff
Webrev
Link to Webrev Comment