-
Notifications
You must be signed in to change notification settings - Fork 13.8k
Lint more overlapping assignments in MIR. #146566
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
Some changes occurred to MIR optimizations cc @rust-lang/wg-mir-opt |
@bors r+ rollup -Zlint-mir is off by default so this shouldn't be capable of causing perf impacts. |
Lint more overlapping assignments in MIR. In an effort to make bugs like rust-lang#146383 more easily discovered, this PR extends the "overlapping assignment" MIR lint. I had to whitelist some rvalues, as they are actually allowed to alias, like `a = a + 1`.
acf0615
to
cc83892
Compare
This PR was rebased onto a different master commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
This comment has been minimized.
This comment has been minimized.
cc83892
to
912785d
Compare
I think this is in the clear now? @bors r+ |
Rollup of 5 pull requests Successful merges: - #146566 (Lint more overlapping assignments in MIR.) - #146645 (Cleanup `FnDecl::inner_full_print`) - #146664 (Clean up `ty::Dynamic`) - #146673 (cg_llvm: Replace some DIBuilder wrappers with LLVM-C API bindings (part 4)) - #146694 (Remove ImplSubject) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of #146566 - cjgillot:mir-overlap-lint, r=saethlin Lint more overlapping assignments in MIR. In an effort to make bugs like #146383 more easily discovered, this PR extends the "overlapping assignment" MIR lint. I had to whitelist some rvalues, as they are actually allowed to alias, like `a = a + 1`.
@rust-timer build a7976cf Perf. run for #146698. |
This comment has been minimized.
This comment has been minimized.
Finished benchmarking commit (a7976cf): comparison URL. Overall result: ❌✅ regressions and improvements - no action neededBenchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf. @bors rollup=never Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (secondary 4.8%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (secondary -0.5%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeResults (secondary -0.0%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Bootstrap: 471.663s -> 470.424s (-0.26%) |
In an effort to make bugs like #146383 more easily discovered, this PR extends the "overlapping assignment" MIR lint.
I had to whitelist some rvalues, as they are actually allowed to alias, like
a = a + 1
.