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 7 pull requests #129057

Closed
wants to merge 26 commits into from

Conversation

GuillaumeGomez
Copy link
Member

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

ChrisDenton and others added 26 commits August 9, 2024 10:43
doing so requires overwriting global cache entries and
generally adds significant complexity to the solver. This is
also only ever done for root goals, so it feels easier to wrap
the `evaluate_canonical_goal` in an ordinary query if
necessary.
this allows us to only sometimes disable the global cache.
this makes it easier to maintain and modify going forward.
There may be a small performance cost as we now need to
access the provisional cache *and* walk through the stack
to detect cycles. However, the provisional cache should be
mostly empty and the stack should only have a few elements
so the performance impact is likely minimal.

Given the complexity of the search graph maintainability
trumps linear performance improvements.
Relevant for the deprecation of `CommandExt::before_exit` in rust-lang#125970.
…er error

This doesn't work for translated compiler error messages.
This function is called for both compiler and non-compiler output, so if the
line isn't recognized as JSON from the compiler then just print it as-is.
The JSON messages parsed by this file are from the _compiler_, not from
libtest.
… is used with other output formats than HTML
…trochenkov

Allow to customize `// TODO:` comment for deprecated safe autofix

Relevant for the deprecation of `CommandExt::before_exit` in rust-lang#125970.

Tracking:
- rust-lang#124866
…youxu

Migrate `remap-path-prefix-dwarf` `run-make` test to rmake

Part of rust-lang#121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html).

Possibly my proudest branch name yet.

try-job: aarch64-apple
try-job: armhf-gnu
try-job: test-various
try-job: x86_64-gnu-llvm-18
…rrors

`-Znext-solver` caching

This PR has two major changes while also fixing multiple issues found via fuzzing.

The main optimization is the ability to not discard provisional cache entries when popping the highest cycle head the entry depends on. This fixes the hang in Fuchsia with `-Znext-solver=coherence`.

It also bails if the result of a fixpoint iteration is ambiguous, even without reaching a fixpoint. This is necessary to avoid exponential blowup if a coinductive cycle results in ambiguity, e.g. due to unknowable candidates in coherence.

Updating stack entries pretty much exclusively happens lazily now, so `fn check_invariants` ended up being mostly useless and I've removed it. See https://gist.github.com/lcnr/8de338fdb2685581e17727bbfab0622a for the invariants we would be able to assert with it.

For a general overview, see the in-process update of the relevant rustc-dev-guide chapter: https://hackmd.io/1ALkSjKlSCyQG-dVb_PUHw

r? `@compiler-errors`
…k-Simulacrum

Add windows-targets crate to std's sysroot

