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

Make compare_impl_item into a query #133365

Merged
merged 2 commits into from
Dec 1, 2024

Conversation

compiler-errors
Copy link
Member

@compiler-errors compiler-errors commented Nov 23, 2024

Turns compare_impl_item into a query (generalizing the existing query for compare_impl_const), and uses that in Instance::resolve to fail resolution when an implementation is incompatible with the trait it comes from.

Fixes #119701
Fixes #121127
Fixes #121411
Fixes #129075
Fixes #129127
Fixes #129214
Fixes #131294

@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 Nov 23, 2024
@compiler-errors
Copy link
Member 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 Nov 23, 2024
@bors
Copy link
Contributor

bors commented Nov 23, 2024

⌛ Trying commit c7ca253 with merge 507b0fd...

bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 23, 2024
…=<try>

Make `compare_impl_item` into a query

First want to perf, then I'll write something up.

r? `@ghost`
@rust-log-analyzer

This comment has been minimized.

@bors
Copy link
Contributor

bors commented Nov 23, 2024

☀️ Try build successful - checks-actions
Build commit: 507b0fd (507b0fdc53b493f2fe2f88a18d7b1f00914beafe)

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (507b0fd): comparison URL.

Overall result: ❌ regressions - please read the text below

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.

Next Steps: If you can justify the regressions found in this try perf run, please indicate this with @rustbot label: +perf-regression-triaged along with sufficient written justification. If you cannot justify the regressions please fix the regressions and do another perf run. If the next run shows neutral or positive results, the label will be automatically removed.

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

Instruction count

This is the most reliable metric that we have; it was used to determine the overall result at the top of this comment. However, even this metric can sometimes exhibit noise.

mean range count
Regressions ❌
(primary)
0.3% [0.2%, 0.4%] 37
Regressions ❌
(secondary)
0.4% [0.2%, 0.5%] 10
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 0.3% [0.2%, 0.4%] 37

Max RSS (memory usage)

Results (primary -0.9%, secondary 0.3%)

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)
2.0% [2.0%, 2.0%] 1
Regressions ❌
(secondary)
2.2% [2.2%, 2.2%] 1
Improvements ✅
(primary)
-1.9% [-2.6%, -1.4%] 3
Improvements ✅
(secondary)
-1.7% [-1.7%, -1.7%] 1
All ❌✅ (primary) -0.9% [-2.6%, 2.0%] 4

Cycles

Results (primary -2.2%, secondary 9.6%)

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)
9.6% [9.6%, 9.6%] 1
Improvements ✅
(primary)
-2.2% [-2.2%, -2.2%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) -2.2% [-2.2%, -2.2%] 1

Binary size

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

Bootstrap: 795.253s -> 795.718s (0.06%)
Artifact size: 336.22 MiB -> 335.54 MiB (-0.20%)

@rustbot rustbot added perf-regression Performance regression. and removed S-waiting-on-perf Status: Waiting on a perf run to be completed. labels Nov 23, 2024
@compiler-errors
Copy link
Member 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 Nov 23, 2024
bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 23, 2024
…=<try>

Make `compare_impl_item` into a query

First want to perf, then I'll write something up.

r? `@ghost`
@bors
Copy link
Contributor

bors commented Nov 23, 2024

⌛ Trying commit 1b30977 with merge d249c37...

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@bors
Copy link
Contributor

bors commented Nov 23, 2024

💔 Test failed - checks-actions

@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-review Status: Awaiting review from the assignee but also interested parties. labels Nov 23, 2024
@compiler-errors
Copy link
Member Author

@bors try @rust-timer queue

@rust-timer

This comment has been minimized.

@bors
Copy link
Contributor

bors commented Nov 23, 2024

⌛ Trying commit 4ece9e6 with merge 9dedd09...

bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 23, 2024
…=<try>

Make `compare_impl_item` into a query

First want to perf, then I'll write something up.

r? `@ghost`
@rust-log-analyzer

This comment has been minimized.

@bors
Copy link
Contributor

bors commented Nov 23, 2024

☀️ Try build successful - checks-actions
Build commit: 9dedd09 (9dedd0907e6ca8addde92511267c83ff2d1f6a22)

@bors
Copy link
Contributor

bors commented Nov 26, 2024

💔 Test failed - checks-actions

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

lcnr commented Nov 26, 2024

@bors retry

@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 Nov 26, 2024
bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 27, 2024
…=lcnr

Make `compare_impl_item` into a query

Turns `compare_impl_item` into a query (generalizing the existing query for `compare_impl_const`), and uses that in `Instance::resolve` to fail resolution when an implementation is incompatible with the trait it comes from.

Fixes rust-lang#119701
Fixes rust-lang#121127
Fixes rust-lang#121411
Fixes rust-lang#129075
Fixes rust-lang#129127
Fixes rust-lang#129214
Fixes rust-lang#131294
@bors
Copy link
Contributor

bors commented Nov 27, 2024

⌛ Testing commit a1d9da3 with merge 5857540...

@rust-log-analyzer

This comment has been minimized.

@bors
Copy link
Contributor

bors commented Nov 27, 2024

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Nov 27, 2024
@compiler-errors
Copy link
Member Author

compiler-errors commented Nov 27, 2024

lmao, ok I think I know how to turn this into a cycle 🤔

should be able to fix this by removing the refinement check from this logic

@lcnr
Copy link
Contributor

lcnr commented Nov 27, 2024

gamer!

@lcnr
Copy link
Contributor

lcnr commented Nov 30, 2024

@bors r+ rollup=never

@bors
Copy link
Contributor

bors commented Nov 30, 2024

📌 Commit 1e655ef has been approved by lcnr

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-review Status: Awaiting review from the assignee but also interested parties. labels Nov 30, 2024
@bors
Copy link
Contributor

bors commented Dec 1, 2024

⌛ Testing commit 1e655ef with merge 4af7fa7...

@bors
Copy link
Contributor

bors commented Dec 1, 2024

☀️ Test successful - checks-actions
Approved by: lcnr
Pushing 4af7fa7 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Dec 1, 2024
@bors bors merged commit 4af7fa7 into rust-lang:master Dec 1, 2024
7 checks passed
@rustbot rustbot added this to the 1.85.0 milestone Dec 1, 2024
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (4af7fa7): comparison URL.

Overall result: ❌ regressions - please read the text below

Our benchmarks found a performance regression caused by this PR.
This might be an actual regression, but it can also be just noise.

Next Steps:

  • If the regression was expected or you think it can be justified,
    please write a comment with sufficient written justification, and add
    @rustbot label: +perf-regression-triaged to it, to mark the regression as triaged.
  • If you think that you know of a way to resolve the regression, try to create
    a new PR with a fix for the regression.
  • If you do not understand the regression or you think that it is just noise,
    you can ask the @rust-lang/wg-compiler-performance working group for help (members of this group
    were already notified of this PR).

@rustbot label: +perf-regression
cc @rust-lang/wg-compiler-performance

Instruction count

This is the most reliable metric that we have; it was used to determine the overall result at the top of this comment. However, even this metric can sometimes exhibit noise.

mean range count
Regressions ❌
(primary)
0.3% [0.2%, 0.5%] 27
Regressions ❌
(secondary)
0.4% [0.3%, 1.3%] 7
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 0.3% [0.2%, 0.5%] 27

Max RSS (memory usage)

Results (primary 0.1%, secondary 4.0%)

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.0% [0.5%, 1.6%] 2
Regressions ❌
(secondary)
4.0% [4.0%, 4.0%] 1
Improvements ✅
(primary)
-1.7% [-1.7%, -1.7%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 0.1% [-1.7%, 1.6%] 3

Cycles

Results (primary -2.3%, secondary -2.4%)

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)
-2.3% [-2.3%, -2.3%] 1
Improvements ✅
(secondary)
-2.4% [-2.7%, -2.1%] 13
All ❌✅ (primary) -2.3% [-2.3%, -2.3%] 1

Binary size

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

Bootstrap: 774.339s -> 774.422s (0.01%)
Artifact size: 332.31 MiB -> 332.10 MiB (-0.06%)

@rylev
Copy link
Member

rylev commented Dec 4, 2024

Perf regressions were excused here

@rustbot label: +perf-regression-triaged

@rustbot rustbot added the perf-regression-triaged The performance regression has been triaged. label Dec 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. perf-regression Performance regression. perf-regression-triaged The performance regression has been triaged. 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
8 participants