-
Notifications
You must be signed in to change notification settings - Fork 13.4k
Rollup of 17 pull requests #142332
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
Closed
Closed
Rollup of 17 pull requests #142332
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
``` error[E0621]: explicit lifetime required in the type of `x` --> $DIR/42701_one_named_and_one_anonymous.rs:10:9 | LL | &*x | ^^^ lifetime `'a` required | help: add explicit lifetime `'a` to the type of `x` | LL | fn foo2<'a>(a: &'a Foo, x: &'a i32) -> &'a i32 { | ++ ```
Lets the test still work on different architectures.
We move the vectorcall ABI tests into their own file which is now only run on x86-64, while replacing them with rust-cold ABI tests so that aarch64 hosts continue to test an unstable ABI. A better solution might be cross-compiling or something but I really don't have time for that right now.
Explicitly cross-build it for GPU targets and check it errors on hosts.
Some architectures gain target-cpu minimums in doing so.
To centralize this hack in one place with a backlink to the issue tracking this hack, as this logic is also needed by compiletest to implement a `//@ needs-target-std` directive.
To support tests to condition their (potentially cross-compile) execution based on whether the target supports std.
Instead of a jumble of `ignore-$target`s, `ignore-none` and `ignore-nvptx`.
This removes the `compiler_builtins` dependency from a handful of library dependencies, which is progress toward [1]. [1]: rust-lang#142265
This was attempted in [1] then reverted in [2] because of fallout. Recently, this was made an edition-dependent error in [3]. Make missing fragment specifiers an unconditional error again. [1]: rust-lang#75516 [2]: rust-lang#80210 [3]: rust-lang#128006
``` error: cannot find attribute `empty_helper` in this scope --> $DIR/derive-helper-legacy-limits.rs:17:3 | LL | #[empty_helper] | ^^^^^^^^^^^^ | help: `empty_helper` is an attribute that can be used by the derive macro `Empty`, you might be missing a `derive` attribute | LL + #[derive(Empty)] LL | struct S2; | ``` Look at proc-macro attributes when encountering unknown attribute ``` error: cannot find attribute `sede` in this scope --> src/main.rs:18:7 | 18 | #[sede(untagged)] | ^^^^ | help: the derive macros `Serialize` and `Deserialize` accept the similarly named `serde` attribute | 18 | #[serde(untagged)] | ~~~~~ error: cannot find attribute `serde` in this scope --> src/main.rs:12:7 | 12 | #[serde(untagged)] | ^^^^^ | = note: `serde` is in scope, but it is a crate, not an attribute help: `serde` is an attribute that can be used by the derive macros `Serialize` and `Deserialize`, you might be missing a `derive` attribute | 10 | #[derive(Serialize, Deserialize)] | ```
No changes; just removing the `self` that wasn't needed.
…r-unconditional, r=petrochenkov,traviscross Make `missing_fragment_specifier` an unconditional error This was attempted in [1] then reverted in [2] because of fallout. Recently, this was made an edition-dependent error in [3]. Make missing fragment specifiers an unconditional error again, across all editions. More context: rust-lang#128006 Most recent crater: rust-lang#128425 (comment) Fixes: rust-lang#40107 [1]: rust-lang#75516 [2]: rust-lang#80210 [3]: rust-lang#128006
Look at proc-macro attributes when encountering unknown attribute ``` error: cannot find attribute `sede` in this scope --> $DIR/missing-derive-2.rs:22:7 | LL | #[sede(untagged)] | ^^^^ | help: the derive macros `Deserialize` and `Serialize` accept the similarly named `serde` attribute | LL | #[serde(untagged)] | + error: cannot find attribute `serde` in this scope --> $DIR/missing-derive-2.rs:16:7 | LL | #[serde(untagged)] | ^^^^^ | note: `serde` is imported here, but it is a crate, not an attribute --> $DIR/missing-derive-2.rs:5:1 | LL | extern crate serde; | ^^^^^^^^^^^^^^^^^^^ help: `serde` is an attribute that can be used by the derive macros `Serialize` and `Deserialize`, you might be missing a `derive` attribute | LL + #[derive(Serialize, Deserialize)] LL | enum B { | ``` Partially address rust-lang#47608. This PR doesn't find [macros that haven't yet been imported by name](rust-lang@af945cb).
…ts, r=aDotInTheVoid tests: Change ABIs in tests to more future-resilient ones Eventually we're going to make these tests not work as they are currently written on HEAD, so change them now to get ahead of that. r? aDotInTheVoid
…eature-gate-test, r=jieyouxu tests: Minicore `extern "gpu-kernel"` feature test Explicitly cross-build it for GPU targets and check it errors on hosts. A relatively minor cleanup from my other ABI-related PRs that I got tired of rebasing.
…r=Mark-Simulacrum Update dependencies in `library/Cargo.lock` This removes the `compiler_builtins` dependency from a handful of library dependencies, which is progress toward [1]. [1]: rust-lang#142265
Only run `citool` tests on the `auto` branch Proposed here: [#t-infra > PR ci seems much to slow @ 💬](https://rust-lang.zulipchat.com/#narrow/channel/242791-t-infra/topic/PR.20ci.20seems.20much.20to.20slow/near/523159583). I haven't yet seen these tests failing on CI, so I think it's a good trade-off. r? ``@marcoieni``
…ly, r=nnethercote tests: Do not run afoul of asm.validity.non-exhaustive in input-stats This addresses one of the three powerpc64-unknown-linux-musl test failures in rust-lang#142280 I was motivated to cover it myself because technically this is also compile-time UB if we compile a program that has `asm!` with x86-64-specific instructions on another platform. That'll only mean something if this is ever switched to build-pass, or if checking emits object code, but conveniently "nop" is valid assembly on all platforms anyone has implemented Rust codegen for. Even the weird ones LLVM doesn't support, like PA-RISC or Common Intermediate Language. ...except GPUs. Not sure about those. r? ``@nnethercote``
Implement `//@ needs-target-std` compiletest directive Closes rust-lang#141863. Needed to unblock rust-lang#139244 and rust-lang#141856. ### Summary This PR implements a `//@ needs-target-std` compiletest directive that gates test execution based on whether the target supports std or not. For some cases, this should be preferred over e.g. some combination of `//@ ignore-none`, `//@ ignore-nvptx` and more[^none-limit]. ### Implementation limitation Unfortunately, since there is currently [no reliable way to determine from metadata whether a given target supports std or not](rust-lang#142296), we have to resort to a hack. Bootstrap currently determines whether or not a target supports std by a naive target tuple substring comparison: a target supports std if its target tuple does *not* contain one of `["-none", "nvptx", "switch"]` substrings. This PR simply pulls that hack out into `build_helpers` to avoid reimplementing the same hack in compiletest, and uses that logic to inform `//@ needs-target-std`. ### Auxiliary changes This PR additionally changes a few run-make tests to use `//@ needs-target-std` over an inconsistent combination of target-based `ignore`s. This should help with rust-lang#139244. --- r? bootstrap [^none-limit]: Notably, `target_os = "none"` is **not** a sufficient condition for "target does not support std"
…, r=fee1-dead Make loongarch-none target maintainers more easily pingable In the same style as rust-lang#139028. r? compiler
…nv-query, r=lcnr Dont unwrap and re-wrap typing envs Just a tiny tweak to make the query less awkward. r? lcnr
…gjubilee Remove unneeded `FunctionCx` from some codegen methods No changes; just removing the `self` that wasn't needed. r? workingjubilee cc rust-lang#138759 (comment)
…, r=tgross35 feat: Add `bit_width` for unsigned integer types - Accepted ACP: rust-lang/libs-team#598 - Tracking issue: rust-lang#142326 This PR adds methods to the primitive unsigned integer types that return the minimum number of bits required to represent an unsigned integer.
@bors r+ rollup=never p=5 |
@bors r- |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-compiletest
Area: The compiletest test runner
A-meta
Area: Issues & PRs about the rust-lang/rust repository itself
A-run-make
Area: port run-make Makefiles to rmake.rs
A-rustc-dev-guide
Area: rustc-dev-guide
A-rustdoc-json
Area: Rustdoc JSON backend
A-testsuite
Area: The testsuite used to check the correctness of rustc
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-rustdoc-frontend
Relevant to the rustdoc-frontend team, which will review and decide on the web UI/UX output.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Successful merges:
missing_fragment_specifier
an unconditional error #128425 (Makemissing_fragment_specifier
an unconditional error)extern "gpu-kernel"
feature test #142273 (tests: Minicoreextern "gpu-kernel"
feature test)library/Cargo.lock
#142276 (Update dependencies inlibrary/Cargo.lock
)citool
tests on theauto
branch #142282 (Only runcitool
tests on theauto
branch)//@ needs-target-std
compiletest directive #142297 (Implement//@ needs-target-std
compiletest directive)FunctionCx
from some codegen methods #142324 (Remove unneededFunctionCx
from some codegen methods)bit_width
for unsigned integer types #142328 (feat: Addbit_width
for unsigned integer types)Failed merges:
r? @ghost
@rustbot modify labels: rollup
Create a similar rollup