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 #121234

Closed
wants to merge 20 commits into from

Conversation

matthiaskrgr
Copy link
Member

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

onur-ozkan and others added 20 commits February 14, 2024 13:31
Previously, we were trying to install all doc files under "share/doc/rust"
which caused `rust-installer` tool to create backup files (*.old) due to filename
conflicts. With this change, doc files is now installed under "share/doc/{package}",
where {package} could be rustc, cargo, clippy, etc.

Signed-off-by: onur-ozkan <[email protected]>
Previously, we used the entire sysroot binary path to prepare rustc tarballs.
Since we also copy tool binaries to the sysroot binary path, installing rustc
and tools with `x install` results in attempting to install the same binaries
more than once. This causes rust-installer to create backup files (*.old) due
to file conflicts. This change fixes that.

Signed-off-by: onur-ozkan <[email protected]>
This change helps us to bypass downloading the beta compiler in bootstrap tests.

Signed-off-by: onur-ozkan <[email protected]>
Subdiagnostics don't need to be lazily translated, they can always be
eagerly translated. Eager translation is slightly more complex as we need
to have a `DiagCtxt` available to perform the translation, which involves
slightly more threading of that context.

This slight increase in complexity should enable later simplifications -
like passing `DiagCtxt` into `AddToDiagnostic` and moving Fluent messages
into the diagnostic structs rather than having them in separate files
(working on that was what led to this change).

Signed-off-by: David Wood <[email protected]>
Because they all are, in practice.
i386-apple-ios is also a simulator target
Due to missing stamp file, we were downloading (and applying nix patches if enabled)
continuously every time `Config::download_clippy` was called. This change fixes that by
creating stamp file at the end of the function.

Signed-off-by: onur-ozkan <[email protected]>
Don't use mem::zeroed in vec::IntoIter

`mem::zeroed` is not a trivial function. Maybe it was once, but now it involves multiple locals, copies, and an intrinsic that gets monomorphized into a call to `panic_nounwind` for iterators of types like `Vec<&T>`. Of course all that complexity is trivially optimized out, but generating a bunch of IR where we don't need to just so we can optimize it away later is silly.
…bertlarsan68

distribute tool documentations and avoid file conflicts on `x install`

I suggest reading commits one-by-one with the descriptions for more context about the changes.

Fixes rust-lang#115213
…, r=nnethercote

errors: only eagerly translate subdiagnostics

Subdiagnostics don't need to be lazily translated, they can always be eagerly translated. Eager translation is slightly more complex as we need to have a `DiagCtxt` available to perform the translation, which involves slightly more threading of that context.

This slight increase in complexity should enable later simplifications - like passing `DiagCtxt` into `AddToDiagnostic` and moving Fluent messages into the diagnostic structs rather than having them in separate files (working on that was what led to this change).

r? `@nnethercote`
…in-tests, r=albertlarsan68

use build.rustc config and skip-stage0-validation flag

This change helps us to bypass downloading the beta compiler in bootstrap tests.

more context: https://rust-lang.zulipchat.com/#narrow/stream/326414-t-infra.2Fbootstrap/topic/tests.20causing.20downloads.20of.20native.20rustc.20for.20other.20platforms/near/421467975
…ent, r=lcnr

Use fulfillment in next trait solver coherence

Use fulfillment in the new trait solver's `impl_intersection_has_impossible_obligation` routine. This means that inference that falls out of processing other obligations can influence whether we can determine if an obligation is impossible to satisfy. See the committed test.

This should be completely sound, since evaluation and fulfillment both respect intercrate mode equally.

We run the risk of breaking coherence later if we were to change the rules of fulfillment and/or inference during coherence, but this is a problem which affects evaluation, as nested obligations from a trait goal are processed together and can influence each other in the same way.

r? lcnr
cc rust-lang#114862

Also changed obligationctxt -> fulfillmentctxt because it feels kind of redundant to use an ocx here. I don't really care enough and can change it back if it really matters much.
…s, r=compiler-errors

Add more checks for `unnamed_fields` during HIR analysis

Fixes rust-lang#121151

I also found that we don't prevent enums here so
```rs
#[repr(C)]
#[derive(Debug)]
enum A {
    #[default]
    B,
    C,
}

#[repr(C)]
#[derive(Debug)]
struct D {
    _: A,
}
```
leads to an ICE on an `self.is_struct() || self.is_union()` assertion, so fixed that too.
…n, r=bjorn3

Make `CodegenBackend::join_codegen` infallible.

Because they all are, in practice.

r? `@bjorn3`
…ios, r=workingjubilee

Fix `cfg(target_abi = "sim")` on `i386-apple-ios`

Since rust-lang#80970 is stabilizing, I went and had a look, and found that the result was wrong on `i386-apple-ios`.

r? rust-lang/macos
…=albertlarsan68

create stamp file for clippy

Due to missing stamp file, we were downloading (and applying nix patches if enabled) continuously every time `Config::download_clippy` was called. This change fixes that by creating stamp file at the end of the function.

Fixes rust-lang#119442
@rustbot rustbot added A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic 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. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver) rollup A PR which is a rollup labels Feb 17, 2024
@matthiaskrgr
Copy link
Member Author

@bors r+ rollup=never p=9

@bors
Copy link
Contributor

bors commented Feb 17, 2024

📌 Commit ad71ae1 has been approved by matthiaskrgr

It is now in the queue for this repository.

@bors bors removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Feb 17, 2024
@bors bors added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Feb 17, 2024
@rust-log-analyzer
Copy link
Collaborator

The job x86_64-gnu-llvm-16 failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
GITHUB_ENV=/home/runner/work/_temp/_runner_file_commands/set_env_ad10b8a6-8910-4afa-9fa8-546fc8db4e31
GITHUB_EVENT_NAME=pull_request
GITHUB_EVENT_PATH=/home/runner/work/_temp/_github_workflow/event.json
GITHUB_GRAPHQL_URL=https://api.github.com/graphql
GITHUB_HEAD_REF=rollup-fizi1gf
GITHUB_JOB=pr
GITHUB_PATH=/home/runner/work/_temp/_runner_file_commands/add_path_ad10b8a6-8910-4afa-9fa8-546fc8db4e31
GITHUB_REF=refs/pull/121234/merge
GITHUB_REF_NAME=121234/merge
GITHUB_REF_PROTECTED=false
---
#12 writing image sha256:a6f93ded3f6494adb92554cd01bbd3def2a3ca3295268b4e6be5c219e7fe9292 done
#12 naming to docker.io/library/rust-ci done
#12 DONE 10.0s
##[endgroup]
Setting extra environment values for docker:  --env ENABLE_GCC_CODEGEN=1 --env GCC_EXEC_PREFIX=/usr/lib/gcc/
[CI_JOB_NAME=x86_64-gnu-llvm-16]
##[group]Clock drift check
  local time: Sat Feb 17 13:48:04 UTC 2024
  network time: Sat, 17 Feb 2024 13:48:04 GMT
  network time: Sat, 17 Feb 2024 13:48:04 GMT
##[endgroup]
sccache: Starting the server...
##[group]Configure the build
configure: processing command line
configure: 
configure: build.configure-args := ['--build=x86_64-unknown-linux-gnu', '--llvm-root=/usr/lib/llvm-16', '--enable-llvm-link-shared', '--set', 'rust.thin-lto-import-instr-limit=10', '--set', 'change-id=99999999', '--enable-verbose-configure', '--enable-sccache', '--disable-manage-submodules', '--enable-locked-deps', '--enable-cargo-native-static', '--set', 'rust.codegen-units-std=1', '--set', 'dist.compression-profile=balanced', '--dist-compression-formats=xz', '--set', 'build.optimized-compiler-builtins', '--disable-dist-src', '--release-channel=nightly', '--enable-debug-assertions', '--enable-overflow-checks', '--enable-llvm-assertions', '--set', 'rust.verify-llvm-ir', '--set', 'rust.codegen-backends=llvm,cranelift,gcc', '--set', 'llvm.static-libstdcpp', '--enable-new-symbol-mangling']
configure: target.x86_64-unknown-linux-gnu.llvm-config := /usr/lib/llvm-16/bin/llvm-config
configure: llvm.link-shared     := True
configure: rust.thin-lto-import-instr-limit := 10
configure: change-id            := 99999999
---
   Compiling compiletest v0.0.0 (/checkout/src/tools/compiletest)
    Finished release [optimized] target(s) in 13.85s
##[endgroup]
##[group]Testing stage2 compiletest suite=ui mode=ui (x86_64-unknown-linux-gnu)
error: detected legacy-style directives in ui test: /checkout/tests/ui/union/unnamed-fields/restrict_type_hir.rs:1, please use `ui_test`-style directives `//@` instead:Some(
        None,
        None,
        "aux-build:dep.rs",
)
)
errors encountered during EarlyProps parsing: /checkout/tests/ui/union/unnamed-fields/restrict_type_hir.rs
errors encountered during EarlyProps parsing
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Build completed unsuccessfully in 0:11:57
  local time: Sat Feb 17 14:00:35 UTC 2024

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic 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. 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.