about summary refs log tree commit diff
path: root/src/tools
AgeCommit message (Collapse)AuthorLines
2024-04-17fmtRalf Jung-5/+1
2024-04-17Merge from rustcRalf Jung-39/+46
2024-04-17Preparing for merge from rustcRalf Jung-1/+1
2024-04-17Rollup merge of #124030 - RalfJung:adjust_alloc_base_pointer, r=oli-obkMatthias Krüger-39/+46
interpret: pass MemoryKind to adjust_alloc_base_pointer Another puzzle piece for https://github.com/rust-lang/miri/pull/3475. The 2nd commit renames base_pointer -> root_pointer; that's how Tree Borrows already calls them and I think the term is more clear than "base pointer". In particular, this distinguishes it from "base address", since a root pointer can point anywhere into an allocation, not just its base address. https://github.com/rust-lang/rust/pull/124018 has been rolled up already so I couldn't add it there any more. r? ```@oli-obk```
2024-04-17Auto merge of #3480 - RalfJung:alloc_error_handler, r=RalfJungbors-120/+171
directly call handle_alloc_error Also test more codepaths. There's like 5 different things that can happen on allocation failure! Between `-Zoom`, `#[alloc_error_handler]`, and `set_alloc_error_hook`, we have 3 layers of behavior overrides. It's all a bit messy. https://github.com/rust-lang/rust/pull/112331 seems intended to clean this up, but has not yet reached consensus.
2024-04-17no need to use miri's native stderr hereRalf Jung-3/+2
2024-04-17tests/utils: add fmt::Write implementations for miri's native stdout/stderrRalf Jung-59/+64
2024-04-17alloc_error_handler tests: directly call handle_alloc_error; test more codepathsRalf Jung-75/+122
2024-04-17interpret: rename base_pointer -> root_pointerRalf Jung-35/+35
also in Miri, "base tag" -> "root tag"
2024-04-17interpret: pass MemoryKind to adjust_alloc_base_pointerRalf Jung-7/+14
2024-04-17fmtThe Miri Cronjob Bot-10/+12
2024-04-17Merge from rustcThe Miri Cronjob Bot-103/+170
2024-04-17Preparing for merge from rustcThe Miri Cronjob Bot-1/+1
2024-04-17Auto merge of #124055 - matthiaskrgr:rollup-waq2e68, r=matthiaskrgrbors-59/+60
Rollup of 6 pull requests Successful merges: - #122813 (Qualifier tweaking) - #122883 (refactor clippy in bootstrap) - #123997 (Delay span bug when `Self` kw resolves to `DefKind::{Mod,Trait}`) - #124045 (Reinstate nnethercote to the review rotation.) - #124051 (Fix empty-set symbol in comments) - #124052 (Make the comments for `ReturnDest` variants doc comments) r? `@ghost` `@rustbot` modify labels: rollup
2024-04-17Rollup merge of #122813 - nnethercote:nicer-quals, r=compiler-errorsMatthias Krüger-59/+60
Qualifier tweaking Adding and removing qualifiers in some cases that make things nicer. Details in individual commits. r? `@compiler-errors`
2024-04-17Auto merge of #124039 - weihanglo:update-cargo, r=weihanglobors-0/+0
Update cargo 11 commits in 48eca1b164695022295ce466b64b44e4e0228b08..6f06fe908a5ee0f415c187f868ea627e82efe07d 2024-04-12 21:16:36 +0000 to 2024-04-16 18:47:44 +0000 - fix(toml): Error on `[project]` in Edition 2024 (rust-lang/cargo#13747) - feat(update): Include a Locking message (rust-lang/cargo#13759) - chore(deps): update rust crate gix to 0.62.0 [security] (rust-lang/cargo#13760) - test(schemas): Ensure tests cover the correct case (rust-lang/cargo#13761) - feat(resolve): Tell the user the style of resovle done (rust-lang/cargo#13754) - Make sure to also wrap the initial `-vV` invocation (rust-lang/cargo#13659) - docs: update `checkout` GitHub action version (rust-lang/cargo#13757) - Recategorize cargo test's `--doc` flag under "Target Selection" (rust-lang/cargo#13756) - Reword sentence describing workspace toml for clarity (rust-lang/cargo#13753) - docs(ref): Update unstable docs for msrv-policy (rust-lang/cargo#13751) - refactor(config): Consistently use kebab-case (rust-lang/cargo#13748) r? ghost
2024-04-17Rollup merge of #124013 - RalfJung:box-to-raw, r=oli-obkGuillaume Gomez-2/+42
Box::into_raw: make Miri understand that this is a box-to-raw cast Turns out https://github.com/rust-lang/rust/pull/122647 went a bit too far in cleaning up `Box`... we still need a hack in `Box::into_raw`. The nicer fix would be to make Stacked Borrows not care about reference-to-raw-pointer casts, but it's unclear whether that will ever be possible without going to full Tree Borrows. Fixes https://github.com/rust-lang/miri/issues/3473.
2024-04-17Rollup merge of #123975 - lqd:rust-lld-tests, r=jieyouxuGuillaume Gomez-4/+10
Port the 2 `rust-lld` run-make tests to `rmake` In preparation for finalizing most of the `rust-lld` work, this PR ports the following tests to `rmake`: - `tests/run-make/rust-lld` - `tests/run-make/rust-lld-custom-target` As they use `$(CGREP) -e` I added `regex` as an exported dependency to the `run_make_support` library. Unfortunately, the most recent versions depend on `memchr` 2.6.0 but it's currently pinned at 2.5.0 in the workspace, and therefore had to settle for the older `regex-1.8.0`. r? `@jieyouxu`
2024-04-17Rollup merge of #123673 - oli-obk:sig_wfcheck_ice, r=jieyouxu,estebankGuillaume Gomez-3/+6
Don't ICE for kind mismatches during error rendering fixes #123457 also some test suite cleanups to make backtraces easier to read
2024-04-16Update cargoWeihang Lo-0/+0
2024-04-16Auto merge of #3478 - RalfJung:alloc_error_handler, r=RalfJungbors-7/+207
implement support for __rust_alloc_error_handler Fixes https://github.com/rust-lang/miri/issues/3439
2024-04-16implement support for __rust_alloc_error_handlerRalf Jung-7/+207
2024-04-16no_std works on Windows nowRalf Jung-4/+0
2024-04-16Rollup merge of #122811 - nnethercote:mv-SourceMap-init, r=WaffleLapkinGuillaume Gomez-1/+1
Move `SourceMap` initialization So it happens at the same time as `SessionGlobals` initialization, rather than shortly afterward. r? `@WaffleLapkin`
2024-04-16Rollup merge of #124018 - RalfJung:dealloc-memory-kind, r=oli-obkMatthias Krüger-18/+19
interpret: pass MemoryKind to before_memory_deallocation This will be needed for https://github.com/rust-lang/miri/pull/3475. r? ``@oli-obk``
2024-04-16Rollup merge of #124007 - RalfJung:miri, r=RalfJungMatthias Krüger-143/+345
Miri subtree update r? ``@ghost``
2024-04-16interpret: pass MemoryKind to before_memory_deallocationRalf Jung-18/+19
2024-04-16Auto merge of #124015 - GuillaumeGomez:rollup-s46ksxa, r=GuillaumeGomezbors-1/+0
Rollup of 14 pull requests Successful merges: - #120781 (Correct usage note on OpenOptions::append()) - #121694 (sess: stabilize `-Zrelro-level` as `-Crelro-level`) - #122521 (doc(bootstrap): add top-level doc-comment to utils/tarball.rs) - #123491 (Fix ICE in `eval_body_using_ecx`) - #123574 (rustdoc: rename `issue-\d+.rs` tests to have meaningful names (part 6)) - #123687 (Update ar_archive_writer to 0.2.0) - #123721 (Various visionOS fixes) - #123797 (Better graphviz output for SCCs and NLL constraints) - #123990 (Make `suggest_deref_closure_return` more idiomatic/easier to understand) - #123995 (Make `thir_tree` and `thir_flat` into hooks) - #123998 (Opaque types have no namespace) - #124001 (Fix docs for unstable_features lint.) - #124006 (Move size assertions for `mir::syntax` types into the same file) - #124011 (rustdoc: update the module-level docs of `rustdoc::clean`) r? `@ghost` `@rustbot` modify labels: rollup
2024-04-16Auto merge of #3472 - RalfJung:deadlock, r=RalfJungbors-25/+175
deadlock: show backtrace for all threads Fixes https://github.com/rust-lang/miri/issues/3424
2024-04-16deadlock: show backtrace for all threadsRalf Jung-25/+175
2024-04-16Box::into_raw: make Miri understand that this is a box-to-raw castRalf Jung-2/+42
2024-04-16Auto merge of #123468 - compiler-errors:precise-capturing, r=oli-obkbors-3/+17
Implement syntax for `impl Trait` to specify its captures explicitly (`feature(precise_capturing)`) Implements `impl use<'a, 'b, T, U> Sized` syntax that allows users to explicitly list the captured parameters for an opaque, rather than inferring it from the opaque's bounds (or capturing *all* lifetimes under 2024-edition capture rules). This allows us to exclude some implicit captures, so this syntax may be used as a migration strategy for changes due to #117587. We represent this list of captured params as `PreciseCapturingArg` in AST and HIR, resolving them between `rustc_resolve` and `resolve_bound_vars`. Later on, we validate that the opaques only capture the parameters in this list. We artificially limit the feature to *require* mentioning all type and const parameters, since we don't currently have support for non-lifetime bivariant generics. This can be relaxed in the future. We also may need to limit this to require naming *all* lifetime parameters for RPITIT, since GATs have no variance. I have to investigate this. This can also be relaxed in the future. r? `@oli-obk` Tracking issue: - https://github.com/rust-lang/rust/issues/123432
2024-04-16Make ui_test backtraces short by defaultOli Scherer-1/+4
2024-04-16Unset test env vars before setting new ones.Oli Scherer-2/+2
If you want to override an env var, don't unset it, just set it
2024-04-16threads: keep track of why we are blocked, and sanity-check that when waking upRalf Jung-95/+108
2024-04-16avoid passing --sysroot twice in bootstrapRalf Jung-5/+8
2024-04-16bless test-cargo-miriRalf Jung-11/+11
2024-04-16Avoid lots of `hir::HirId{,Map,Set}` qualifiers.Nicholas Nethercote-35/+37
Because they're a bit redundant.
2024-04-16Always use `ty::` qualifier for `TyKind` enum variants.Nicholas Nethercote-19/+20
Because that's the way it should be done.
2024-04-16Avoid unnecessary `rustc_span::DUMMY_SP` usage.Nicholas Nethercote-5/+3
In some cases `DUMMY_SP` is already imported. In other cases this commit adds the necessary import, in files where `DUMMY_SP` is used more than once.
2024-04-16Merge from rustcThe Miri Cronjob Bot-4885/+5214
2024-04-16Preparing for merge from rustcThe Miri Cronjob Bot-1/+1
2024-04-16Construct `SourceMap` at the same time as `SessionGlobals`.Nicholas Nethercote-1/+1
Currently `SourceMap` is constructed slightly later than `SessionGlobals`, and inserted. This commit changes things so they are done at the same time. Benefits: - `SessionGlobals::source_map` changes from `Lock<Option<Lrc<SourceMap>>>` to `Option<Lrc<SourceMap>>`. It's still optional, but mutability isn't required because it's initialized at construction. - `set_source_map` is removed, simplifying `run_compiler`, which is good because that's a critical function and it's nice to make it simpler. This requires moving things around a bit, so the necessary inputs are available when `SessionGlobals` is created, in particular the `loader` and `hash_kind`, which are no longer computed by `build_session`. These inputs are captured by the new `SourceMapInputs` type, which is threaded through various places.
2024-04-15Fix docs for unstable_features lint.Eric Huss-1/+0
2024-04-16Auto merge of #123991 - fmease:rollup-96xcgnm, r=fmeasebors-7/+7
Rollup of 7 pull requests Successful merges: - #123016 (Remove `TypeVariableOriginKind` and `ConstVariableOriginKind`) - #123462 (Cleanup: Rename `ModSep` to `PathSep`) - #123603 (Don't even parse an intrinsic unless the feature gate is enabled) - #123926 (Fix pretty HIR for anon consts in diagnostics) - #123973 (crashes: readme: add reminder to add Fixes #abcde to prs to automatically close issues.) - #123984 (sanitizers: Add rustc_sanitizers to triagebot.toml) - #123989 (Just use `type_dependent_def_id` to figure out what the method is for an expr) r? `@ghost` `@rustbot` modify labels: rollup
2024-04-16Rollup merge of #123926 - compiler-errors:no-ann, r=estebankLeón Orell Valerian Liehr-3/+3
Fix pretty HIR for anon consts in diagnostics This removes the `NoAnn` printer which skips over nested bodies altogether, which is confusing, and requires users of `{ty|qpath|pat}_to_string` to pass in `&tcx` which now impleemnts `hir_pretty::PpAnn`. There's one case where this "regresses" by actually printing out the body of the anon const -- we could suppress that, but I don't expect people to actually get anon consts like that unless they're fuzzing, tbh. r? estebank
2024-04-16Rollup merge of #123462 - fmease:rn-mod-sep-to-path-sep, r=nnethercoteLeón Orell Valerian Liehr-2/+2
Cleanup: Rename `ModSep` to `PathSep` `::` is usually referred to as the *path separator* (citation needed). The existing name `ModSep` for *module separator* is a bit misleading since it in fact separates the segments of arbitrary path segments, not only ones resolving to modules. Let me just give a shout-out to associated items (`T::Assoc`, `<Ty as Trait>::function`) and enum variants (`Option::None`). Motivation: Reduce friction for new contributors, prevent potential confusion. cc `@petrochenkov` r? nnethercote or compiler
2024-04-15Fix clippyMichael Goulet-3/+3
2024-04-15Auto merge of #123451 - Kobzol:arbitrary-try-build, r=pietroalbinibors-23/+16
CI: add a script for dynamically computing CI job matrix It would be great if was easier to run specific CI workflows locally, and also to allow us to spawn a specific CI workflow by bors, to enable running arbitrary try builds. See discussion [here](https://rust-lang.zulipchat.com/#narrow/stream/242791-t-infra/topic/CI.20workflows.20refactoring). This PR is a first step in that direction. - Moves the definition of CI runners and (for now) PR jobs into a separate `jobs.yml` file. - Adds a simple Python script that reads the file, decides which jobs should be active for the current CI workflow, and prints them as JSON to their output. - The PR job then reads this output and generates its job matrix based on it. By moving the job definitions from `ci.yml` into a separate file, we can handle it programmatically, which should make it easier to both do local execution of CI jobs and also to do arbitrary try builds.
2024-04-15Remove TypeVariableOriginKindMichael Goulet-2/+2