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

Rollup of 5 pull requests #125649

Merged
merged 23 commits into from
May 28, 2024
Merged

Rollup of 5 pull requests #125649

merged 23 commits into from
May 28, 2024

Conversation

workingjubilee
Copy link
Member

@workingjubilee workingjubilee commented May 28, 2024

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

clarfonthey and others added 23 commits May 25, 2024 15:00
 - Restrict const-anon exception diag to relevant places
 - Invoke bounds (and type-inference) in non_local_defs
 - Specialize diagnostic for impl without Trait
 - Remove wrong exception text for non-local macro_rules!
 - Simplify anonymous const exception note
…=estebank

Improve diagnostic output the `non_local_definitions` lint

This PR improves (or at least tries to improve) the diagnostic output the `non_local_definitions` lint, by simplifying the wording, by adding a "sort of" explanation of bounds interaction that leak the impl...

This PR is best reviewed commit by commit and is voluntarily made a bit vague as to have a starting point to improve on.

Related to https://rust-lang.zulipchat.com/#narrow/stream/131828-t-compiler/topic/non_local_defs.20wording.20improvements

Fixes rust-lang#125068
Fixes rust-lang#124396
cc ```@workingjubilee```
r? ```@estebank```
…, r=compiler-errors

`-Znext-solver`: eagerly normalize when adding goals

fixes rust-lang#125269. I am not totally with this fix and going to keep this open until we have a more general discussion about how to handle hangs caused by lazy norm in the new solver.
Stabilise `IpvNAddr::{BITS, to_bits, from_bits}` (`ip_bits`)

This completed FCP in rust-lang#113744. (Closes rust-lang#113744.)

Stabilises the following APIs:

```rust
impl Ipv4Addr {
    pub const BITS: u32 = 32;
    pub const fn from_bits(bits: u32) -> Ipv4Addr;
    pub const fn to_bits(self) -> u32;
}

impl Ipv6Addr {
    pub const BITS: u32 = 128;
    pub const fn from_bits(bits: u128) -> Ipv4Addr;
    pub const fn to_bits(self) -> u128;
}
```
Don't suggest turning non-char-literal exprs of ty `char` into string literals

Fixes rust-lang#125595.
Fixes rust-lang#125081.

