-
Notifications
You must be signed in to change notification settings - Fork 5.9k
8325372: Shenandoah: SIGSEGV crash in unnecessary_acquire due to LoadStore split through phi #17926
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
Conversation
👋 Welcome back roland! A progress list of the required criteria for merging this PR into |
@rwestrel 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.
I suggest we rename the bug to:
8325372: Shenandoah: SIGSEGV crash in unnecessary_acquire due to LoadStore split through phi
@@ -1734,11 +1734,26 @@ bool ShenandoahBarrierC2Support::identical_backtoback_ifs(Node* n, PhaseIdealLoo | |||
return true; | |||
} | |||
|
|||
bool ShenandoahBarrierC2Support::merge_point_safe(Node* region) { |
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 should probably be is_merge_point_safe
, since it answers bool
?
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's an existing merge_point_safe
method that validate merge points for split if (loopopts.cpp). That's why I named it like that.
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.
Ah, okay then!
test/hotspot/jtreg/gc/shenandoah/compiler/TestUnsafeLoadStoreMergedHeapStableTests.java
Outdated
Show resolved
Hide resolved
…ergedHeapStableTests.java Co-authored-by: Aleksey Shipilëv <shipilev@amazon.de>
@rwestrel 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 130 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 |
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, thank you!
Roman
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.
Shared code changes look good. Testing passed.
@shipilev @rkennke @TobiHartmann thanks for the reviews |
/integrate |
Going to push as commit 5d414da.
Your commit was automatically rebased without conflicts. |
After shenandoah barrier expansion, a shenandoah specific pass looks
for heap stable checks that are back to back:
and fuse them:
In the case of the failure, a
GetAndSetP
(orGetAndSetN
) node isbetween the 2 heap_stable checks. The fusion of the 2 tests is
implemented by taking advantage of the split if c2 optimization. But
split if doesn't support having a
GetAndSet
node at the region wheresplit if happens (that can only happen with shenandoah late barrier
expansion). That causes the
GetAndSet
node to lose itsSCMemProj
which can then result in the
GetAndSet
being entirely removed.The fix I propose is to not perform the heap_stable fusion in this
particular case.
/cc hotspot-compiler,shenandoah
Progress
Issue
Reviewers
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/17926/head:pull/17926
$ git checkout pull/17926
Update a local copy of the PR:
$ git checkout pull/17926
$ git pull https://git.openjdk.org/jdk.git pull/17926/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 17926
View PR using the GUI difftool:
$ git pr show -t 17926
Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/17926.diff
Webrev
Link to Webrev Comment