-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
Miscompilation of libcore with -Zmir-opt-level=3 #108166
Comments
Try adding Turning off |
Correctly handle aggregates in DataflowConstProp The previous implementation from rust-lang#107411 flooded target of an aggregate assignment with `Bottom`, corresponding to the `deinit` that the interpreter does. As a consequence, when assigning `target = Enum::Variant#i(...)` all the `(target as Variant#j)` were at `Bottom` while they should have been `Top`. This PR replaces that flooding with `Top`. Aside, it corrects a second bug where the wrong place would be used to assign to enum variant fields, resulting to nothing happening. Fixes rust-lang#108166
I can confirm the miscompilation is now fixed. |
Compile the standard library with -Zmir-opt-level=3 and then running libcore's test suite with this version of the standard library results in several tests failing. I am seeing this on cg_clif's CI (https://github.com/bjorn3/rustc_codegen_cranelift/actions/runs/4203400456/jobs/7292743420) but I expect it to be reproducible using LLVM too.
Meta
Last known good version:
rustc 1.69.0-nightly (065852def 2023-02-13)
First known bad version:
Regression range: 065852d...9a7cc6c
#107449 stands out as a changed MIR opt.
The text was updated successfully, but these errors were encountered: