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 9 pull requests #129632

Merged
merged 34 commits into from
Aug 27, 2024
Merged

Rollup of 9 pull requests #129632

merged 34 commits into from
Aug 27, 2024

Conversation

matthiaskrgr
Copy link
Member

Successful merges:

Failed merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

binarycat and others added 30 commits July 25, 2024 12:14
also start deduplicating the docs that are getting moved to this
section.
It requires no additonal changes to these crates, but will prevent
unnecessary `pub`s in the future.
Prevents reporting labels or diagnostics on spans that are produced
multiple times.
Documents that `BikeshedIntrinsicFrom` models transmute-via-union,
which is slightly more expressive than the transmute-via-cast
implemented by `transmute_copy`. Additionally, we provide an
implementation of transmute-via-union as a method on the
`BikeshedIntrinsicFrom` trait with additional documentation on
the boundary between trait invariants and caller obligations.

Whether or not transmute-via-union is the right kind of transmute
to model remains up for discussion [1]. Regardless, it seems wise
to document the present behavior.

[1] https://rust-lang.zulipchat.com/#narrow/stream/216762-project-safe-transmute/topic/What.20'kind'.20of.20transmute.20to.20model.3F/near/426331967
When looking for multiple versions of the same crate, do not blindly construct the receiver type.

Follow up to rust-lang#128786. Fix rust-lang#129205.
Add `#[warn(unreachable_pub)]` to a bunch of compiler crates

By default `unreachable_pub` identifies things that need not be `pub` and tells you to make them `pub(crate)`. But sometimes those things don't need any kind of visibility. So they way I did these was to remove the visibility entirely for each thing the lint identifies, and then add `pub(crate)` back in everywhere the compiler said it was necessary. (Or occasionally `pub(super)` when context suggested that was appropriate.) Tedious, but results in more `pub` removal.

There are plenty more crates to do but this seems like enough for a first PR.

r? `@compiler-errors`
…=cuviper

deduplicate and clarify rules for converting pointers to references

part of rust-lang#124669
…er-errors

Document & implement the transmutation modeled by `BikeshedIntrinsicFrom`

Documents that `BikeshedIntrinsicFrom` models transmute-via-union, which is slightly more expressive than the transmute-via-cast implemented by `transmute_copy`. Additionally, we provide an implementation of transmute-via-union as a method on the `BikeshedIntrinsicFrom` trait with additional documentation on the boundary between trait invariants and caller obligations.

Whether or not transmute-via-union is the right kind of transmute to model remains up for discussion [1]. Regardless, it seems wise to document the present behavior.

[1] https://rust-lang.zulipchat.com/#narrow/stream/216762-project-safe-transmute/topic/What.20'kind'.20of.20transmute.20to.20model.3F/near/426331967

Tracking Issue: rust-lang#99571

r? `@compiler-errors`

cc `@scottmcm,` `@Lokathor`
…errors

Do not ICE on non-ADT rcvr type when looking for crate version collision

When looking for multiple versions of the same crate, do not blindly construct the receiver type.

Follow up to rust-lang#128786.
Fixes rust-lang#129205
Fixes rust-lang#129216
…274, r=compiler-errors

Remove Duplicate E0381 Label

Aims to resolve rust-lang#129274, and adds a test for the case.

Essentially, we are duplicating this span for some reason. For now, I'm just using a set to collect the spans rather than the vec. I imagine there's probably no real reason to inspect duplicates in this area, but if I'm wrong I can adjust to collect "seen spans" in just the point where this label is applied.

I'm not sure why it's producing duplicate spans. Looks like this has been this way for a while? I think it gives the duplicate label on 1.75.0 for example.
…rce-link, r=notriddle

[rustdoc] Generate source link on impl associated types

Currently, impl associated types are generated but don't get a source link. This PR fixes that.

Before:

![image](https://github.com/user-attachments/assets/3a22adb5-8b66-4124-9267-7c26eed1aa5e)

After:

![Screenshot from 2024-08-25 16-31-36](https://github.com/user-attachments/assets/6e9b35e7-4357-4ecf-8c49-1d8294051283)

r? `@notriddle`
Remove a couple of unused feature enables
… r=fmease

Rename `ParenthesizedGenericArgs` to `GenericArgsMode`

A bit easier to digest name. Broken out of a PR implementing return type notation.
…fmease

Remove `ParamMode::ExplicitNamed`

This was introduced as a hack to improve a diagnostics suggestion in rust-lang#61679. It was subsequently broken, but also it was an incomplete hack that I don't believe we need to support, so let's just remove it.
@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. rollup A PR which is a rollup labels Aug 26, 2024
@matthiaskrgr
Copy link
Member Author

@bors r+ rollup=never p=9

@bors
Copy link
Contributor

bors commented Aug 26, 2024

📌 Commit b3b6baf has been approved by matthiaskrgr

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 Aug 26, 2024
@bors
Copy link
Contributor

bors commented Aug 26, 2024

⌛ Testing commit b3b6baf with merge bf662eb...

@bors
Copy link
Contributor

bors commented Aug 27, 2024

☀️ Test successful - checks-actions
Approved by: matthiaskrgr
Pushing bf662eb to master...

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

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#126013 Add #[warn(unreachable_pub)] to a bunch of compiler crates ad76c6fbabf44e5c8bb05b30d3bc1359ff0c4a55 (link)
#128157 deduplicate and clarify rules for converting pointers to re… f68193acc7ebfcee5a5792a006bc335716bb2b24 (link)
#129032 Document & implement the transmutation modeled by `Bikeshed… 5911b2a59e73e70bca97ccb9e42b4b57dc745aa5 (link)
#129250 Do not ICE on non-ADT rcvr type when looking for crate vers… ce0ce843f214edc134ed13f2850878d5b327d8d3 (link)
#129340 Remove Duplicate E0381 Label 0b7a23192b77b4c0b0dfa55746527c2d7d22d8d7 (link)
#129560 [rustdoc] Generate source link on impl associated types b90b55a38a06658aa78b710462c6fde85dde2a27 (link)
#129622 Remove a couple of unused feature enables 3e175dbde1f8e7b92a8884bbddad4279c2e77665 (link)
#129625 Rename ParenthesizedGenericArgs to GenericArgsMode 4cd2ebbc059bbc74c350f351d7b520f985f27342 (link)
#129626 Remove ParamMode::ExplicitNamed b48ee7854174722fa86a37457213cd2963c69f24 (link)

previous master: 515395af0e

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

Max RSS (memory usage)

Results (primary 3.2%, secondary 2.1%)

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

Cycles

Results (primary 4.5%, secondary 4.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)
4.5% [4.5%, 4.5%] 1
Regressions ❌
(secondary)
4.3% [3.5%, 5.0%] 3
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 4.5% [4.5%, 4.5%] 1

Binary size

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

Bootstrap: 749.753s -> 748.783s (-0.13%)
Artifact size: 338.77 MiB -> 338.80 MiB (0.01%)

@rustbot rustbot added the perf-regression Performance regression. label Aug 27, 2024
@pnkfelix
Copy link
Member

@rust-timer build b90b55a

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (b90b55a): 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)
1.0% [0.2%, 2.3%] 3
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 1.0% [0.2%, 2.3%] 3

Max RSS (memory usage)

Results (secondary 0.1%)

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

Cycles

Results (primary 4.1%)

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

Binary size

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

Bootstrap: 749.753s -> 752.203s (0.33%)
Artifact size: 338.77 MiB -> 338.74 MiB (-0.01%)

@matthiaskrgr matthiaskrgr deleted the rollup-8055gq6 branch September 1, 2024 17:35
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. 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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.