Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Only encode constness for items that may conditionally be const #103263

Closed

Conversation

compiler-errors
Copy link
Member

r? @ghost

@rustbot rustbot added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Oct 19, 2022
@compiler-errors
Copy link
Member Author

@bors try @rust-timer queue

@rust-timer
Copy link
Collaborator

Awaiting bors try build completion.

@rustbot label: +S-waiting-on-perf

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Oct 19, 2022
@bors
Copy link
Contributor

bors commented Oct 19, 2022

⌛ Trying commit 74ec77ea0f7bba8d2b17770b47c90b71b3b95456 with merge af025d85b7e1dcc7f8ff5741c8bc4a38c4da73b4...

@compiler-errors
Copy link
Member Author

@bors try @rust-timer queue

@rust-timer
Copy link
Collaborator

Awaiting bors try build completion.

@rustbot label: +S-waiting-on-perf

@bors
Copy link
Contributor

bors commented Oct 19, 2022

⌛ Trying commit f007d6a with merge 1d8b099c82d0eba87738a42bae5b62b488a69c30...

@bors
Copy link
Contributor

bors commented Oct 19, 2022

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

@rust-timer
Copy link
Collaborator

Queued 1d8b099c82d0eba87738a42bae5b62b488a69c30 with parent 4b8f431, future comparison URL.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (1d8b099c82d0eba87738a42bae5b62b488a69c30): 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-review -S-waiting-on-perf -perf-regression

Instruction count

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

Max RSS (memory usage)

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

Cycles

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

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-perf Status: Waiting on a perf run to be completed. labels Oct 19, 2022
@compiler-errors
Copy link
Member Author

@bors try @rust-timer queue

@rust-timer
Copy link
Collaborator

Awaiting bors try build completion.

@rustbot label: +S-waiting-on-perf

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Oct 19, 2022
@bors
Copy link
Contributor

bors commented Oct 19, 2022

⌛ Trying commit 0aa06c975b083fda15d98d5a01742c395fd3109c with merge 963ee0810ed9817ccaa498ac104fd535c1897a3d...

@compiler-errors
Copy link
Member Author

@bors try @rust-timer queue

@rust-timer
Copy link
Collaborator

Awaiting bors try build completion.

@rustbot label: +S-waiting-on-perf

@bors
Copy link
Contributor

bors commented Oct 20, 2022

⌛ Trying commit 6868a10 with merge f44a2646472c3d9b34077e4f006df9f6ef0fa6d7...

@rust-log-analyzer
Copy link
Collaborator

The job dist-x86_64-linux failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
   Compiling rustc_query_impl v0.0.0 (/checkout/compiler/rustc_query_impl)
   Compiling rustc_passes v0.0.0 (/checkout/compiler/rustc_passes)
   Compiling rustc_monomorphize v0.0.0 (/checkout/compiler/rustc_monomorphize)
   Compiling rustc_save_analysis v0.0.0 (/checkout/compiler/rustc_save_analysis)
error[E0004]: non-exhaustive patterns: `rustc_hir::def::DefKind::Trait` and `rustc_hir::def::DefKind::AssocTy` not covered
    --> compiler/rustc_metadata/src/rmeta/encoder.rs:1063:11
1063 |     match def_kind {
1063 |     match def_kind {
     |           ^^^^^^^^ patterns `rustc_hir::def::DefKind::Trait` and `rustc_hir::def::DefKind::AssocTy` not covered
note: `rustc_hir::def::DefKind` defined here
     = note: the matched value is of type `rustc_hir::def::DefKind`
     = note: the matched value is of type `rustc_hir::def::DefKind`
help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern, a match arm with multiple or-patterns as shown, or multiple match arms
1094 ~         | DefKind::InlineConst => false,
1094 ~         | DefKind::InlineConst => false,
1095 ~         rustc_hir::def::DefKind::Trait | rustc_hir::def::DefKind::AssocTy => todo!(),

For more information about this error, try `rustc --explain E0004`.
[RUSTC-TIMING] rustc_metadata test:false 1.788
error: could not compile `rustc_metadata` due to previous error

@bors
Copy link
Contributor

bors commented Oct 20, 2022

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

@rust-timer
Copy link
Collaborator

Queued f44a2646472c3d9b34077e4f006df9f6ef0fa6d7 with parent 57781b2, future comparison URL.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (f44a2646472c3d9b34077e4f006df9f6ef0fa6d7): comparison URL.

Overall result: ✅ improvements - 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-review -S-waiting-on-perf -perf-regression

Instruction count

This is a highly reliable metric that was used to determine the overall result at the top of this comment.

mean1 range count2
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.6% [-1.1%, -0.1%] 7
All ❌✅ (primary) - - 0

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.

mean1 range count2
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-1.7% [-1.7%, -1.7%] 1
Improvements ✅
(secondary)
-4.3% [-4.3%, -4.3%] 1
All ❌✅ (primary) -1.7% [-1.7%, -1.7%] 1

Cycles

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

Footnotes

  1. the arithmetic mean of the percent change 2

  2. number of relevant changes 2

@rustbot rustbot removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Oct 20, 2022
bors added a commit to rust-lang-ci/rust that referenced this pull request Oct 26, 2022
Revert "Unify tcx.constness and param env constness checks"

Too much of a perf regression rust-lang#102975 (comment), and an attempt in rust-lang#103263 didn't fix it except for just a tiny bit.

This change isn't really needed (see rust-lang#102830 (comment)), so this should be an easy revert.
@compiler-errors compiler-errors deleted the conditional-const branch November 2, 2022 02:53
Aaron1011 pushed a commit to Aaron1011/rust that referenced this pull request Jan 6, 2023
Revert "Unify tcx.constness and param env constness checks"

Too much of a perf regression rust-lang#102975 (comment), and an attempt in rust-lang#103263 didn't fix it except for just a tiny bit.

This change isn't really needed (see rust-lang#102830 (comment)), so this should be an easy revert.
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.

None yet

5 participants