-
Notifications
You must be signed in to change notification settings - Fork 341
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
Miri detects UB (SB error) when setting a thread name #1957
Comments
I vaguely remember a previous issue where pointer -> int casts tripped up stacked borrows when used in a syscall like that. I'd need to go find it, but IIRC the (proposed, i don't think tested) solution was to transmute if |
Yeah, the Int-to-ptr casts do not work with |
Wow that's awkward. So we're backed into a corner here by the combination of this miri peculiarity and the signature of this libc function, because it is trying to be generic. Is this something better fixed in miri? |
It seems at least better to track this in Miri, so I moved the issue. |
Actually, we already have this issue on the Miri side: #1717 |
I tried this code:
MIRIFLAGS="-Zmiri-tag-raw-pointers" cargo miri run
I expected to see this happen: Nothing
Instead, this happened: Miri is upset 😢
I truly have no idea what's going on here. I've tried a number of things with moving data or pointers to data into threads, and none of them can trip up the Stacked Borrows tracking. cc @RalfJung ?
The text was updated successfully, but these errors were encountered: