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 14 pull requests #132470

Merged
merged 35 commits into from
Nov 2, 2024
Merged

Conversation

GuillaumeGomez
Copy link
Member

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

joshtriplett and others added 30 commits October 30, 2024 13:16
This avoids pathological cases where chains of binops get progressively
deeper.
Co-authored-by: Jubilee <workingjubilee@gmail.com>
Currently `f32_nan` and `f64_nan` are used to provide the
`invalid_nan_comparison` lint. Since we have `f16_nan` and `f128_nan`,
hook these up so the new float types get the same lints.
This makes it significantly easier to debug bugs of this kind.
…ready stable

the rest has their constness guarded by their usual feature gate
This is an API that naturally should exist as a combination of byte_offset_from and sub_ptr
both existing (they showed up at similar times so this union was never made). Adding these
is a logical (and perhaps final) precondition of stabilizing ptr_sub_ptr (rust-lang#95892).
rustc_target reexports a lot of things that are in rustc_abi, but
that will be over soon and now is probably a good time to switch.
Uses of rustc_target remain where they inquire about the target tuple.
…ukang

Remove support for `-Zprofile` (gcov-style coverage instrumentation)

Tracking issue: rust-lang#42524

MCP: rust-lang/compiler-team#798

---

This PR removes the unstable `-Zprofile` flag, which enables ”gcov-style” coverage instrumentation, along with its associated `-Zprofile-emit` configuration flag.

(The profile flag predates and is almost entirely separate from the stable `-Cinstrument-coverage` flag.)

Notably, the `-Zprofile` flag:
- Is largely untested in-tree, having only one run-make test that does not check whether its output is correct or useful.
- Has no known maintainer.
- Has seen no push towards stabilization.
- Has at least one severe regression reported in 2022 that apparently remains unaddressed.
  - rust-lang#100125
- Is confusingly named, since it appears to be more about coverage than performance profiling, and has nothing to do with PGO.
- Is fundamentally limited by relying on counters auto-inserted by LLVM, with no knowledge of Rust beyond debuginfo.
…ristic-assignment-only, r=calebcartwright

style-guide: Only use the new binop heuristic for assignments

This avoids pathological cases where chains of binops get progressively
deeper.
…k-sugg, r=WaffleLapkin

Implement suggestion for never type fallback lints

r? ```@WaffleLapkin```

Just opening this up for vibes; it's not done yet. I'd still like to make this suggestable in a few more cases before merge:
- [x] Try to annotate `_` -> `()`
- [x] Try to annotate local variables if they're un-annotated: `let x = ...` -> `let x: () = ...`
- [x] Try to annotate the self type of a `Trait::method()` -> `<() as Trait>::method()`.

The only other case we may want to suggest is a missing turbofish, like `f()` -> `f::<()>()`. That may be possible, but seems overly annoying.

This partly addresses rust-lang#132358; the other half of fixing that would be to make the error message a bit better, perhaps just special casing the `?` operator 🤔 I don't think I'll do that part.
…, r=workingjubilee

update offset_of! docs to reflect the stabilization of nesting

this seems to have been missed.
…tings, r=jieyouxu

Remove unncessary option for default rust-analyzer setting

In favor of rust-lang/rust-analyzer#17888
…ouxu

Add `f16` and `f128` to `invalid_nan_comparison`

Currently `f32_nan` and `f64_nan` are used to provide the `invalid_nan_comparison` lint. Since we have `f16_nan` and `f128_nan`, hook these up so the new float types get the same lints.
…uillaumeGomez

rustdoc: Directly use rustc_abi instead of reexports

rustc_target reexports a lot of things that are in rustc_abi, but that will be over soon and now is probably a good time to switch. Uses of rustc_target remain where they inquire about the target tuple.
…=tgross35

Cleanup attributes around unchecked shifts and unchecked negation in const

The underlying intrinsic is marked as "safe to expose on stable", so we shouldn't need any `rustc_allow_const_fn_unstable(unchecked_shifts)` anywhere. However, bootstrap rustc doesn't yet have the new const stability checks, so these changes only apply under `cfg(not(bootstrap))`.
@rustbot rustbot added A-run-make Area: port run-make Makefiles to rmake.rs A-rustdoc-json Area: Rustdoc JSON backend S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) 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. T-style Relevant to the style team, which will review and decide on the PR/issue. rollup A PR which is a rollup labels Nov 1, 2024
@GuillaumeGomez
Copy link
Member Author