r? estebank (rust-lang#122217) or compiler
…r=workingjubilee

update tracking issue for lazy_cell_consume

<!--
If this PR is related to an unstable feature or an otherwise tracked effort,
please link to the relevant tracking issue here. If you don't know of a related
tracking issue or there are none, feel free to ignore this.

This PR will get automatically assigned to a reviewer. In case you would like
a specific user to review your work, you can assign it to them by using

    r​? <reviewer name>
-->
@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. T-libs Relevant to the library 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 (-Znext-solver) rollup A PR which is a rollup labels May 28, 2024
@workingjubilee
Copy link
Member Author

@bors r+ rollup=never p=5

@bors
Copy link
Contributor

bors commented May 28, 2024

📌 Commit 4aaf9f6 has been approved by workingjubilee

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 May 28, 2024
@bors
Copy link
Contributor

bors commented May 28, 2024

⌛ Testing commit 4aaf9f6 with merge f989d2f...

@bors
Copy link
Contributor

bors commented May 28, 2024

☀️ Test successful - checks-actions
Approved by: workingjubilee
Pushing f989d2f to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label May 28, 2024
@bors bors merged commit f989d2f into rust-lang:master May 28, 2024
7 checks passed
@rustbot rustbot added this to the 1.80.0 milestone May 28, 2024
@rust-timer
Copy link
Collaborator

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#125089 Improve diagnostic output the non_local_definitions lint 6f02344996aef2d4e34cb4ff59cf853f3513c132 (link)
#125343 -Znext-solver: eagerly normalize when adding goals 7e8b50b1f3e77b28e0bbd7b713bbf0db2bc2a99e (link)
#125551 Stabilise IpvNAddr::{BITS, to_bits, from_bits} (ip_bits) 73a6e50d55ca80cd4238d901c40ff889186358d7 (link)
#125640 Don't suggest turning non-char-literal exprs of ty char i… 5b7e1ea250b15f162086942030aeb25ee58e5690 (link)
#125647 update tracking issue for lazy_cell_consume 46397ae9b0be5aad4d9df416e5317b307140e2ca (link)

previous master: c0d600385b

In the case of a perf regression, run the following command for each PR you suspect might be the cause: @rust-timer build $SHA

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (f989d2f): comparison URL.

Overall result: ❌ regressions - ACTION NEEDED

Next Steps: If you can justify the regressions found in this perf run, please indicate this with @rustbot label: +perf-regression-triaged along with sufficient written justification. If you cannot justify the regressions please open an issue or create a new PR that fixes the regressions, add a comment linking to the newly created issue or PR, and then add the perf-regression-triaged label to this PR.

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

Instruction count

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

mean range count
Regressions ❌
(primary)
1.3% [0.5%, 2.1%] 12
Regressions ❌
(secondary)
0.3% [0.3%, 0.4%] 3
Improvements ✅
(primary)
-0.1% [-0.1%, -0.1%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 1.2% [-0.1%, 2.1%] 13

Max RSS (memory usage)

Results (primary 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)
2.4% [2.2%, 2.7%] 2
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 2.4% [2.2%, 2.7%] 2

Cycles

Results (primary 1.5%)

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.4%, 1.6%] 2
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 1.5% [1.4%, 1.6%] 2

Binary size

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

Bootstrap: 668.358s -> 669.563s (0.18%)
Artifact size: 318.16 MiB -> 318.39 MiB (0.07%)

@rustbot rustbot added the perf-regression Performance regression. label May 28, 2024
@workingjubilee
Copy link
Member Author

uhhh

@rust-timer build 7e8b50b

@rust-timer

This comment has been minimized.

@lqd
Copy link
Member

lqd commented May 28, 2024

Probably #125089

@workingjubilee
Copy link
Member Author

oh probably.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (7e8b50b): comparison URL.

Overall result: ❌ regressions - ACTION NEEDED

Instruction count

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

mean range count
Regressions ❌
(primary)
0.8% [0.8%, 0.9%] 4
Regressions ❌
(secondary)
0.4% [0.3%, 0.8%] 26
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 0.8% [0.8%, 0.9%] 4

Max RSS (memory usage)

Results (primary 3.1%, secondary -3.2%)

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

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: 668.358s -> 669.315s (0.14%)
Artifact size: 318.16 MiB -> 318.25 MiB (0.03%)

@lqd
Copy link
Member

lqd commented May 28, 2024

Is this noise 👨 🫴 🦋, none of these regressions showed up in the initial perf report, and the PR is supposed to be new-solver only. Maybe the other PRs are improvements...

Oh but this is the lint that uses the new solver IIRC, it's not clear why helloworld would be impacted but let's see: @rust-timer build 6f02344

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (6f02344): comparison URL.

Overall result: ❌✅ regressions and improvements - ACTION NEEDED

Instruction count

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

mean range count
Regressions ❌
(primary)
1.3% [0.4%, 2.1%] 12
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-0.2% [-0.2%, -0.2%] 2
Improvements ✅
(secondary)
-0.2% [-0.2%, -0.2%] 1
All ❌✅ (primary) 1.1% [-0.2%, 2.1%] 14

Max RSS (memory usage)

Results (primary 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)
2.4% [2.1%, 2.8%] 2
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 2.4% [2.1%, 2.8%] 2

Cycles

Results (primary 1.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)
1.4% [1.3%, 1.6%] 2
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 1.4% [1.3%, 1.6%] 2

Binary size

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

Bootstrap: 668.358s -> 670.93s (0.38%)
Artifact size: 318.16 MiB -> 318.32 MiB (0.05%)

@lqd
Copy link
Member

lqd commented May 28, 2024

Right, that's more like the previous results.

@workingjubilee
Copy link
Member Author

cc @Urgau perf regression in your PR unforch

@workingjubilee workingjubilee deleted the rollup-zwoum3k branch May 29, 2024 00:19
@Urgau
Copy link
Member

Urgau commented May 29, 2024

Right, I think it's the same kind of perf regression as when the non_local_definitions lint was introduced, #120393 (comment).

The lint triggers nearly 150 times in the version of diesel used by rustc-perf, so the benchmark has become a bit a linting machinery benchmark, and since #125089 is making some big changes to the diagnostic output, that probably explain why there is some perf regression.

I would consider this to be a false alarm. cc rust-lang/rustc-perf#1819

@pnkfelix
Copy link
Member

pnkfelix commented Jun 3, 2024

I agree with @Urgau 's analysis; the benchmark has become a linting machinery benchmark, and T-compiler really should decide what it wants out of such a scenario...

... but that debate can be continued on rust-lang/rustc-perf#1819.

marking as triaged.

@rustbot label: +perf-regression-triaged

@rustbot rustbot added the perf-regression-triaged The performance regression has been triaged. label Jun 3, 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. rollup A PR which is a rollup 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-libs Relevant to the library 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 (-Znext-solver)
Projects
None yet
Development

Successfully merging this pull request may close these issues.