Skip to content

Couple of cleanups and optimizations around MIR encoding#152096

Open
bjorn3 wants to merge 3 commits intorust-lang:mainfrom
bjorn3:mir_encoding_cleanups
Open

Couple of cleanups and optimizations around MIR encoding#152096
bjorn3 wants to merge 3 commits intorust-lang:mainfrom
bjorn3:mir_encoding_cleanups

Conversation

@bjorn3
Copy link
Member

@bjorn3 bjorn3 commented Feb 4, 2026

No description provided.

@rustbot
Copy link
Collaborator

rustbot commented Feb 4, 2026

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 Feb 4, 2026
@rustbot
Copy link
Collaborator

rustbot commented Feb 4, 2026

r? @BoxyUwU

rustbot has assigned @BoxyUwU.
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

@bjorn3
Copy link
Member Author

bjorn3 commented Feb 4, 2026

@bors try @rust-timer queue

@rust-timer

This comment has been minimized.

@rust-bors

This comment has been minimized.

rust-bors bot pushed a commit that referenced this pull request Feb 4, 2026
Couple of cleanups and optimizations around MIR encoding
@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Feb 4, 2026
Copy link
Contributor

@oli-obk oli-obk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

r=me with perf happy

r? oli-obk

View changes since this review

@rustbot rustbot assigned oli-obk and unassigned BoxyUwU Feb 4, 2026
@rust-bors

This comment has been minimized.

@rust-bors
Copy link
Contributor

rust-bors bot commented Feb 4, 2026

☀️ Try build successful (CI)
Build commit: 9b86a67 (9b86a6753da5ada177cf50d80831a569b0834671, parent: 794495e2b4a1353cf7b66ffc55f0e755490af2cc)

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (9b86a67): comparison URL.

Overall result: ✅ improvements - no action needed

Benchmarking 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
@rustbot label: -S-waiting-on-perf -perf-regression

Instruction count

Our most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-0.2% [-0.2%, -0.2%] 1
Improvements ✅
(secondary)
-0.2% [-0.4%, -0.1%] 4
All ❌✅ (primary) -0.2% [-0.2%, -0.2%] 1

Max RSS (memory usage)

Results (primary -3.0%, secondary 4.1%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
4.1% [4.1%, 4.1%] 1
Improvements ✅
(primary)
-3.0% [-3.0%, -3.0%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) -3.0% [-3.0%, -3.0%] 1

Cycles

Results (secondary 2.9%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
5.6% [4.7%, 6.4%] 2
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-2.6% [-2.6%, -2.6%] 1
All ❌✅ (primary) - - 0

Binary size

Results (primary -0.2%, secondary -0.5%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-0.2% [-0.5%, -0.0%] 39
Improvements ✅
(secondary)
-0.5% [-1.5%, -0.0%] 39
All ❌✅ (primary) -0.2% [-0.5%, -0.0%] 39

Bootstrap: 475.808s -> 471.843s (-0.83%)
Artifact size: 398.08 MiB -> 398.07 MiB (-0.00%)

@rustbot rustbot removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Feb 4, 2026
It isn't called anywhere anymore.
@bjorn3 bjorn3 force-pushed the mir_encoding_cleanups branch from 5b63d3f to d1891b8 Compare February 4, 2026 15:58
@rustbot
Copy link
Collaborator

rustbot commented Feb 4, 2026

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.

We only use mir_for_ctfe for them anyway in instance_mir. This does
prevent MIR inlining of constructor calls, but constructor calls that
are inlinable during MIR optimizations are rare anyway given that MIR
building already inlines all direct calls to constructors.
@bjorn3 bjorn3 force-pushed the mir_encoding_cleanups branch from d1891b8 to 05921d4 Compare February 4, 2026 16:01
@bjorn3
Copy link
Member Author

bjorn3 commented Feb 4, 2026

@bors r=oli-obk

@rust-bors
Copy link
Contributor

rust-bors bot commented Feb 4, 2026

📌 Commit 05921d4 has been approved by oli-obk

It is now in the queue for this repository.

@rust-bors rust-bors bot added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Feb 4, 2026
@rust-bors
Copy link
Contributor

rust-bors bot commented Feb 5, 2026

⌛ Testing commit 05921d4 with merge 7596c04...

Workflow: https://github.com/rust-lang/rust/actions/runs/21702427957

rust-bors bot pushed a commit that referenced this pull request Feb 5, 2026
Couple of cleanups and optimizations around MIR encoding
@JonathanBrouwer
Copy link
Contributor

@bors yield
Letting the rollup with two flaky test fixes go first

@rust-bors
Copy link
Contributor

rust-bors bot commented Feb 5, 2026

Auto build cancelled. Cancelled workflows:

The next pull request likely to be tested is #152156.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. 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.

7 participants