Fix coroutine MIR saved local remapping#158655
Conversation
|
Some changes occurred to MIR optimizations cc @rust-lang/wg-mir-opt |
|
r? @TaKO8Ki rustbot has assigned @TaKO8Ki. Use Why was this reviewer chosen?The reviewer was selected based on:
|
|
r? cjgillot who probably has more context |
f809a69 to
fd23727
Compare
|
@rustbot ready |
Signed-off-by: Xiangfei Ding <dingxiangfei2009@protonmail.ch>
fd23727 to
aa485b2
Compare
|
This PR was rebased onto a different main 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.
aa485b2 to
bb63725
Compare
This comment has been minimized.
This comment has been minimized.
bb63725 to
81a734f
Compare
Storage is still required even if the local is moved out and immediately moved in again. Signed-off-by: Xiangfei Ding <dingxiangfei2009@protonmail.ch>
81a734f to
401dc21
Compare
|
@rustbot ready |
|
@cjgillot Thank you for your review! I have applied the suggestions. Let me know any other outstanding concerns. Cheers! |
|
Great ! |
…cjgillot Fix coroutine MIR saved local remapping The unsound analysis was found while I was working on the `async-drop` code. Apparently the counter variable in the array drop glue is not correctly identified as a saved local. Also we did not patch up indices in `ProjectionElem::Index` when they are saved locals. The reproduction is in the older commit with the expected output.
Rollup of 8 pull requests Successful merges: - #158541 (Move `std::io::Write` to `core::io`) - #150946 (intrinsics: Add a fallback for non-const libm float functions) - #158655 (Fix coroutine MIR saved local remapping) - #158920 (Update wasm-component-ld to 0.5.26) - #158926 (wrapping_sh* methods: clarify underspecified reference) - #151379 (Stabilize `VecDeque::retain_back` from `truncate_front`) - #158913 (Update `browser-ui-test` version to `0.24.1`) - #158935 (std: support real fd methods on Emscripten)
Rollup of 8 pull requests Successful merges: - #158541 (Move `std::io::Write` to `core::io`) - #150946 (intrinsics: Add a fallback for non-const libm float functions) - #158655 (Fix coroutine MIR saved local remapping) - #158920 (Update wasm-component-ld to 0.5.26) - #158926 (wrapping_sh* methods: clarify underspecified reference) - #151379 (Stabilize `VecDeque::retain_back` from `truncate_front`) - #158913 (Update `browser-ui-test` version to `0.24.1`) - #158935 (std: support real fd methods on Emscripten)
…cjgillot Fix coroutine MIR saved local remapping The unsound analysis was found while I was working on the `async-drop` code. Apparently the counter variable in the array drop glue is not correctly identified as a saved local. Also we did not patch up indices in `ProjectionElem::Index` when they are saved locals. The reproduction is in the older commit with the expected output.
…cjgillot Fix coroutine MIR saved local remapping The unsound analysis was found while I was working on the `async-drop` code. Apparently the counter variable in the array drop glue is not correctly identified as a saved local. Also we did not patch up indices in `ProjectionElem::Index` when they are saved locals. The reproduction is in the older commit with the expected output.
…cjgillot Fix coroutine MIR saved local remapping The unsound analysis was found while I was working on the `async-drop` code. Apparently the counter variable in the array drop glue is not correctly identified as a saved local. Also we did not patch up indices in `ProjectionElem::Index` when they are saved locals. The reproduction is in the older commit with the expected output.
…uwer Rollup of 18 pull requests Successful merges: - #158871 (add relnotes for 1.97.0) - #150946 (intrinsics: Add a fallback for non-const libm float functions) - #158617 (allow mGCA const arguments to fall back to anon consts) - #158645 (Fix splat ICEs and ban it in closures) - #158655 (Fix coroutine MIR saved local remapping) - #158666 (Carry the `b_offset` inside `BackendRepr::ScalarPair`) - #158920 (Update wasm-component-ld to 0.5.26) - #158926 (wrapping_sh* methods: clarify underspecified reference) - #158927 (add core test run with `-Zforce-intrinsic-fallback`) - #151379 (Stabilize `VecDeque::retain_back` from `truncate_front`) - #158807 (Add regression test for CString::clone_into unwind safety) - #158862 (Fix the span for parameter suggestion ) - #158883 (tests: fix enum-match.rs to handle LLVM 23) - #158894 (Make the ordering of non-terminal binds in ambiguity error messages deterministic) - #158902 (add codegen test for range length bound propagation) - #158913 (Update `browser-ui-test` version to `0.24.1`) - #158935 (std: support real fd methods on Emscripten) - #158951 (Merge three `MaxUniverse`s into one)
…uwer Rollup of 18 pull requests Successful merges: - #158871 (add relnotes for 1.97.0) - #150946 (intrinsics: Add a fallback for non-const libm float functions) - #158617 (allow mGCA const arguments to fall back to anon consts) - #158645 (Fix splat ICEs and ban it in closures) - #158655 (Fix coroutine MIR saved local remapping) - #158666 (Carry the `b_offset` inside `BackendRepr::ScalarPair`) - #158920 (Update wasm-component-ld to 0.5.26) - #158926 (wrapping_sh* methods: clarify underspecified reference) - #158927 (add core test run with `-Zforce-intrinsic-fallback`) - #151379 (Stabilize `VecDeque::retain_back` from `truncate_front`) - #158807 (Add regression test for CString::clone_into unwind safety) - #158862 (Fix the span for parameter suggestion ) - #158883 (tests: fix enum-match.rs to handle LLVM 23) - #158894 (Make the ordering of non-terminal binds in ambiguity error messages deterministic) - #158902 (add codegen test for range length bound propagation) - #158913 (Update `browser-ui-test` version to `0.24.1`) - #158935 (std: support real fd methods on Emscripten) - #158951 (Merge three `MaxUniverse`s into one)
…uwer Rollup of 18 pull requests Successful merges: - #158871 (add relnotes for 1.97.0) - #150946 (intrinsics: Add a fallback for non-const libm float functions) - #158617 (allow mGCA const arguments to fall back to anon consts) - #158645 (Fix splat ICEs and ban it in closures) - #158655 (Fix coroutine MIR saved local remapping) - #158666 (Carry the `b_offset` inside `BackendRepr::ScalarPair`) - #158920 (Update wasm-component-ld to 0.5.26) - #158926 (wrapping_sh* methods: clarify underspecified reference) - #158927 (add core test run with `-Zforce-intrinsic-fallback`) - #151379 (Stabilize `VecDeque::retain_back` from `truncate_front`) - #158807 (Add regression test for CString::clone_into unwind safety) - #158862 (Fix the span for parameter suggestion ) - #158883 (tests: fix enum-match.rs to handle LLVM 23) - #158894 (Make the ordering of non-terminal binds in ambiguity error messages deterministic) - #158902 (add codegen test for range length bound propagation) - #158913 (Update `browser-ui-test` version to `0.24.1`) - #158935 (std: support real fd methods on Emscripten) - #158951 (Merge three `MaxUniverse`s into one)
…cjgillot Fix coroutine MIR saved local remapping The unsound analysis was found while I was working on the `async-drop` code. Apparently the counter variable in the array drop glue is not correctly identified as a saved local. Also we did not patch up indices in `ProjectionElem::Index` when they are saved locals. The reproduction is in the older commit with the expected output.
…cjgillot Fix coroutine MIR saved local remapping The unsound analysis was found while I was working on the `async-drop` code. Apparently the counter variable in the array drop glue is not correctly identified as a saved local. Also we did not patch up indices in `ProjectionElem::Index` when they are saved locals. The reproduction is in the older commit with the expected output.
…uwer Rollup of 25 pull requests Successful merges: - #158871 (add relnotes for 1.97.0) - #158968 (stdarch subtree update) - #154445 (rustdoc: Represent `--output-format=json` coverage and ir differently) - #156370 (Reject linked dylib EII default overrides) - #157153 (allow `Allocator`s to be used as `#[global_allocator]`s) - #158495 (Rename HAS_CT_PROJECTION to HAS_CONST_ALIAS) - #158617 (allow mGCA const arguments to fall back to anon consts) - #158645 (Fix splat ICEs and ban it in closures) - #158655 (Fix coroutine MIR saved local remapping) - #158666 (Carry the `b_offset` inside `BackendRepr::ScalarPair`) - #158912 (Introduce new bootstrap config section for PGO configuration) - #158920 (Update wasm-component-ld to 0.5.26) - #158926 (wrapping_sh* methods: clarify underspecified reference) - #158927 (add core test run with `-Zforce-intrinsic-fallback`) - #158932 (Do not build the compiler when invoking `x perf compare`) - #158937 (Emit the emscripten entry point as `__main_argc_argv`) - #151379 (Stabilize `VecDeque::retain_back` from `truncate_front`) - #156548 ( Library support for aarch64-unknown-linux-pauthtest target) - #158307 (CI job for parallel frontend ui tests) - #158347 (Improve generic parameters handling for #[diagnostic::on_const]) - #158722 (delegation: do not always inherit `ConstArgHasType` predicates) - #158741 (Simplify `Option::into_flat_iter` signature) - #158807 (Add regression test for CString::clone_into unwind safety) - #158862 (Fix the span for parameter suggestion ) - #158883 (tests: fix enum-match.rs to handle LLVM 23)
…cjgillot Fix coroutine MIR saved local remapping The unsound analysis was found while I was working on the `async-drop` code. Apparently the counter variable in the array drop glue is not correctly identified as a saved local. Also we did not patch up indices in `ProjectionElem::Index` when they are saved locals. The reproduction is in the older commit with the expected output.
Rollup of 25 pull requests Successful merges: - #158871 (add relnotes for 1.97.0) - #158968 (stdarch subtree update) - #157690 (codegen_ssa: pack small const aggregates into immediate stores) - #158541 (Move `std::io::Write` to `core::io`) - #154445 (rustdoc: Represent `--output-format=json` coverage and ir differently) - #156370 (Reject linked dylib EII default overrides) - #157153 (allow `Allocator`s to be used as `#[global_allocator]`s) - #158495 (Rename HAS_CT_PROJECTION to HAS_CONST_ALIAS) - #158617 (allow mGCA const arguments to fall back to anon consts) - #158645 (Fix splat ICEs and ban it in closures) - #158655 (Fix coroutine MIR saved local remapping) - #158666 (Carry the `b_offset` inside `BackendRepr::ScalarPair`) - #158870 (std: merge the unix-like io::error modules into one file) - #158920 (Update wasm-component-ld to 0.5.26) - #158926 (wrapping_sh* methods: clarify underspecified reference) - #158927 (add core test run with `-Zforce-intrinsic-fallback`) - #158932 (Do not build the compiler when invoking `x perf compare`) - #158937 (Emit the emscripten entry point as `__main_argc_argv`) - #151379 (Stabilize `VecDeque::retain_back` from `truncate_front`) - #156144 (Better docs for PartialEq (includes macro rename)) - #156548 ( Library support for aarch64-unknown-linux-pauthtest target) - #158307 (CI job for parallel frontend ui tests) - #158347 (Improve generic parameters handling for #[diagnostic::on_const]) - #158722 (delegation: do not always inherit `ConstArgHasType` predicates) - #158741 (Simplify `Option::into_flat_iter` signature)
|
I think this may be the cause of #158986 (comment), but I'm not certain. @bors try jobs=aarch64-gnu-debug @bors r- |
This comment has been minimized.
This comment has been minimized.
Fix coroutine MIR saved local remapping try-job: aarch64-gnu-debug
|
This pull request was unapproved. This PR was contained in a rollup (#158986), which was unapproved. |
View all comments
The unsound analysis was found while I was working on the
async-dropcode. Apparently the counter variable in the array drop glue is not correctly identified as a saved local.Also we did not patch up indices in
ProjectionElem::Indexwhen they are saved locals.The reproduction is in the older commit with the expected output.