-
Notifications
You must be signed in to change notification settings - Fork 356
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
ICE when dealloc causes Stacked Borrows error #2693
Comments
I feel like |
Special-casing |
Yeah, some of our 'access' mean 'do all the things we would do for a memory access, as a way to enforce some aliasing property', and some mean 'an actual load/store'. But the codebase was already confused about that before, #2694 (which makes |
So yes I agree that #2694 is good enough with the somewhat-confused status of our naming. |
fix handling of spurious accesses during retag The `dereferenceable` attribute we emit for LLVM is checked during retag in Stacked Borrows. However, we currently don't properly do that for retagging of `&mut !Unpin`, which this PR fixes. Also this adjusts retagging to inform the data race model of the accesses as well. Fixes rust-lang/miri#2648. Also fixes rust-lang/miri#2693 since the same issue arose for retagging as well. r? `@saethlin`
I realized we don't have a test hitting this, and indeed trying to do so currently ICEs:
produces
The trouble is here:
miri/src/stacked_borrows/mod.rs
Lines 477 to 480 in 2f92cf2
We try to use
map_err
to make this a deallocation error, but when that happensaccess
has already calleddcx.access_error
, causing the ICE. (The ICE is a regression introduced by #2684.)@saethlin any idea how to best fix this?
The text was updated successfully, but these errors were encountered: