2

Don't store lazyness in `DefKind::TyAlias` by compiler-errors · Pull Request #11...

 11 months ago
source link: https://github.com/rust-lang/rust/pull/116163
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

Don't store lazyness in DefKind::TyAlias #116163

Conversation

  1. Don't store lazyness of a type alias in its DefKind, but instead via a query.
  2. This allows us to treat type aliases as lazy if #[feature(lazy_type_alias)] OR if the alias contains a TAIT, rather than having checks for both in separate parts of the codebase.

r? @oli-obk cc @fmease

fmease reacted with thumbs up emojifmease reacted with heart emoji

rustbot

added A-query-system Area: The rustc query system (https://rustc-dev-guide.rust-lang.org/query.html) 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. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative

labels

Sep 26, 2023

Collaborator

Some changes occurred to the core trait solver

cc @rust-lang/initiative-trait-system-refactor

Some changes occurred in need_type_info.rs

cc @lcnr

Some changes might have occurred in exhaustiveness checking

cc @Nadrieril

Some changes occurred in src/tools/clippy

cc @rust-lang/clippy

This comment has been minimized.

rustbot

added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label

Sep 26, 2023

Contributor

⌛ Trying commit 88ef3a2 with merge a4bf23b...

This comment has been minimized.

Collaborator

Some changes occurred in need_type_info.rs

cc @lcnr

Some changes might have occurred in exhaustiveness checking

cc @Nadrieril

Some changes occurred in src/tools/clippy

cc @rust-lang/clippy

Some changes occurred to the core trait solver

cc @rust-lang/initiative-trait-system-refactor

// compile-flags: --crate-type=lib

// check-pass

We no longer call type_of in variance computation on type aliases to determine if it's a TAIT, since we go through the type_alias_is_lazy query operating on HIR.

fmease reacted with thumbs up emoji

Member

Author

@bors try

Contributor

⌛ Trying commit d6ce9ce with merge b3abcff...

Contributor

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

This comment has been minimized.

Collaborator

Finished benchmarking commit (b3abcff): 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

Cycles

Results

Binary size

Results

Bootstrap: 631.966s -> 631.546s (-0.07%)
Artifact size: 317.23 MiB -> 317.15 MiB (-0.03%)

compiler-errors reacted with heart emoji

rustbot

removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label

Sep 26, 2023

Contributor

@bors r+ rollup-

Contributor

📌 Commit d6ce9ce has been approved by oli-obk

It is now in the queue for this repository.

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

Sep 26, 2023

Contributor

⌛ Testing commit d6ce9ce with merge 6b99cf1...

Contributor

☀️ Test successful - checks-actions
Approved by: oli-obk
Pushing 6b99cf1 to master...

bors

added the merged-by-bors This PR was explicitly merged by bors label

Sep 27, 2023

bors

merged commit 6b99cf1 into

rust-lang:master

Sep 27, 2023

12 checks passed

Collaborator

Finished benchmarking commit (6b99cf1): 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

Cycles

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

Binary size

Results

Bootstrap: 630.538s -> 629.316s (-0.19%)
Artifact size: 317.11 MiB -> 317.14 MiB (0.01%)

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

Reviewers

No reviews

Assignees

oli-obk

Labels
A-query-system Area: The rustc query system (https://rustc-dev-guide.rust-lang.org/query.html) 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. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative
Projects

None yet

Milestone

1.74.0

Development

Successfully merging this pull request may close these issues.

None yet

6 participants

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK