Skip to content

Conversation

matthiaskrgr
Copy link
Member

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

Bryanskiy and others added 29 commits March 22, 2024 17:24
…ype, None in compiler/rustc_mir_build/src/build/expr/as_place.rs rust-lang#110453

Fixes rust-lang#110453
Rustc gives a warning when compiling proc macros with panic=abort.
…ister

Don't emit an error about failing to produce a file with a specific name if user never gave an explicit name

Fixes rust-lang#122509

You can ask `rustc` to produce some intermediate results with `--emit foo`, this operation comes in two flavors: `--emit asm` and `--emit asm=foo.s`. First one produces one or more `.s` files without any name guarantees, second one renames it into `foo.s`. Second version only works when compiler produces a single file - for asm files this means using a single compilation unit for example.

In case compilation produced more than a single file `rustc` runs following check to emit some warnings:

```rust
            if crate_output.outputs.contains_key(&output_type) {
                // 2) Multiple codegen units, with `--emit foo=some_name`. We have
                //    no good solution for this case, so warn the user.
                sess.dcx().emit_warn(errors::IgnoringEmitPath { extension });
            } else if crate_output.single_output_file.is_some() {
                // 3) Multiple codegen units, with `-o some_name`. We have
                //    no good solution for this case, so warn the user.
                sess.dcx().emit_warn(errors::IgnoringOutput { extension });
            } else {
                // 4) Multiple codegen units, but no explicit name. We
                //    just leave the `foo.0.x` files in place.
                // (We don't have to do any work in this case.)
            }
```

Comment in the final `else` branch implies that if user didn't ask for a specific name - there's no need to emit warnings. However because of the internal representation of `crate_output.outputs` - this doesn't work as expected: if user asked to produce an asm file without giving it an implicit name it will contain `Some(None)`.

To fix the problem new code actually checks if user gave an explicit name. I think this was an original intentional behavior, at least comments imply that.
…trochenkov

Delegation: fix ICE on `bound_vars` divergence

Fixes rust-lang#122550.

Bug was caused by divergence  between lowered type and corresponding `bound_vars` in `late_bound_vars_map`. In this patch `bound_vars` calculation for delegation item is moved from `lower_fn_ty` to `resolve_bound_vars` query.

r? `@petrochenkov`
…h-pat-only, r=petrochenkov

Validate that we're only matching on unit struct for path pattern

Resolution doesn't validate that we only really take `CtorKind::Unit` in path patterns, since all it sees is `Res::SelfCtor(def_id)`. Check this instead during pattern typeck.

r? petrochenkov

Fixes rust-lang#122809
…acrum

Use `chunk_by` when building `ReverseSccGraph`

With stable `chunk_by` in Rust 1.77, this code doesn't need `Itertools::group_by` anymore.
…t, r=petrochenkov

Fix unpretty UI test when /tmp does not exist

On Windows this test fails if e.g. `C:\tmp` is created successfully
Rename `{enter,exit}_lint_attrs` to `check_attributes{,_post}`

Several places in Clippy want to check all the attributes of a node, we end up using `hir().attrs()` from several different `check_` functions (e.g. [in our doc lints](https://github.com/rust-lang/rust-clippy/blob/95c62ffae9bbce793f68a6f1473e3fc24af19bdd/clippy_lints/src/doc/mod.rs#L396)) but this is error prone, we recently found that doc lints weren't triggering on struct fields for example

I went to add a `check_attributes` function but realised `enter_lint_attrs` is already this, the rename is to encourage their use

Also removes `LateContextAndPass::visit_attribute` since it's unused - `visit_attribute` for HIR visitors is only called by `hir().walk_attributes()` which lint passes do not use
…losure, r=bjorn3

Add `async-closures/once.rs` back to cranelift tests

This was fixed afaict by rust-lang#120717

r? `@bjorn3`
…rors

Add a bunch of needs-unwind annotations to tests

To filter out tests that fail with cg_clif due to missing panic=unwind support.
@rustbot rustbot added the A-testsuite Area: The testsuite used to check the correctness of rustc label Mar 25, 2024
@rustbot rustbot added 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. rollup A PR which is a rollup labels Mar 25, 2024
@matthiaskrgr
Copy link
Member Author

@bors r+ rollup=never p=9

@bors
Copy link
Collaborator

bors commented Mar 25, 2024

📌 Commit 4369718 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 Mar 25, 2024
@bors
Copy link
Collaborator

bors commented Mar 25, 2024

⌛ Testing commit 4369718 with merge 60b5ca6...

@bors
Copy link
Collaborator

bors commented Mar 25, 2024

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

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Mar 25, 2024
@bors bors merged commit 60b5ca6 into rust-lang:master Mar 25, 2024
@rustbot rustbot added this to the 1.79.0 milestone Mar 25, 2024
@rust-timer
Copy link
Collaborator

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#122842 Don't emit an error about failing to produce a file with a … e37bc758bf79726cf19328f0111a5ecf5ecafc6f (link)
#122881 Delegation: fix ICE on bound_vars divergence bace571c7dd39a0aa9eed77da638acf4043ad4a1 (link)
#122910 Validate that we're only matching on unit struct for path p… b31c21180ff874b7ed5d9c3fdc7359fba98fbdd9 (link)
#122970 Use chunk_by when building ReverseSccGraph 668c9054e931fdcad0d32f98a31b56a3f9e19267 (link)
#122988 add even more tests! 53d9d9a12f96a46094a19fcafe687b5ee5458222 (link)
#122999 Fix unpretty UI test when /tmp does not exist 6b442dcc81c0d4112de78f75e2adc530aacf206f (link)
#123001 Rename {enter,exit}_lint_attrs to `check_attributes{,_pos… 6c5e4dbc1751952e3b911d2bc0bd758720fcb34c (link)
#123022 Add async-closures/once.rs back to cranelift tests e0a9f15614b5bd244ba8b6259735f704dc2618b0 (link)
#123034 Add a bunch of needs-unwind annotations to tests 6ef104f39ea227fbf0a7b79c178f6c0736a5616b (link)

previous master: cb7c63606e

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 (60b5ca6): 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

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)
-1.1% [-1.4%, -0.6%] 4
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) -1.1% [-1.4%, -0.6%] 4

Cycles

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.

mean range count
Regressions ❌
(primary)
0.6% [0.4%, 0.8%] 6
Regressions ❌
(secondary)
3.5% [3.5%, 3.5%] 1
Improvements ✅
(primary)
-0.8% [-0.8%, -0.8%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 0.4% [-0.8%, 0.8%] 7

Binary size

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

Bootstrap: 670.74s -> 671.366s (0.09%)
Artifact size: 315.07 MiB -> 315.07 MiB (-0.00%)

@rust-log-analyzer
Copy link
Collaborator

A job failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
  PR_MESSAGE: Automation to keep dependencies in `Cargo.lock` current.
following is the output from `cargo update`:
  COMMIT_MESSAGE: cargo update 
##[endgroup]
Starting download for Cargo-lock
##[error]Unable to find any artifacts for the associated workflow

@matthiaskrgr matthiaskrgr deleted the rollup-dj8hra4 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
A-testsuite Area: The testsuite used to check the correctness of rustc 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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.