-
Notifications
You must be signed in to change notification settings - Fork 6.2k
8374190: Convert ConcurrentHashTable atomic lists to use Atomic<T> #28951
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
base: master
Are you sure you want to change the base?
Conversation
|
👋 Welcome back kbarrett! A progress list of the required criteria for merging this PR into |
|
@kimbarrett 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 10 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 |
|
@kimbarrett The following label will be automatically applied to this pull request:
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. |
dholmes-ora
left a comment
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 all seems reasonable.
Thanks
| // only give out pointer to const Node pointer to avoid accidental | ||
| // assignment, thus here we must cast const part away. Method is not static | ||
| // due to an assert. | ||
| void release_assign_node_ptr(Node* const volatile * dst, Node* node) const; | ||
| void release_assign_node_ptr(const Atomic<Node*>* dst, Node* node) const; |
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.
The const part of the comment no longer seems relevant.
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.
The const is still relevant, for the reason described. It's at least
arguable that it's kind of sketchy to do this. It certainly took me a bit of
study to understand. Note that I moved the position of the const qualifier
to its more usual location (in our code) for declaring a constant object (the
Atomic<Node*> is atomic). It could instead be written as Atomic<Node*> const*,
retaining the ordering from the original. Also see the implementation, where
we need to cast away the const qualifier, which is now being done with
const_cast rather than a C-style cast (that was also stripping off the volatile
qualifier, which the use of AtomicAccess implicitly reapplied).
Please review this change to ConcurrentHashTable to use
Atomic<Node*>forthe Node lists. Note that this does not complete the replacement of direct
uses of AtomicAccess by that class; there's still one more group remaining.
Testing: mach5 tier1-3
Progress
Issue
Reviewers
Reviewing
Using
gitCheckout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/28951/head:pull/28951$ git checkout pull/28951Update a local copy of the PR:
$ git checkout pull/28951$ git pull https://git.openjdk.org/jdk.git pull/28951/headUsing Skara CLI tools
Checkout this PR locally:
$ git pr checkout 28951View PR using the GUI difftool:
$ git pr show -t 28951Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/28951.diff
Using Webrev
Link to Webrev Comment