With this PR, when backtrace is used as a crate from crates.io it will (once updated) use the real [windows-targets](https://crates.io/crates/windows-targets) crate. But when used from std it'll use std's replacement version.

This allows sharing our customized `windows_tagets::link!` macro between std proper and the backtrace crate when used as part of std, ensuring a consistent linking story. This will be especially important once we move to using [`raw-dylib`](https://doc.rust-lang.org/reference/items/external-blocks.html#dylib-versus-raw-dylib) by default.
…joboet

Add `#[must_use]` attribute to `Coroutine` trait

[Coroutines tracking issue](rust-lang#43122)

Like closures (`FnOnce`, `AsyncFn`, etc.), coroutines are lazy and do nothing unless called (resumed). Closure traits like `FnOnce` have `#[must_use = "closures are lazy and do nothing unless called"]` to catch likely bugs for users of APIs that produce them. This PR adds such a `#[must_use]` attribute to `trait Coroutine`.
compiletest: Don't panic on unknown JSON-like output lines

The `json::extract_rendered` function is called for both compiler output and non-compiler output, so it's inappropriate to panic just because a line starting with `{` didn't contain a compiler output message.

It is called from two places: when checking the output of a `ui` test process, and when printing the output of an arbitrary non-passing `ProcRes`. So unfortunately there's currently no easy way to know for sure whether it is seeing compiler output or not. Fortunately, neither call site appears to be relying on this panic; it's just an overzealous internal check.

Fixes rust-lang#126373.
…finition-warning, r=notriddle

Emit a warning instead of an error if `--generate-link-to-definition` is used with other output formats than HTML

Fixes rust-lang/docs.rs#2581.

It's a bit weird to emit an error in this case anyway, a warning is more than enough.

r? `@notriddle`
@rustbot rustbot added A-run-make Area: port run-make Makefiles to rmake.rs A-testsuite Area: The testsuite used to check the correctness of rustc O-windows Operating system: Windows S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 13, 2024
@rustbot rustbot added 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. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver) rollup A PR which is a rollup labels Aug 13, 2024
@GuillaumeGomez
Copy link
Member Author

@bors r+ p=5 rollup=never

@bors
Copy link
Contributor

bors commented Aug 13, 2024

📌 Commit d3a37ef 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 Aug 13, 2024
@bors
Copy link
Contributor

bors commented Aug 13, 2024

⌛ Testing commit d3a37ef with merge a1df0fa...

bors added a commit to rust-lang-ci/rust that referenced this pull request Aug 13, 2024
…llaumeGomez

Rollup of 7 pull requests

Successful merges:

 - rust-lang#127857 (Allow to customize `// TODO:` comment for deprecated safe autofix)
 - rust-lang#128410 (Migrate `remap-path-prefix-dwarf` `run-make` test to rmake)
 - rust-lang#128828 (`-Znext-solver` caching)
 - rust-lang#128873 (Add windows-targets crate to std's sysroot)
 - rust-lang#129034 (Add `#[must_use]` attribute to `Coroutine` trait)
 - rust-lang#129049 (compiletest: Don't panic on unknown JSON-like output lines)
 - rust-lang#129050 (Emit a warning instead of an error if `--generate-link-to-definition` is used with other output formats than HTML)

r? `@ghost`
`@rustbot` modify labels: rollup
@rust-log-analyzer
Copy link
Collaborator

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

Click to see the possible cause of the failure (guessed by this bot)
+ .jiri_root/bin/jiri update -autoupdate=false
[18:47:06.761] Updating all projects
[18:49:27.795] Wait for 1m4s before next attempt...: Cloning https://fuchsia.googlesource.com/third_party/inih

ERROR: 'git clone --no-checkout --filter=blob:none https://fuchsia.googlesource.com/third_party/inih /checkout/obj/fuchsia/third_party/inih' failed:

stderr:
Cloning into '/checkout/obj/fuchsia/third_party/inih'...
error: RPC failed; HTTP 503 curl 22 The requested URL returned error: 503
---
command fail error: exit status 128

[18:49:34.835] Wait for 1m4s before next attempt...: Cloning https://fuchsia.googlesource.com/shac-project/generic-checks

ERROR: 'git clone --no-checkout --filter=blob:none https://fuchsia.googlesource.com/third_party/github.com/google/bt-test-interfaces /checkout/obj/fuchsia/third_party/github.com/google/bt-test-interfaces/src' failed:

stderr:
Cloning into '/checkout/obj/fuchsia/third_party/github.com/google/bt-test-interfaces/src'...
error: RPC failed; HTTP 503 curl 22 The requested URL returned error: 503
error: RPC failed; HTTP 503 curl 22 The requested URL returned error: 503
fatal: expected flush after ref listing

command fail error: exit status 128

[18:49:37.510] Wait for 1m4s before next attempt...: Cloning https://fuchsia.googlesource.com/third_party/github.com/google/bt-test-interfaces

ERROR: 'git clone --no-checkout --filter=blob:none https://fuchsia.googlesource.com/third_party/github.com/jd/tenacity /checkout/obj/fuchsia/third_party/github.com/jd/tenacity/src' failed:

stderr:
stderr:
Cloning into '/checkout/obj/fuchsia/third_party/github.com/jd/tenacity/src'...
fatal: expected flush after ref listing

command fail error: exit status 128


[18:49:38.027] Wait for 1m4s before next attempt...: Cloning https://fuchsia.googlesource.com/third_party/github.com/jd/tenacity
[18:50:31.819] Attempt 2/3: Cloning https://fuchsia.googlesource.com/third_party/inih

[18:50:32.001] Attempt 2/3: Cloning https://fuchsia.googlesource.com/third_party/spirv-cross


[18:50:38.841] Attempt 2/3: Cloning https://fuchsia.googlesource.com/shac-project/generic-checks

[18:50:41.511] Attempt 2/3: Cloning https://fuchsia.googlesource.com/third_party/github.com/google/bt-test-interfaces

[18:50:42.028] Attempt 2/3: Cloning https://fuchsia.googlesource.com/third_party/github.com/jd/tenacity
[18:51:01.937] Wait for 1m4s before next attempt...: Cloning https://fuchsia.googlesource.com/third_party/inih


ERROR: 'git clone --no-checkout --filter=blob:none https://fuchsia.googlesource.com/third_party/inih /checkout/obj/fuchsia/third_party/inih' failed:

stderr:
Cloning into '/checkout/obj/fuchsia/third_party/inih'...
error: RPC failed; HTTP 503 curl 22 The requested URL returned error: 503
---
command fail error: exit status 128

[18:51:02.172] Wait for 1m4s before next attempt...: Cloning https://fuchsia.googlesource.com/third_party/spirv-cross

[18:51:12.198] Wait for 1m4s before next attempt...: Cloning https://fuchsia.googlesource.com/third_party/github.com/jd/tenacity

ERROR: 'git clone --no-checkout --filter=blob:none https://fuchsia.googlesource.com/third_party/github.com/jd/tenacity /checkout/obj/fuchsia/third_party/github.com/jd/tenacity/src' failed:

stderr:
stderr:
Cloning into '/checkout/obj/fuchsia/third_party/github.com/jd/tenacity/src'...
fatal: error reading section header 'shallow-info'

command fail error: exit status 128


[18:52:05.952] Attempt 3/3: Cloning https://fuchsia.googlesource.com/third_party/inih

[18:52:06.172] Attempt 3/3: Cloning https://fuchsia.googlesource.com/third_party/spirv-cross

[18:52:16.200] Attempt 3/3: Cloning https://fuchsia.googlesource.com/third_party/github.com/jd/tenacity

[18:59:25.865] Jiri packages are not fetched due to fatal errors when updating projects.
[18:59:25.865] Jiri hooks are not run due to fatal errors when updating projects or packages
ERROR: Creating project "third_party/spirv-cross": "Cloning https://fuchsia.googlesource.com/third_party/spirv-cross" failed 3 times in a row, Last error: 'git clone --no-checkout --filter=blob:none https://fuchsia.googlesource.com/third_party/spirv-cross /checkout/obj/fuchsia/third_party/spirv-cross' failed:

stderr:
Cloning into '/checkout/obj/fuchsia/third_party/spirv-cross'...
error: RPC failed; HTTP 503 curl 22 The requested URL returned error: 503

@bors
Copy link
Contributor

bors commented Aug 13, 2024

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Aug 13, 2024
@GuillaumeGomez
Copy link
Member Author

I think something is off with fuschia here. It's been failing a lot lately.

cc @rust-lang/infra

@GuillaumeGomez GuillaumeGomez deleted the rollup-q2yyzru branch August 13, 2024 19:05
@MarcoIeni
Copy link
Member

Yes. Discussion here. It should be fixed now 👍

@GuillaumeGomez
Copy link
Member Author

Awesome, thanks!

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-testsuite Area: The testsuite used to check the correctness of rustc O-windows Operating system: Windows rollup A PR which is a rollup 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. 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.