Commit Graph

147619 Commits

Author SHA1 Message Date
bors
6c90ac8d8f Auto merge of #123546 - Rajveer100:branch-for-issue-122128, r=onur-ozkan
Bootstrap: Check validity of `--target` and `--host` triples before starting a build

Resolves #122128

As described in the issue, validating the `target` and `host` triples would save a lot of time before actually starting a build. This would also check for custom targets by looking for a valid JSON spec if the specified target does not exist in the [supported](42825768b1/compiler/rustc_target/src/spec/mod.rs (L1401-L1689)) list of targets.
2024-04-28 04:16:05 +00:00
bors
2207179a59 Auto merge of #124454 - Mark-Simulacrum:bump-version, r=Mark-Simulacrum
Bump version to 1.80

https://forge.rust-lang.org/release/process.html#bump-the-stable-version-number-t-6-days-friday-the-week-before

r? `@Mark-Simulacrum`
2024-04-28 02:12:04 +00:00
Matthias Krüger
088753cb9a
Rollup merge of #124429 - Enselic:document-builder, r=Mark-Simulacrum
bootstrap: Document `struct Builder` and its fields

I'm exploring the code of bootstrap and had a bit of a hard time understanding exactly what `Builder` is for at first. I decided to help document it and its field to help future explorers.
2024-04-28 01:25:01 +02:00
Matthias Krüger
f17ce8bf7a
Rollup merge of #124242 - workingjubilee:describe-bootstrap-files-better, r=Mark-Simulacrum
bootstrap: Describe build_steps modules

One of my preferred ways to understand source code is to start with its API. This implies the code is documented reasonably accurately, even if it is a private API. The description of one of these modules had not been updated since 2015 and so was both terse and confusing, so I rewrote it. Then I noticed many others went unremarked, so I offered some remarks.
2024-04-28 01:25:00 +02:00
Matthias Krüger
8ef4a8df4b
Rollup merge of #123942 - onur-ozkan:x-vendor, r=Mark-Simulacrum
`x vendor`

This PR implements `x vendor` on bootstrap; enabling dependency vendoring without the need for developers to have `cargo` installed on their system (previously, we suggested running `cargo vendor ...` but now we can accomplish the same task with `x vendor`).

In addition, fixes #112391 problem.
2024-04-28 01:24:59 +02:00
Mark Rousskov
a7696ed4ab Bump version to 1.80 2024-04-27 19:03:50 -04:00
bors
aed2187d53 Auto merge of #124448 - matthiaskrgr:rollup-iloy9vz, r=matthiaskrgr
Rollup of 7 pull requests

Successful merges:

 - #124370 (Fix substitution parts having a shifted underline in some cases)
 - #124394 (Fix ICE on invalid const param types)
 - #124425 (Do not ICE on invalid consts when walking mono-reachable blocks)
 - #124434 (Remove lazycell and once_cell from compiletest dependencies)
 - #124437 (doc: Make the `mod.rs` in the comment point to the correct location)
 - #124443 (Elaborate in comment about `statx` probe)
 - #124445 (bootstrap: Change `global(true)` to `global = true` for flags for consistency)

r? `@ghost`
`@rustbot` modify labels: rollup
2024-04-27 20:49:06 +00:00
Matthias Krüger
6f8811d113
Rollup merge of #124445 - Enselic:global-true, r=onur-ozkan
bootstrap: Change `global(true)` to `global = true` for flags for consistency

All other arg properties use the `prop = value` style, which makes it slightly annoying to use the `prop(value)` only style for `global`. Change to `prop = value` also for `global` for consistency.
2024-04-27 20:46:10 +02:00
Matthias Krüger
8f962a6256
Rollup merge of #124434 - GKFX:remove-lazy-dependencies, r=jieyouxu
Remove lazycell and once_cell from compiletest dependencies

