about summary refs log tree commit diff
AgeCommit message (Collapse)AuthorLines
2025-01-27Rollup merge of #136118 - oli-obk:push-qsslxsopnrmr, r=ZalatharGuillaume Gomez-21/+33
Change `collect_and_partition_mono_items` tuple return type to a struct https://github.com/rust-lang/rust/pull/133429 will add a new field to this tuple, so it seems prudent to turn it into a struct first to avoid confusion about what the tuple elements mean.
2025-01-27Rollup merge of #136114 - compiler-errors:more-idents, r=jieyouxuGuillaume Gomez-90/+97
Use identifiers more in diagnostics code This should make the diagnostics code slightly more correct when rendering idents in mixed crate edition situations. Kinda a no-op, but a cleanup regardless. r? oli-obk or reassign
2025-01-27Rollup merge of #136112 - fmease:clean-up-all-dead-files-in-ui-tests, ↵Guillaume Gomez-3628/+45
r=compiler-errors Clean up all dead files inside `tests/ui/` While rebasing #135860 I noticed that there are several dead `*.stderr` files inside `tests/ui/`. When I checked thoroughly, I found 69 dead `*.$revision.stderr` files, 3 other dead `*.stderr` files and one dead `*.rs` file. Prior to #134808, compiletest's `--bless` didn't remove dead `*.stderr` files when the set of revisions changed in any way (renamings, removals, additions, …) which explains their existence. Regarding the dead `*.rs` file, that one was located inside an `auxiliary/` directory (together with a `*.stderr` file) despite not being meant to be an auxiliary file (it's not referenced by any `//@ aux-*`, it has an accompanying `*.stderr` file and it's obvious from looking at #111056 which added it). Ideally compiletest or tidy would forbid `*.std{out,err}` files inside `auxiliary/` dirs, that would've caught it. I moved it, updated it and turned it into a proper UI test. --- How to reproduce: 1. Run `rm tests/ui/**/*.stderr` 2. Run `./x test tests/ui --bless` (or similar) 3. Manually / semi-automatically go through all tests that were ignored (likely due to your OS etc. not matching) and restore any stderr files that were overzealously removed --- r? compiler
2025-01-27Rollup merge of #136082 - Zalathar:iter-nodes, r=oli-obkGuillaume Gomez-23/+18
Incorporate `iter_nodes` into `graph::DirectedGraph` This helper method iterates over all node IDs in the dense range `0..num_nodes`. In practice, we have a lot of graph-algorithm code that already assumes that nodes are densely numbered, by using `num_nodes` to allocate per-node indexed data structures. So I don't think this is actually a substantial change to the de-facto semantics of `graph::DirectedGraph`. --- Resolves a FIXME from #135481.
2025-01-27Rollup merge of #136064 - veluca93:tf11-fntrait-note, r=oli-obkGuillaume Gomez-13/+47
Add a suggestion to cast target_feature fn items to fn pointers. See https://github.com/rust-lang/rust/pull/134090#issuecomment-2612197095 for the motivation behind this suggestion. r? oli-obk
2025-01-27Rollup merge of #136037 - no1wudi:doc, r=jieyouxuGuillaume Gomez-54/+51
Mark all NuttX targets as tier 3 target and support the standard library The support for standard library added by https://github.com/rust-lang/rust/pull/130595.
2025-01-27Rollup merge of #135988 - bjorn3:workaround_parallel_rustc_crash, r=lqdGuillaume Gomez-15/+53
Add a workaround for parallel rustc crashing when there are delayed bugs This doesn't fix the root cause of this crash, but at least stops it from happening for the time being. Workaround for https://github.com/rust-lang/rust/issues/135870
2025-01-27Rollup merge of #135876 - usamoi:mpmc-doc, r=tgross35Guillaume Gomez-4/+12
fix doc for std::sync::mpmc fix document of `std::sync::mpmc` (tracked in https://github.com/rust-lang/rust/issues/126840)
2025-01-27Rollup merge of #135807 - jhpratt:phantom-variance, r=AmanieuGuillaume Gomez-0/+267
Implement phantom variance markers ACP accepted https://github.com/rust-lang/libs-team/issues/488 Tracking issue #135806
2025-01-27Rollup merge of #135773 - hkBst:patch-10, r=tgross35Guillaume Gomez-4/+9
Clarify WindowsMut (Lending)Iterator fixes #133628
2025-01-27Auto merge of #136024 - GuillaumeGomez:cg_gcc-subtree, r=GuillaumeGomezbors-41/+85
Update rustc_codegen_gcc subtree cc `@antoyo`
2025-01-27Clarify WindowsMut (Lending)IteratorMarijn Schouten-4/+9
fixes 133628
2025-01-27Change `collect_and_partition_mono_items` tuple return type to a structOli Scherer-21/+33
2025-01-27Auto merge of #136116 - fmease:rollup-c8pk3mj, r=fmeasebors-576/+974
Rollup of 8 pull requests Successful merges: - #126604 (Uplift `clippy::double_neg` lint as `double_negations`) - #135158 (Add `TooGeneric` variant to `LayoutError` and emit `Unknown`) - #135635 (Move `std::io::pipe` code into its own file) - #136072 (add two old crash tests) - #136079 (compiler_fence: fix example) - #136091 (Add some tracing to core bootstrap logic) - #136097 (rustc_ast: replace some len-checks + indexing with slice patterns etc.) - #136101 (triagebot: set myself on vacation) r? `@ghost` `@rustbot` modify labels: rollup
2025-01-27Auto merge of #135937 - bjorn3:separate_coretests_crate, r=jieyouxu,tgross35bors-77/+52
Put the core unit tests in a separate coretests package Having standard library tests in the same package as a standard library crate has bad side effects. It causes the test to have a dependency on a locally built standard library crate, while also indirectly depending on it through libtest. Currently this works out fine in the context of rust's build system as both copies are identical, but for example in cg_clif's tests I've found it basically impossible to compile both copies with the exact same compiler flags and thus the two copies would cause lang item conflicts. This PR moves the tests of libcore to a separate package which doesn't depend on libcore, thus preventing the duplicate crates even when compiler flags don't exactly match between building the sysroot (for libtest) and building the test itself. The rest of the standard library crates do still have this issue however.
2025-01-27fix doc for std::sync::mpmcusamoi-4/+12
2025-01-27Rollup merge of #136101 - jieyouxu:away, r=jieyouxuLeón Orell Valerian Liehr-1/+2
triagebot: set myself on vacation Will be back 02-01.
2025-01-27Rollup merge of #136097 - yotamofek:check-len-and-index, r=petrochenkovLeón Orell Valerian Liehr-10/+10
rustc_ast: replace some len-checks + indexing with slice patterns etc.
2025-01-27Rollup merge of #136091 - jieyouxu:core-tracing, r=clubby789León Orell Valerian Liehr-50/+165
Add some tracing to core bootstrap logic Follow-up to #135391. ### Summary Add some initial tracing logging to bootstrap, focused on the core logic (in this PR). Also: - Adjusted tracing-tree style to not use indent lines (I found that more distracting than helpful). - Avoid glob-importing `tracing` items. - Improve the rustc-dev-guide docs on bootstrap tracing. ### Example output ```bash $ BOOTSTRAP_TRACING=bootstrap=TRACE ./x check src/bootstrap ``` ![Example bootstrap tracing output](https://github.com/user-attachments/assets/0be39042-0822-44b6-9451-30427cfea156) r? bootstrap
2025-01-27Rollup merge of #136079 - RalfJung:compiler-fence-example, r=jhprattLeón Orell Valerian Liehr-13/+13
compiler_fence: fix example The old example was wrong, an acquire fence is required in the signal handler. To make the point more clear, I changed the "data" variable to use non-atomic accesses. Fixes https://github.com/rust-lang/rust/issues/133014
2025-01-27Rollup merge of #136072 - cyrgani:old-crash-tests, r=WaffleLapkinLeón Orell Valerian Liehr-0/+16
add two old crash tests This is for #108248 and #132826.
2025-01-27Rollup merge of #135635 - tbu-:pr_io_pipe, r=joboetLeón Orell Valerian Liehr-272/+281
Move `std::io::pipe` code into its own file Also update the docs for the new location, create a section "Platform-specific behavior", don't hide required imports for code examples.
2025-01-27Rollup merge of #135158 - FedericoBruzzone:master, r=lukas-codeLeón Orell Valerian Liehr-58/+233
Add `TooGeneric` variant to `LayoutError` and emit `Unknown` What's in this PR? - Add `TooGeneric` variant to `LayoutError` and emit `Unknown` one With this PR these issues and their respective ICEs are resolved: - fixes https://github.com/rust-lang/rust/issues/135020 - fixes https://github.com/rust-lang/rust/issues/135138
2025-01-27Rollup merge of #126604 - kadiwa4:uplift_double_negation, r=nnethercoteLeón Orell Valerian Liehr-172/+254
Uplift `clippy::double_neg` lint as `double_negations` Warns about cases like this: ```rust fn main() { let x = 1; let _b = --x; //~ WARN use of a double negation } ``` The intent is to keep people from thinking that `--x` is a prefix decrement operator. `++x`, `x++` and `x--` are invalid expressions and already have a helpful diagnostic. I didn't add a machine-applicable suggestion to the lint because it's not entirely clear what the programmer was trying to achieve with the `--x` operation. The code that triggers the lint should always be reviewed manually. Closes #82987
2025-01-27Make a previously unreachable UI test reachableLeón Orell Valerian Liehr-36/+44
2025-01-27Remove all dead files inside tests/ui/León Orell Valerian Liehr-3592/+1
2025-01-27Remove redundant to_ident_string callsMichael Goulet-18/+14
2025-01-27Use identifiers in diagnostics more oftenMichael Goulet-72/+83
2025-01-27Mark all NuttX targets as tier 3 target and support the standard libraryHuang Qi-54/+51
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2025-01-26compiler_fence: fix exampleRalf Jung-13/+13
2025-01-27Add `TooGeneric` variant to `LayoutError` and emit `Unknown` oneFedericoBruzzone-58/+233
- `check-pass` test for a MRE of #135020 - fail test for #135138 - switch to `TooGeneric` for checking CMSE fn signatures - switch to `TooGeneric` for compute `SizeSkeleton` (for transmute) - fix broken tests
2025-01-26Auto merge of #104693 - jhorstmann:use-high-bit-of-mask-for-select, ↵bors-172/+280
r=workingjubilee Consistently use the highest bit of vector masks when converting to i1 vectors This improves the codegen for vector `select`, `gather`, `scatter` and boolean reduction intrinsics and fixes rust-lang/portable-simd#316. The current behavior of most mask operations during llvm codegen is to truncate the mask vector to <N x i1>, telling llvm to use the least significat bit. The exception is the `simd_bitmask` intrinsics, which already used the most signifiant bit. Since sse/avx instructions are defined to use the most significant bit, truncating means that llvm has to insert a left shift to move the bit into the most significant position, before the mask can actually be used. Similarly on aarch64, mask operations like blend work bit by bit, repeating the least significant bit across the whole lane involves shifting it into the sign position and then comparing against zero. By shifting before truncating to <N x i1>, we tell llvm that we only consider the most significant bit, removing the need for additional shift instructions in the assembly.
2025-01-26Auto merge of #135783 - compiler-errors:cache-in-closure-binder, r=lcnrbors-1/+144
Add cache to `FoldEscapingRegions` Fixes #135780 ty `@lqd` for the tests
2025-01-27triagebot: set myself on vacation许杰友 Jieyou Xu (Joe)-1/+2
2025-01-26Add cache to FoldEscapingRegionsMichael Goulet-1/+144
2025-01-27rustc-dev-guide: update bootstrap tracing docs许杰友 Jieyou Xu (Joe)-32/+58
2025-01-27bootstrap: add more logging许杰友 Jieyou Xu (Joe)-2/+93
2025-01-27bootstrap: adjust config file cascading fallback comment许杰友 Jieyou Xu (Joe)-1/+5
2025-01-27bootstrap: adjust tracing style许杰友 Jieyou Xu (Joe)-11/+6
2025-01-27bootstrap: avoid glob imports in `main` binary许杰友 Jieyou Xu (Joe)-5/+4
2025-01-26rustc_ast: replace some len-checks + indexing with slice patterns etc. 🧹Yotam Ofek-10/+10
2025-01-26Consistently use the most significant bit of vector masksJörn Horstmann-172/+280
This improves the codegen for vector `select`, `gather`, `scatter` and boolean reduction intrinsics and fixes rust-lang/portable-simd#316. The current behavior of most mask operations during llvm codegen is to truncate the mask vector to <N x i1>, telling llvm to use the least significat bit. The exception is the `simd_bitmask` intrinsics, which already used the most signifiant bit. Since sse/avx instructions are defined to use the most significant bit, truncating means that llvm has to insert a left shift to move the bit into the most significant position, before the mask can actually be used. Similarly on aarch64, mask operations like blend work bit by bit, repeating the least significant bit across the whole lane involves shifting it into the sign position and then comparing against zero. By shifting before truncating to <N x i1>, we tell llvm that we only consider the most significant bit, removing the need for additional shift instructions in the assembly.
2025-01-26Auto merge of #135764 - nikic:llvm-20-test-fixes, r=wesleywiserbors-15/+105
Fix tests on LLVM 20 For sparcv8plus.rs, duplicate the test for LLVM 19 and LLVM 20. LLVM 20 resolves one of the FIXME in the test. For x86_64-bigint-add.rs split the check lines for LLVM 19 and LLVM 20. The difference in codegen here is due to a difference in unroll factor, which I believe is not what the test is interested in. Fixes https://github.com/rust-lang/rust/issues/132957. Fixes https://github.com/rust-lang/rust/issues/133754.
2025-01-26Add regression testbjorn3-0/+23
2025-01-26Auto merge of #136087 - jhpratt:rollup-tam1mzn, r=jhprattbors-155/+309
Rollup of 7 pull requests Successful merges: - #133631 (Support QNX 7.1 with `io-sock`+libstd and QNX 8.0 (`no_std` only)) - #134358 (compiler: Set `target_abi = "ilp32e"` on all riscv32e targets) - #135812 (Fix GDB `OsString` provider on Windows ) - #135842 (TRPL: more backward-compatible Edition changes) - #135946 (Remove extra whitespace from rustdoc breadcrumbs for copypasting) - #135953 (ci.py: check the return code in `run-local`) - #136019 (Add an `unchecked_div` alias to the `Div<NonZero<_>>` impls) r? `@ghost` `@rustbot` modify labels: rollup
2025-01-26Update `std::io::{pipe, PipeReader, PipeWriter}` docs the new locationTobias Bucher-16/+20
Also create a section "Platform-specific behavior", don't hide required imports for code examples.
2025-01-26Move `std::io::pipe` code into its own fileTobias Bucher-272/+277
2025-01-26implement lint `double_negations`Kalle Wachsmuth-16/+159
2025-01-26remove `clippy::double_neg`Kalle Wachsmuth-146/+93
2025-01-26unrelated cleanupKalle Wachsmuth-10/+2