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
8260497: Shenandoah: Improve SATB flushing #2254
Conversation
👋 Welcome back rkennke! A progress list of the required criteria for merging this PR into |
|
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 nice. Although you want to fix some of the build falures: https://github.com/rkennke/jdk/runs/1776231024?check_suite_focus=true
@rkennke 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 3 new commits pushed to the
Please see this link for an up-to-date comparison between the source branch of this pull request and the ➡️ To integrate this PR with the above commit message to the |
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!
/integrate |
@rkennke Since your change was applied there have been 16 commits pushed to the
Your commit was automatically rebased without conflicts. Pushed as commit 316d52c. 💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored. |
Currently, we periodically force flushing of SATB queues. This works by activating a flag every 100ms in every thread, which causes that thread to enqueue its SATB buffer the next time it overflows, even if it doesn't meet its threshold after filtering. This is somewhat problematic when a thread does not actually overflow its SATB queue in time. The whole point of the exercise is to try and avoid having too much left-over work when we reach final-mark.
We can do better than that: when concurrent mark is done we can handshake all threads, and let them flush their respective SATB queues, and re-enter concurrent mark loop again, until flushing yields no more work. Experiments show that it usually takes 1-3 flushes to clean out leftover work properly.
I ran benchmarks, 3 high-pressure preset runs of SPECjbb2015, 10 minutes each:
It reliably lowers all timings for finish-mark. It also doesn't cause any regressions in throughput.
Testing:
Progress
Issue
Reviewers
Download
$ git fetch https://git.openjdk.java.net/jdk pull/2254/head:pull/2254
$ git checkout pull/2254