Use the standard library `OnceLock` instead of third-party equivalents. A macro is used for the regexes to make their initialization less unwieldy.
2024-04-27 20:46:09 +02:00
bors
825e831dc3 Auto merge of #124405 - RalfJung:miri-core-alloc-tests, r=clubby789
miri core/alloc tests: do not test a 2nd target

check-aux seems to be one of the slowest runners since we started running standard library tests in Miri on it. So maybe it'd be better to reduce test coverage a bit by not doing cross-target testing of core and alloc? I don't recall finding target-specific issues in these libraries ever (and we still have the extra test coverage via our [out-of-tree nightly tests](https://github.com/rust-lang/miri-test-libstd)). This gives us more buffer to deal with the fact that the number of tests we run will only grow over time.

Cc `@rust-lang/miri` `@rust-lang/infra`
2024-04-27 18:45:51 +00:00
Rajveer
09c076810c Bootstrap: Check validity of --target and --host triples before starting a build
Resolves #122128
2024-04-27 23:50:48 +05:30
Martin Nordholts
4c2a7d17cf bootstrap: Change global(true) to global = true for flags for consistency
All other arg properties use the `prop = value` style, which makes it
slightly annoying to use the `prop(value)` style for `global`. Change to
`prop = value` also for `global` for consistency.
2024-04-27 19:30:57 +02:00
Martin Nordholts
4e83776731 bootstrap: Document struct Builder and its fields 2024-04-27 19:27:59 +02:00
George Bateman
31af4f81ca
Remove lazycell and once_cell from compiletest dependencies 2024-04-27 12:38:51 +01:00
bors
261823eee7 Auto merge of #124430 - RalfJung:miri, r=RalfJung
Miri subtree update

r? `@ghost`
2024-04-27 09:32:46 +00:00
Matthias Krüger
cf07246ae9
Rollup merge of #124382 - petrochenkov:itemvisit, r=lcnr
ast: Generalize item kind visiting

And avoid duplicating logic for visiting `Item`s with different kinds (regular, associated, foreign).

The diff is better viewed with whitespace ignored.
2024-04-27 07:55:37 +02:00
bors
9ac33d9c33 Auto merge of #124416 - weihanglo:update-cargo, r=weihanglo
Update cargo

9 commits in c9392675917adc2edab269eea27c222b5359c637..b60a1555155111e962018007a6d0ef85207db463
2024-04-23 19:35:19 +0000 to 2024-04-26 16:37:29 +0000
- fix(toml): Remove underscore field support in 2024 (rust-lang/cargo#13804)
- fix: emit 1.77 syntax error only when msrv is incompatible (rust-lang/cargo#13808)
- docs(ref): Index differences between virtual / real manifests (rust-lang/cargo#13794)
- refactor(toml): extract dependency-to-source-id to function (rust-lang/cargo#13802)
- Add where lint was set (rust-lang/cargo#13801)
- fix(toml): Don't double-warn when underscore is used in workspace dep (rust-lang/cargo#13800)
- fix(toml): Be more forceful with underscore/dash redundancy (rust-lang/cargo#13798)
- Fix warning suppression for config.toml vs config compat symlinks (rust-lang/cargo#13793)
- Cleanup linting system (rust-lang/cargo#13797)

r? ghost
2024-04-27 02:30:40 +00:00
bors
80d1c8349a Auto merge of #124424 - jhpratt:rollup-o3ngkjy, r=jhpratt
Rollup of 5 pull requests

Successful merges:

 - #124341 (resolve: Remove two cases of misleading macro call visiting)
 - #124383 (Port run-make `--print=native-static-libs` to rmake.rs)
 - #124391 (`rustc_builtin_macros` cleanups)
 - #124408 (crashes: add more tests)
 - #124410 (PathBuf: replace transmuting by accessor functions)

r? `@ghost`
`@rustbot` modify labels: rollup
2024-04-27 00:26:48 +00:00
Jacob Pratt
c8beab7f46
Rollup merge of #124383 - Urgau:port-print-native-static-libs, r=jieyouxu
Port run-make `--print=native-static-libs` to rmake.rs

This PR port the run-make `--print=native-static-libs` test to rmake.rs

The dedup was really awful in the `Makefile`, I'm glad to finally have a proper dedup detection for this.

Related to https://github.com/rust-lang/rust/issues/121876

r? `@jieyouxu`
2024-04-26 19:25:55 -04:00
bors
aa6a8ee270 Auto merge of #124296 - cuviper:dist-cargo-tests, r=onur-ozkan
bootstrap: keep all cargo test files in dist rustc-src

Cargo tests use some files that we would otherwise exclude, especially
the `cargo init` tests that are meant to deal with pre-existing `.git`
and `.hg` repos and their ignore files. Keeping these in our dist
tarball doesn't take much space, and allows distro builds to run these
tests successfully.
2024-04-26 22:22:47 +00:00
Ralf Jung
454f09d891 env: split up Windows and Unix environment variable handling 2024-04-26 22:16:16 +02:00
Weihang Lo
c5eda4199c
Update cargo 2024-04-26 13:53:34 -04:00
Ralf Jung
26af88aced add test for concurrent env var access 2024-04-26 19:47:35 +02:00
Urgau
74cbc09fc9 Port run-make --print=native-static-libs to rmake.rs 2024-04-26 19:45:45 +02:00
bors
d7c89cfbf8 Auto merge of #3516 - RalfJung:pathbuf, r=RalfJung
add smoke tests for basic PathBuf interactions

I wrote these while debugging [this](https://github.com/rust-lang/miri-test-libstd/actions/runs/8849912635/job/24302962983); it turns out the issue is [more complicated](https://github.com/rust-lang/rust/issues/124409) but these tests still seemed worth keeping.
2024-04-26 15:47:17 +00:00
Ralf Jung
2935cd93c2 add smoke tests for basic PathBuf interactions 2024-04-26 17:44:37 +02:00
bors
1b3a32958b Auto merge of #122385 - lcnr:analyze-obligations-for-infer, r=compiler-errors
`obligations_for_self_ty`: use `ProofTreeVisitor` for nested goals

As always, dealing with proof trees continues to be a hacked together mess. After this PR and #124380 the only remaining blocker for core is https://github.com/rust-lang/trait-system-refactor-initiative/issues/90. There is also a `ProofTreeVisitor` issue causing an ICE when compiling `alloc` which I will handle in a separate PR. This issue likely affects coherence diagnostics more generally.

The core idea is to extend the proof tree visitor to support visiting nested candidates without using a `probe`. We then simply recurse into nested candidates if they are the only potentially applicable candidate for a given goal and check whether the self type matches the expected one.

For that to work, we need to improve `CanonicalState` to also handle unconstrained inference variables created inside of the trait solver. This is done by extending the `var_values` of `CanoncalState` with each fresh inference variables. Furthermore, we also store the state of all inference variables at the end of each probe. When recursing into `InspectCandidates` we then unify the values of all these states.

r? `@compiler-errors`
2024-04-26 15:37:05 +00:00
Ralf Jung
babead5b58 miri core/alloc tests: do not test a 2nd target 2024-04-26 16:33:37 +02:00
bors
9adafa7f8d Auto merge of #124321 - JoverZhang:run-make-support-tests, r=onur-ozkan
Add support for run-make-support unit tests to be run with bootstrap

The `run-make-support` library needs to run its unit tests to ensure it is correct.

Close #124267
2024-04-26 13:22:13 +00:00
Jover Zhang
c028782c67 Add support for run-make-support unit tests to be run with bootstrap command
Co-authored-by: Onur Özkan <onurozkan.dev@outlook.com>
2024-04-26 15:31:18 +08:00
The Miri Cronjob Bot
4be9c689f6 Merge from rustc 2024-04-26 05:08:12 +00:00
The Miri Cronjob Bot
4dcc2fac06 Preparing for merge from rustc 2024-04-26 04:58:30 +00:00
Vadim Petrochenkov
5be9fdd636 ast: Generalize item kind visiting
And avoid duplicating logic for visiting `Item`s with different kinds (regular, associated, foreign).
2024-04-25 22:49:58 +03:00
lcnr
03878c682a hir typeck: look into nested goals
uses a `ProofTreeVisitor` to look into nested
goals when looking at the pending obligations
during hir typeck. Used by closure signature
inference, coercion, and for async functions.
2024-04-25 19:44:00 +00:00
Vadim Petrochenkov
98804c1786 debuginfo: Stabilize -Z debug-macros, -Z collapse-macro-debuginfo and #[collapse_debuginfo]
`-Z debug-macros` is "stabilized" by enabling it by default and removing.

`-Z collapse-macro-debuginfo` is stabilized as `-C collapse-macro-debuginfo`.
It now supports all typical boolean values (`parse_opt_bool`) in addition to just yes/no.

Default value of `collapse_debuginfo` was changed from `false` to `external` (i.e. collapsed if external, not collapsed if local).
`#[collapse_debuginfo]` attribute without a value is no longer supported to avoid guessing the default.
2024-04-25 22:14:47 +03:00
bors
6a9758d4f3 Auto merge of #124058 - TechVest:master, r=fmease
Fix some typos in comments
2024-04-25 13:02:08 +00:00
bors
1c84675e1f Auto merge of #124368 - RalfJung:miri, r=RalfJung
Miri subtree update

r? `@ghost`
2024-04-25 10:59:13 +00:00
bors
d93f9ae3ee Auto merge of #3514 - RalfJung:hyperfine, r=RalfJung
CI: run benches with hyperfine rather than bash

The hyperfine installation is cached so this should not cost a lot of CI time.

This is step 1/2 to getting rid of the BASH variable hack.
2024-04-25 09:16:32 +00:00
Ralf Jung
505e4dd7ba CI: run benches with hyperfine rather than bash 2024-04-25 11:14:22 +02:00
bors
97132949f7 Auto merge of #3501 - RalfJung:tls-many-seeds, r=RalfJung
add a test for the TLS memory leak

This is a regression test for https://github.com/rust-lang/rust/issues/123583.
2024-04-25 08:14:58 +00:00
Ralf Jung
247e82cb83 run many-seeds tests at least a few times on all tier 1 targets 2024-04-25 09:53:34 +02:00
Ralf Jung
ea9cff254f add a test for the TLS memory leak 2024-04-25 09:51:15 +02:00
Ralf Jung
f38dba69b1 weak memory outdated loads: show where the load was from 2024-04-25 09:51:15 +02:00
bors
e22a73c6d0 Auto merge of #3512 - RalfJung:miri-script-build, r=RalfJung
make miri-script a workspace root

This is needed to make miri-script build on stable (as is done by the `./miri` script) when the parent package uses unstable cargo features.
2024-04-25 07:20:16 +00:00
bors
9d7a47fe31 Auto merge of #3513 - rust-lang:rustup-2024-04-25, r=RalfJung
Automatic Rustup
2024-04-25 06:48:37 +00:00
bors
c69c79d42a Auto merge of #3505 - RalfJung:ci, r=RalfJung
CI: don't run cron-fail-notify when the job just got canceled

Doesn't seem right to prepare a PR in that case
2024-04-25 06:16:47 +00:00
The Miri Cronjob Bot
258e5043a1 fmt 2024-04-25 05:05:41 +00:00
The Miri Cronjob Bot
ff6fc75781 Merge from rustc 2024-04-25 05:04:32 +00:00
The Miri Cronjob Bot
bed7caf206 Preparing for merge from rustc 2024-04-25 04:57:07 +00:00
Matthias Krüger
036bf570ad
Rollup merge of #124327 - Kobzol:ci-skip-jobs, r=pietroalbini
CI: implement job skipping in Python matrix calculation

This removes the `step` YAML anchor and the corresponding bash script.

Best reviewed commit-by-commit.

r? ```@pietroalbini```
2024-04-25 06:31:04 +02:00