Commit Graph

303456 Commits

Author SHA1 Message Date
Oli Scherer
800d80593e Merge pull request #4481 from RalfJung/read-write-truncate
non-deterministically truncate reads/writes
2025-07-21 13:11:38 +00:00
Maksim Bondarenkov
fa924641d6 opt-dist: add an option for setting path to stage0 root
in MSYS2 we have problems with stage0 for *-gnullvm hosts because prebuilt dist tarballs will be
available starting from 1.90.0-beta. also this change helps to match bootstrap.toml config
2025-07-21 15:58:38 +03:00
Maksim Bondarenkov
c193f3039f opt-dist: make artifact-dir an absolute path for opt-dist local
...like for CI environments. the same logic applied as for `build_dir`. fixes the issue where some
intermediate steps fail due to path being relative to an active directory
2025-07-21 15:47:37 +03:00
bors
3f9f20f71d Auto merge of #144154 - tgross35:update-builtins, r=tgross35
compiler-builtins subtree update

Subtree update of `compiler-builtins` to 2cdde03950.

Created using https://github.com/rust-lang/josh-sync.

Fixes: https://github.com/rust-lang/rust/issues/144076

r? `@ghost`
2025-07-21 12:47:33 +00:00
Tshepang Mbambo
44bec00385 Merge pull request #2515 from rust-lang/tshepang-patch-1
typo
2025-07-21 13:56:23 +02:00
Tshepang Mbambo
9ae298c875 typo 2025-07-21 13:55:55 +02:00
Timo
d4dea4bbe7 Fix false positive in useless_attribute with redundant_imports (#15318)
Fix false positive in `useless_attribute` with `redundant_imports`

Add `redundant_imports` to the list of allowed lints on use items to
prevent
`useless_attribute` from triggering false positives when
`#[expect(redundant_imports)]`
or similar attributes are used on use statements.

fixes rust-lang/rust-clippy#15316

---

changelog: [`useless_attribute`]: fix false positive when using
`#[expect(redundant_imports)]` and similar lint attributes on `use`
statements
2025-07-21 11:53:28 +00:00
Krishna Ketan Rai
92111dcc67 Fix false positive in useless_attribute with redundant_imports
The useless_attribute lint was incorrectly flagging #[expect(redundant_imports)]
as useless when applied to macro re-exports. This occurred because the lint
didn't recognize 'redundant_imports' as a valid rustc lint name.

This commit:
- Adds 'redundant_imports' to the list of known rustc lints in sym.rs
- Updates the useless_attribute lint to properly handle this case
- Adds a regression test to prevent future false positives
2025-07-21 17:13:43 +05:30
Jakub Beránek
ff2bfe09b1 Merge pull request #2514 from rust-lang/tshepang/for-ssh-protocol
add rdg push git config entry for git protocol pushers (again)
2025-07-21 13:29:46 +02:00
Tshepang Mbambo
c8ef2117d7 already documented elsewhere 2025-07-21 13:25:14 +02:00
roblabla
58537fb869 Fix broken TLS destructors on 32-bit win7
On the 32-bit win7 target, we use OS TLS instead of native TLS, due to
issues with how the OS handles alignment. Unfortunately, this caused
issues due to the TLS destructors not running, causing memory leaks
among other problems.

On Windows, to support OS TLS, the TlsAlloc family of function is used
by Rust. This function does not support TLS destructors at all. However,
rust has some code to emulate those destructors, by leveraging the TLS
support functionality found in the MSVC CRT (specifically, in tlssup.c
of the CRT). Specifically, the CRT provides the ability to register
callbacks that are called (among other things) on thread destruction. By
registering our own callback, we can run through a list of registered
destructors functions to execute.

To use this functionality, the user must do two things:

1. They must put the address to their callback in a section between
   `.CRT$XLB` and `.CRT$XLY`.
2. They must add a reference to `_tls_used` (or `__tls_used` on x86) to
   make sure the TLS support code in tlssup.c isn't garbage collected by
   the linker.

Prior to this commit, this second bit wasn't being done properly by the
Rust TLS support code. Instead of adding a reference to _tls_used, it
instead had a reference to its own callback to prevent it from getting
GC'd by the linker. While this is _also_ necessary, not having a
reference on _tls_used made the entire support non-functional.

This commit reworks the code to:

1. Add an unconditional `#[used]` attribute on the CALLBACK, which
   should be enough to prevent it from getting GC'd by the linker.
2. Add a reference to `_tls_used`, which should pull the TLS support
   code into the Rust programs and not let it be GC'd by the linker.
2025-07-21 13:11:47 +02:00
Tshepang Mbambo
4304b7b80a add rdg push git config entry for git protocol pushers (again) 2025-07-21 12:19:20 +02:00
Jieyou Xu
523594d7ae Update jobs.yml docs to reflect subset-modulo-carve-outs relationship 2025-07-21 18:06:07 +08:00
Jieyou Xu
fc4bf03a81 Remove spellcheck workflow
Unfortunately, the separate spellcheck GHA workflow does not really work
with homu, if we would like to enforce the invariant that PR CI is a
subset of Full CI (modulo carve outs).

This is not prejudice against a reland of a `typos`-based spellcheck, it
just probably has to go through the "usual" CI flow with bootstrap, so
that it can work with homu.
2025-07-21 18:06:07 +08:00
Jieyou Xu
21768bb380 Enforce PR CI jobs are a subset of Auto CI jobs (modulo carve-outs)
To prevent possibility of a PR with red PR-only CI passing Auto CI, then
all subsequent PR CI runs will be red until that is fixed.

Note that this is **not** a "strict" subset relationship: some jobs
necessarily have to differ under PR CI and Auto CI environments. For
instance:

- `x86_64-gnu-tools` will have auto-only env vars like
  `DEPLOY_TOOLSTATES_JSON: toolstates-linux.json`.
- `tidy` will want to `continue_on_error: true` in PR CI to allow for
  more "useful" compilation errors to also be reported, whereas it needs
  to `continue_on_error: false` in Auto CI to prevent wasting Auto CI
  resources.

The carve-outs are:

1. `env` variables.
2. `continue_on_error`.
2025-07-21 18:06:06 +08:00
Kivooeo
bcaa79529d removed tidy check on issues files 2025-07-21 14:52:30 +05:00
Evgenii Zheltonozhskii
3c76e3d002 Constify Try, From, TryFrom 2025-07-21 12:49:45 +03:00
Tshepang Mbambo
62e3a05291 Merge pull request #2512 from rust-lang/rustc-pull
Rustc pull update
2025-07-21 11:16:20 +02:00
Oli Scherer
4653b7acbd Stabilize const TypeId::of 2025-07-21 09:11:21 +00:00
Jieyou Xu
74ba9cbae4 Don't use another main test file as auxiliary
In this case, the exact extern crate isn't very important.

This is part of the changes needed to address the spurious failures from
a main test `../removing-extern-crate.rs` being both an auxiliary and a
main test file, causing fs races due to multiple `rustc` processes in
multiple test threads trying to build the main test file both as a main
test and also as an auxiliary at around the same time.
2025-07-21 16:58:54 +08:00
Tshepang Mbambo
4a45ab5ad4 Merge pull request #2513 from rust-lang/tshepang/typos
fix some typos
2025-07-21 10:50:11 +02:00
Tshepang Mbambo
79e3c7df0b fix some typos 2025-07-21 10:53:11 +02:00
bors
67819923ac Auto merge of #144238 - jhpratt:rollup-xb8aida, r=jhpratt
Rollup of 8 pull requests

Successful merges:

 - rust-lang/rust#144144 (tests: Skip supported-crate-types test on musl hosts)
 - rust-lang/rust#144159 (opt-dist: change build_dir field to be an actual build dir)
 - rust-lang/rust#144162 (Debug impls for DropElaborators)
 - rust-lang/rust#144189 (Add non-regression test for rust-lang/rust#144168)
 - rust-lang/rust#144216 (Don't consider unstable fields always-inhabited)
 - rust-lang/rust#144229 (Miri subtree update)
 - rust-lang/rust#144230 (Option::as_slice: fix comment)
 - rust-lang/rust#144235 (Fix run-make tests on musl hosts)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-07-21 08:42:52 +00:00
Hayashi Mikihiro
8be9187348 migrate generate new 2025-07-21 17:22:03 +09:00
bjorn3
1fd06975d0 Remove Retag for Unique 2025-07-21 08:08:41 +00:00
bjorn3
dadc4cae50 Remove each_linked_rlib_for_lto from CodegenContext 2025-07-21 07:58:44 +00:00
bjorn3
28ccfad3a8 Remove each_linked_rlib_for_lto from CodegenContext 2025-07-21 07:58:44 +00:00
bjorn3
1a6f941d2b Move exported_symbols_for_lto out of CodegenContext 2025-07-21 07:58:44 +00:00
bjorn3
ecab766c2c Move exported_symbols_for_lto out of CodegenContext 2025-07-21 07:58:44 +00:00
bjorn3
6e757354ad Merge exported_symbols computation into exported_symbols_for_lto
And move exported_symbols_for_lto call from backends to cg_ssa.
2025-07-21 07:58:44 +00:00
bjorn3
df5367810b Merge exported_symbols computation into exported_symbols_for_lto
And move exported_symbols_for_lto call from backends to cg_ssa.
2025-07-21 07:58:44 +00:00
bjorn3
1c8dc6f440 Move LTO symbol export calculation from backends to cg_ssa 2025-07-21 07:58:44 +00:00
bjorn3
803ada77a5 Move LTO symbol export calculation from backends to cg_ssa 2025-07-21 07:58:44 +00:00
bjorn3
2ad7930b40 Remove worker id
It isn't used anywhere. Also inline free_worker into the only call site.
2025-07-21 07:58:44 +00:00
bjorn3
8b8ffa8b4e Merge modules and cached_modules for fat LTO
The modules vec can already contain serialized modules and there is no
need to distinguish between cached and non-cached cgus at LTO time.
2025-07-21 07:58:44 +00:00
bjorn3
112799e637 Merge modules and cached_modules for fat LTO
The modules vec can already contain serialized modules and there is no
need to distinguish between cached and non-cached cgus at LTO time.
2025-07-21 07:58:44 +00:00
Laurențiu Nicola
8f67bcf4b0 Merge pull request #20268 from lnicola/sync-from-rust
minor: Sync from downstream
2025-07-21 06:58:10 +00:00
Laurențiu Nicola
da90db796d Downgrade ra-ap-rustc_parse_format 2025-07-21 09:46:53 +03:00
Laurențiu Nicola
2050358679 Revert "Bump rustc-literal-escaper"
This reverts commit 9f3adc540b51a4c2d0472d94033f6d9147b36f6e.
2025-07-21 09:31:28 +03:00
Laurențiu Nicola
f2633640d6 Bump rustc-literal-escaper 2025-07-21 09:27:37 +03:00
Hayashi Mikihiro
54fa2ad66e Migrate AstNodeEdit 2025-07-21 15:26:48 +09:00
Laurențiu Nicola
1482809fc1 Bump rustc crates 2025-07-21 09:19:24 +03:00
Laurențiu Nicola
2f14119240 Merge from rust-lang/rust 2025-07-21 09:18:22 +03:00
Laurențiu Nicola
750c1e9c39 Preparing for merge from rust-lang/rust 2025-07-21 09:17:54 +03:00
Ralf Jung
9ef15d2302 Merge pull request #4486 from rust-lang/rustup-2025-07-21
Automatic Rustup
2025-07-21 06:09:06 +00:00
The Miri Cronjob Bot
e3e711b2ca Merge from rustc 2025-07-21 05:09:19 +00:00
The Miri Cronjob Bot
72ba7c594d Preparing for merge from rustc 2025-07-21 05:01:50 +00:00
Shoyu Vanilla (Flint)
4bbe74bb6c Merge pull request #20256 from A4-Tacks/gen-mut-trait-deref
Add Deref -> DerefMut for generate_mut_trait_impl
2025-07-21 04:31:24 +00:00
Shoyu Vanilla (Flint)
33d62b5fba Merge pull request #20262 from ChayimFriedman2/goto-ref-raw
fix: Fix search of raw labels and lifetimes
2025-07-21 04:30:42 +00:00
The rustc-josh-sync Cronjob Bot
ad20b064c3 Merge ref '460259d14de0' from rust-lang/rust
Pull recent changes from https://github.com/rust-lang/rust via Josh.

Upstream ref: 460259d14d
Filtered ref: 599ee17eb87c83f97eb37fd9fe264da65d4c9461

This merge was created using https://github.com/rust-lang/josh-sync.
2025-07-21 04:17:50 +00:00