Skip to content

Reuse the MIR validator for MIR inlining#113853

Merged
bors merged 3 commits into
rust-lang:masterfrom
cjgillot:split-validator
Jul 22, 2023
Merged

Reuse the MIR validator for MIR inlining#113853
bors merged 3 commits into
rust-lang:masterfrom
cjgillot:split-validator

Conversation

@cjgillot

@cjgillot cjgillot commented Jul 19, 2023

Copy link
Copy Markdown
Contributor

Instead of having the inliner home-cook its own validation, we just check that the substituted MIR body passes the regular validation.

The MIR validation is first split in two: control flow validation (MIR syntax and CFG invariants) and type validation (subtyping relationship in assignments and projections). Only the latter can be affected by instantiating type parameters.

@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 19, 2023
@cjgillot

Copy link
Copy Markdown
Contributor Author

@bors try @rust-timer queue

@rust-timer

This comment has been minimized.

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jul 19, 2023
@bors

bors commented Jul 19, 2023

Copy link
Copy Markdown
Collaborator

⌛ Trying commit 2e17ca70bd9fff4d0c55926699090ea08cb01388 with merge e986ec863e45a06422e2c807115069afae8dff08...

@bors

bors commented Jul 19, 2023

Copy link
Copy Markdown
Collaborator

☀️ Try build successful - checks-actions
Build commit: e986ec863e45a06422e2c807115069afae8dff08 (e986ec863e45a06422e2c807115069afae8dff08)

@rust-timer

This comment has been minimized.

@rust-timer

Copy link
Copy Markdown
Collaborator

Finished benchmarking commit (e986ec863e45a06422e2c807115069afae8dff08): comparison URL.

Overall result: no relevant changes - no action needed

Benchmarking this pull request likely means that it is perf-sensitive, so we're automatically marking it as not fit for rolling up. While you can manually mark this PR as fit for rollup, we strongly recommend not doing so since this PR may lead to changes in compiler perf.

@bors rollup=never
@rustbot label: -S-waiting-on-perf -perf-regression

Instruction count

This benchmark run did not return any relevant results for this metric.

Max RSS (memory usage)

Results

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

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

Cycles

Results

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-4.7% [-5.2%, -4.4%] 3
All ❌✅ (primary) - - 0

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 647.294s -> 648.277s (0.15%)

@rustbot rustbot removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jul 19, 2023
@cjgillot cjgillot marked this pull request as ready for review July 19, 2023 16:22
@rustbot

rustbot commented Jul 19, 2023

Copy link
Copy Markdown
Collaborator

Some changes occurred to MIR optimizations

cc @rust-lang/wg-mir-opt

@cjgillot

Copy link
Copy Markdown
Contributor Author

r? @compiler-errors
This is a more principled version of #113802

@cjgillot cjgillot added the A-mir-opt Area: MIR optimizations label Jul 21, 2023
@compiler-errors

This comment was marked as off-topic.

@bors

This comment was marked as off-topic.

@bors bors 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 Jul 22, 2023
@compiler-errors

This comment was marked as off-topic.

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Jul 22, 2023
@compiler-errors

This comment was marked as off-topic.

@compiler-errors

Copy link
Copy Markdown
Contributor

@bors r+ rollup=never

@bors

bors commented Jul 22, 2023

Copy link
Copy Markdown
Collaborator

📌 Commit b6cd700 has been approved by compiler-errors

It is now in the queue for this repository.

@bors bors 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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jul 22, 2023
@bors

bors commented Jul 22, 2023

Copy link
Copy Markdown
Collaborator

⌛ Testing commit b6cd700 with merge c399954...

@bors

bors commented Jul 22, 2023

Copy link
Copy Markdown
Collaborator

☀️ Test successful - checks-actions
Approved by: compiler-errors
Pushing c399954 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jul 22, 2023
@bors bors merged commit c399954 into rust-lang:master Jul 22, 2023
@rustbot rustbot added this to the 1.73.0 milestone Jul 22, 2023
@cjgillot cjgillot deleted the split-validator branch July 22, 2023 21:16
@rust-timer

Copy link
Copy Markdown
Collaborator

Finished benchmarking commit (c399954): comparison URL.

Overall result: no relevant changes - no action needed

@rustbot label: -perf-regression

Instruction count

This benchmark run did not return any relevant results for this metric.

Max RSS (memory usage)

Results

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

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

Cycles

This benchmark run did not return any relevant results for this metric.

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 651.513s -> 651.103s (-0.06%)

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

Labels

A-mir-opt Area: MIR optimizations merged-by-bors This PR was explicitly merged by bors. 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.

5 participants