Skip to content

early_otherwise: Don't hoist dereferences when the otherwise branch is reachable#159608

Open
dianqk wants to merge 2 commits into
rust-lang:mainfrom
dianqk:hoist-in-early-else
Open

early_otherwise: Don't hoist dereferences when the otherwise branch is reachable#159608
dianqk wants to merge 2 commits into
rust-lang:mainfrom
dianqk:hoist-in-early-else

Conversation

@dianqk

@dianqk dianqk commented Jul 20, 2026

Copy link
Copy Markdown
Member

Fixes #159591.

A place may contain a dereference that cannot be safely hoisted when the otherwise branch is reachable.

@rustbot

rustbot commented Jul 20, 2026

Copy link
Copy Markdown
Collaborator

Some changes occurred to MIR optimizations

cc @rust-lang/wg-mir-opt

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Jul 20, 2026
@rustbot

rustbot commented Jul 20, 2026

Copy link
Copy Markdown
Collaborator

r? @davidtwco

rustbot has assigned @davidtwco.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: compiler, mir, mir-opt
  • compiler, mir, mir-opt expanded to 74 candidates
  • Random selection from 18 candidates

@dianqk
dianqk force-pushed the hoist-in-early-else branch from 39dd171 to a22fed7 Compare July 20, 2026 15:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Optimization introduces a pointer dereference on unreachable path

3 participants