jdk
jdk copied to clipboard
8292240: CarrierThread.blocking not reset when spare not activated
Some blocking operations that pin a virtual thread to its carrier will compensate by activating a spare carrier (essentially managed blocker). This is done by wrapping the operation in a Blocker begin/end. This code is not correct for the case that a spare cannot be activated (e.g. already at the max of 256 carrier threads). When that happens, the carrier thread's "blocking" flag, used to detect reentrancy, is not reset when the blocking operation is done. The result is that subsequent blocking operations by virtual threads on this carrier thread will not attempt to activate s spare.
The test runs with parallelism=1 and maxPoolSize=2 in order to make it easier to create the conditions for this bug.
Progress
- [ ] Change must be properly reviewed (1 review required, with at least 1 Reviewer)
- [x] Change must not contain extraneous whitespace
- [x] Commit message must refer to an issue
Issue
- JDK-8292240: CarrierThread.blocking not reset when spare not activated
Reviewing
Using git
Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk pull/9841/head:pull/9841
$ git checkout pull/9841
Update a local copy of the PR:
$ git checkout pull/9841
$ git pull https://git.openjdk.org/jdk pull/9841/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 9841
View PR using the GUI difftool:
$ git pr show -t 9841
Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/9841.diff
:wave: Welcome back alanb! 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.
@AlanBateman The following label will be automatically applied to this pull request:
core-libs
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.
@AlanBateman 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:
8292240: CarrierThread.blocking not reset when spare not activated
Reviewed-by: dfuchs
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 29 new commits pushed to the master branch:
- 7169ee5c73c130aacce73cbd3f88377ec07c8311: 8293477: IGV: Upgrade to Netbeans Platform 15
- 3dd94f33b2dddf8ea28805499d110c2347476c19: 8292671: Hotspot Style Guide should allow covariant returns
- 9d6b0285f53599816c30393b87d16772ef6314b7: 8234315: GTK LAF does not gray out disabled JMenu
- 812d805a488597cb9ab6b375869bc6748fd7fa94: 6447816: Provider filtering (getProviders) is not working with OR'd conditions
- 43e191d64b0094cc1ece61929c32e017ee90c0c8: 8293524: RISC-V: Use macro-assembler functions as appropriate
- 14eb5ad0dc987ffe3621f4eeeebeb6b5a2cd691b: 8291753: Add JFR event for GC CPU Time
- 30d4145e2edd2d3e4cbaa8b01f7639ab53bc0991: 8293230: x86_64: Move AES and GHASH stub definitions into separate source files
- 4c5501c31c7ab8fa7d1a6ce479060a899514c671: 8293548: ProblemList sun/management/jmxremote/bootstrap/RmiBootstrapTest.java#id1 on linux-x64
- 46e6e41b9a35c8665eb31be2f8c36bbdcc90564a: 8293051: Further refactor javac after removal of -source/-target/--release 7
- c0ee30a25abda2f93806bbfaf940ba8638b864bf: 8293348: A false cyclic inheritance error reported
- ... and 19 more: https://git.openjdk.org/jdk/compare/1ee59adcfead2128316556121c1711d308c7ea01...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.
/integrate
Going to push as commit 68da02c7b536799ccca49e889c22f3e9a2691fb7.
Since your change was applied there have been 36 commits pushed to the master branch:
- 005b49bb78a468d4e372e6f5fa48bb0db4fd73c2: 8293044: C1: Missing access check on non-accessible class
- 91d00b3022b8bb59ce04fb5f214e3deb93590f46: 8288473: Remove unused frame::set_pc_preserve_deopt methods
- 45ff10cc68296c7c73d0eafe6fcc9946ab98267e: 8292695: SIGQUIT and jcmd attaching mechanism does not work with signal chaining library
- dbec22b84b0ffce447b43271e12ed7d0eed6c387: 8293287: add ReplayReduce flag
- b8598b02979dff8a947a523a6d76768a1bfe594b: 8291660: Grapheme support in BreakIterator
- a14c3a493a98792a61de253920bb177a5c35fd8e: 8288933: Improve the implementation of Double/Float.isInfinite
- 00befddd7ce97d324250807824469daaa9434eef: 8292675: Add identity transformation for removing redundant AndV/OrV nodes
- 7169ee5c73c130aacce73cbd3f88377ec07c8311: 8293477: IGV: Upgrade to Netbeans Platform 15
- 3dd94f33b2dddf8ea28805499d110c2347476c19: 8292671: Hotspot Style Guide should allow covariant returns
- 9d6b0285f53599816c30393b87d16772ef6314b7: 8234315: GTK LAF does not gray out disabled JMenu
- ... and 26 more: https://git.openjdk.org/jdk/compare/1ee59adcfead2128316556121c1711d308c7ea01...master
Your commit was automatically rebased without conflicts.
@AlanBateman Pushed as commit 68da02c7b536799ccca49e889c22f3e9a2691fb7.
:bulb: You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.