@bors r+ p=14 rollup=never

@bors
Copy link
Contributor

bors commented Nov 1, 2024

📌 Commit 305ca05 has been approved by GuillaumeGomez

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

bors commented Nov 1, 2024

⌛ Testing commit 305ca05 with merge 7c7bb7d...

@bors
Copy link
Contributor

bors commented Nov 2, 2024

☀️ Test successful - checks-actions
Approved by: GuillaumeGomez
Pushing 7c7bb7d to master...

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

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#131829 Remove support for -Zprofile (gcov-style coverage instrum… 316805bde449c329140ae3ccfc6b5a63eb16aad5 (link)
#132369 style-guide: Only use the new binop heuristic for assignmen… 14e1acf38535f7b7c6932ffe70c7b700c0296900 (link)
#132383 Implement suggestion for never type fallback lints 8be1e4b0bd506aa6437a66dec7750ec37d4701ed (link)
#132413 update offset_of! docs to reflect the stabilization of nest… 0d5aee10c8cac44564d9cdaed884a47885362aa9 (link)
#132438 Remove unncessary option for default rust-analyzer setting 288423a0d3a9e037bb41655f135b41b255ef8b1c (link)
#132439 Add f16 and f128 to invalid_nan_comparison a3243d2f0b7bd78cfd7e7658f397f0cd85411142 (link)
#132444 rustdoc: Directly use rustc_abi instead of reexports bd913433244d5126b6083171f92820259425dc5a (link)
#132445 Cleanup attributes around unchecked shifts and unchecked ne… 07c59ea875114d08293fae08469d911fd1229e9d (link)
#132448 Add missing backtick b16e7887dbb9488282c83cbe0365e4835b01440f (link)
#132450 Show actual MIR when MIR building forgot to terminate block 5b0faa941dbcbbaa2c1df4df81aa78c727d87aa1 (link)
#132451 remove some unnecessary rustc_allow_const_fn_unstable 5b4d897a67b7d9f3c8a141762f374745214a1cde (link)
#132455 make const_alloc_layout feature gate only about functions t… 940536a35a311c8647106e436c3a22c5c1fb5307 (link)
#132456 Move remaining inline assembly test files into asm directory 29fe8aa886e77456d8445d01c7f96dfbae3cddec (link)
#132459 feat(byte_sub_ptr): unstably add ptr::byte_sub_ptr 03596a1f6eb5bf361f868cc1737ba8878b8fe1d8 (link)

previous master: 705cfe0e96

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 (7c7bb7d): 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 (primary 4.2%, secondary 1.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)
4.2% [3.6%, 4.9%] 2
Regressions ❌
(secondary)
4.1% [4.1%, 4.1%] 1
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-2.1% [-2.1%, -2.1%] 1
All ❌✅ (primary) 4.2% [3.6%, 4.9%] 2

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: 780.514s -> 779.104s (-0.18%)
Artifact size: 334.93 MiB -> 335.00 MiB (0.02%)

@GuillaumeGomez GuillaumeGomez deleted the rollup-1a1mkmp branch November 2, 2024 09:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-run-make Area: port run-make Makefiles to rmake.rs A-rustdoc-json Area: Rustdoc JSON backend merged-by-bors This PR was explicitly merged by bors. 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-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) 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. T-style Relevant to the style team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.