about summary refs log tree commit diff
path: root/src/tools
AgeCommit message (Collapse)AuthorLines
2024-08-28Remove invalid testsAli Bektas-72/+0
2024-08-28Make almost every client config globalAli Bektas-210/+211
2024-08-28Make completion_* localAli Bektas-72/+76
2024-08-28Make diagnostics_* localAli Bektas-32/+33
2024-08-28Make workspace_symbol_search_* workspaceAli Bektas-15/+15
2024-08-28Make procMacro_* workspaceAli Bektas-7/+11
2024-08-28Make rustc_* workspaceAli Bektas-11/+11
2024-08-28Make runnables workspaceAli Bektas-22/+24
2024-08-28Make check workspaceAli Bektas-85/+89
2024-08-28Make checkOnSave workspaceAli Bektas-8/+9
2024-08-28Make cargo_ workspace againAli Bektas-157/+190
2024-08-29Separate core search logic with search uiFolyd-4/+3
2024-08-28Rollup merge of #129613 - RalfJung:interpret-target-feat, r=saethlinMatthias Krüger-6/+40
interpret: do not make const-eval query result depend on tcx.sess The check against calling functions with missing target features uses `tcx.sess` to determine which target features are available. However, this can differ between different crates in a crate graph, so the same const-eval query can come to different conclusions about whether a constant evaluates successfully or not -- which is bad, we should consistently get the same result everywhere.
2024-08-28Rollup merge of #129608 - RalfJung:const-eval-ub-checks, r=saethlinMatthias Krüger-0/+4
const-eval: do not make UbChecks behavior depend on current crate's flags Fixes https://github.com/rust-lang/rust/issues/129552 Let's see if we can get away with just always enabling these checks.
2024-08-28Auto merge of #3837 - JoJoDeveloping:tb-compacting-provenance-gc, r=RalfJungbors-17/+237
Make Tree Borrows Provenance GC compact the tree Follow-up on #3833 and #3835. In these PRs, the TB GC was fixed to no longer cause a stack overflow. One test that motivated it was the test `fill::horizontal_line` in [`tiny-skia`](https://github.com/RazrFalcon/tiny-skia). But not causing stack overflows was not a large improvents, since it did not fix the fundamental issue: The tree was too large. The test now ran, but it required gigabytes of memory and hours of time (only for it to be OOM-killed 🤬), whereas it finishes within 24 seconds in Stacked Borrows. With this merged, it finishes in about 40 seconds under TB. The problem in that test was that it used [`slice::chunked`](https://doc.rust-lang.org/std/primitive.slice.html#method.chunks) to iterate a slice in chunks. That iterator is written to reborrow at each call to `next`, which creates a linear tree with a bunch of intermediary nodes, which also fragments the `RangeMap` for that allocation. The solution is to now compact the tree, so that these interior nodes are removed. Care is taken to not remove nodes that are protected, or that otherwise restrict their children. I am currently only 99% sure that this is sound, and I do also think that this could compact even more. So `@Vanille-N` please also have a look at whether I got the compacting logic right. For a more visual comparison, [here is a gist](https://gist.github.com/JoJoDeveloping/ae4a7f7c29335a4c233ef42d2f267b01) of what the tree looks like at one point during that test, with and without compacting. This new GC requires a different iteration order during accesses (since the current one can make the error messages non-deterministic), so it is rebased on top of #3843 and requires that PR to be merged first.
2024-08-28address nitsJohannes Hostert-15/+26
2024-08-28Auto merge of #17981 - lnicola:proc-macro-cwd, r=Veykrilbors-2/+2
minor: Fix cwd used for proc macro expansion Fixes #17980.
2024-08-28Add benchmark for TB slowdownJohannes Hostert-0/+41
2024-08-28Fix cwd used for proc macro expansionLaurențiu Nicola-2/+2
2024-08-28Add test for tokio file io and mpsctiif-9/+72
2024-08-28Merge from rustcThe Miri Cronjob Bot-117/+275
2024-08-28Preparing for merge from rustcThe Miri Cronjob Bot-1/+1
2024-08-27warn the user if the upstream master branch is oldbinarycat-0/+34
fixes https://github.com/rust-lang/rust/issues/129528
2024-08-27Auto merge of #3804 - tiif:blockit, r=oli-obkbors-64/+316
Support blocking for epoll This PR enabled epoll to have blocking operation. The changes introduced by this PR are: - Refactored part of the logic in ``epoll_wait`` to ``blocking_epoll_callback`` - Added a new field ``thread_ids`` in ``Epoll`` for blocked thread ids - Added a new ``BlockReason::Epoll``
2024-08-27Make Tree Borrows Provenance GC compact the treeJohannes Hostert-17/+185
Follow-up on #3833 and #3835. In these PRs, the TB GC was fixed to no longer cause a stack overflow. One test that motivated it was the test `fill::horizontal_line` in `tiny_skia`. But not causing stack overflows was not a large improvents, since it did not fix the fundamental issue: The tree was too large. The test now ran, but it required gigabytes of memory and hours of time, whereas it finishes within seconds in Stacked Borrows. The problem in that test was that it used [`slice::chunked`](https://doc.rust-lang.org/std/primitive.slice.html#method.chunks) to iterate a slice in chunks. That iterator is written to reborrow at each call to `next`, which creates a linear tree with a bunch of intermediary nodes, which also fragments the `RangeMap` for that allocation. The solution is to now compact the tree, so that these interior nodes are removed. Care is taken to not remove nodes that are protected, or that otherwise restrict their children.
2024-08-27Add explanation to TB's "piecewise bottom-up" traversalJohannes Hostert-44/+111
2024-08-27Arbitrary self types v2: pointers feature gate.Adrian Taylor-1/+1
The main `arbitrary_self_types` feature gate will shortly be reused for a new version of arbitrary self types which we are amending per [this RFC](https://github.com/rust-lang/rfcs/blob/master/text/3519-arbitrary-self-types-v2.md). The main amendments are: * _do_ support `self` types which can't safely implement `Deref` * do _not_ support generic `self` types * do _not_ support raw pointers as `self` types. This PR relates to the last of those bullet points: this strips pointer support from the current `arbitrary_self_types` feature. We expect this to cause some amount of breakage for crates using this unstable feature to allow raw pointer self types. If that's the case, we want to know about it, and we want crate authors to know of the upcoming changes. For now, this can be resolved by adding the new `arbitrary_self_types_pointers` feature to such crates. If we determine that use of raw pointers as self types is common, then we may maintain that as an unstable feature even if we come to stabilize the rest of the `arbitrary_self_types` support in future. If we don't hear that this PR is causing breakage, then perhaps we don't need it at all, even behind an unstable feature gate. [Tracking issue](https://github.com/rust-lang/rust/issues/44874) This is [step 4 of the plan outlined here](https://github.com/rust-lang/rust/issues/44874#issuecomment-2122179688)
2024-08-27miri: Remove feature(new_uninit)Jubilee Young-5/+0
2024-08-27Rollup merge of #129634 - compiler-errors:tidy-2024, r=albertlarsan68Matthias Krüger-4/+6
Fix tidy to allow `edition = "2024"` in `Cargo.toml` Needed to upgrade to edition 2024 eventually.
2024-08-27Create an assist to convert closure to freestanding fnChayim Refael Friedman-13/+1511
The assist converts all captures to parameters.
2024-08-27Auto merge of #128134 - joboet:move_pal_alloc, r=cupiverbors-3/+5
std: move allocators to `sys` Part of #117276.
2024-08-27Make TB tree traversal bottom-upJohannes Hostert-270/+237
In preparation for #3837, the tree traversal needs to be made bottom-up, because the current top-down tree traversal, coupled with that PR's changes to the garbage collector, can introduce non-deterministic error messages if the GC removes a parent tag of the accessed tag that would have triggered the error first. This is a breaking change for the diagnostics emitted by TB. The implemented semantics stay the same.
2024-08-27Auto merge of #17757 - alibektas:toggle_macro_delimiters, r=Veykrilbors-0/+279
assist: Add new assist toggle_macro_delimiter Closes #17716
2024-08-27fix: do not assume rustup is installed in xtask codegenIvar Scholten-15/+19
When formatting generated code the xtask crate attempts to run `rustup run stable rustfmt`, which fails if `rustup` is not installed. This results in test failures when another source manages the compiler toolchain, for example when using Nix (or any other distro-specific packaging solution): * xtask::codegen::grammar::test * xtask::codegen::assists_doc_tests::test With this commit xtask will first attempt to run `rustup run stable rustfmt`, and if that fails just plain `rustfmt`. It still validates a stable version is being used. This allows `cargo test` to pass on systems that do not use `rustup`.
2024-08-27Auto merge of #3847 - JoJoDeveloping:master, r=RalfJungbors-5/+59
Disable tree traversal optimization that is wrong due to lazy nodes. See #3846 for more information. For now, the optimization is disabled in a very "hotfix" way, while we think about potential fixes. Nonetheless, this fixes #3846
2024-08-27Fix testsLukas Wirth-23/+23
2024-08-27Add testcase for #3846Johannes Hostert-0/+54
2024-08-27Auto merge of #17974 - lnicola:rm-apache-appendix, r=lnicolabors-50/+0
internal: Drop Apache license appendices Closes #14586 Similar to https://github.com/rust-lang/rust/pull/67734
2024-08-27Auto merge of #17973 - Veykril:proc-macro-curr-dir, r=Veykrilbors-14/+34
Expand proc-macros in workspace root, not package root Should fix https://github.com/rust-lang/rust-analyzer/issues/17748. The approach is generally not perfect though as rust-project.json projects don't benefit from this (still, nothing changes in that regard)
2024-08-27Drop Apache license appendicesLaurențiu Nicola-50/+0
2024-08-27Expand proc-macros in workspace root, not package rootLukas Wirth-14/+34
2024-08-27Auto merge of #3849 - RalfJung:tb-test, r=RalfJungbors-1/+2
tree_borrows test: ensure we can actually read the variable
2024-08-27tree_borrows test: ensure we can actually read the variableRalf Jung-1/+2
2024-08-27bless miri testjoboet-3/+5
2024-08-27set `BOOTSTRAP_SKIP_TARGET_SANITY` in opt-dist before running testsonur-ozkan-1/+7
opt-dist overrides the stage 0 compiler with previously compiled compilers, which can cause confusion in bootstrap's target sanity checks. It is best to skip that check. Signed-off-by: onur-ozkan <work@onurozkan.dev>
2024-08-27Auto merge of #17970 - ChayimFriedman2:unwrap-unsafe-block, r=Veykrilbors-3/+55
fix: Fix "Unwrap block" assist with block modifiers The assist just assumes the `{` will be the first character, which led to strange outputs such as `nsafe {`. Fixes #17964.
2024-08-27Auto merge of #3827 - RalfJung:gc-comment, r=RalfJungbors-25/+27
provenance_gc: fix comment Fixes https://github.com/rust-lang/miri/issues/3826 r? `@saethlin`
2024-08-27Rollup merge of #128942 - RalfJung:interpret-weak-memory, r=saethlinTrevor Gross-108/+152
miri weak memory emulation: put previous value into initial store buffer Fixes https://github.com/rust-lang/miri/issues/2164 by doing a read before each atomic write so that we can initialize the store buffer. The read suppresses memory access hooks and UB exceptions, to avoid otherwise influencing the program behavior. If the read fails, we store that as `None` in the store buffer, so that when an atomic read races with the first atomic write to some memory and previously the memory was uninitialized, we can report UB due to reading uninit memory. ``@cbeuw`` this changes a bit the way we initialize the store buffers. Not sure if you still remember all this code, but if you could have a look to make sure this still makes sense, that would be great. :) r? ``@saethlin``
2024-08-27Revert "feat: Implement `module_path` macro"Lukas Wirth-278/+71
2024-08-26Fix tidyMichael Goulet-4/+6