about summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorLines
2024-03-16Auto merge of #122559 - ForsakenHarmony:hrmny/update-llvm, r=nikicbors-0/+0
Update LLVM submodule LLVM version `18.1.1` + additional fixes. Fixes https://github.com/Amanieu/corosensei/issues/23. Fixes https://github.com/rust-lang/rust/issues/122252. Fixes https://github.com/rust-lang/rust/issues/121996. Fixes https://github.com/rust-lang/rust/issues/121960.
2024-03-16Auto merge of #121926 - tgross35:f16-f128-step3-feature-gate, ↵bors-0/+18
r=compiler-errors,petrochenkov `f16` and `f128` step 3: compiler support & feature gate Continuation of https://github.com/rust-lang/rust/pull/121841, another portion of https://github.com/rust-lang/rust/pull/114607 This PR exposes the new types to the world and adds a feature gate. Marking this as a draft because I need some feedback on where I did the feature gate check. It also does not yet catch type via suffixed literals (so the feature gate test will fail, probably some others too because I haven't belssed). If there is a better place to check all types after resolution, I can do that. If not, I figure maybe I can add a second gate location in AST when it checks numeric suffixes. Unfortunately I still don't think there is much testing to be done for correctness (codegen tests or parsed value checks) until we have basic library support. I think that will be the next step. Tracking issue: https://github.com/rust-lang/rust/issues/116909 r? `@compiler-errors` cc `@Nilstrieb` `@rustbot` label +F-f16_and_f128
2024-03-15rustdoc: clean up formattingMichael Howell-1/+1
2024-03-16Auto merge of #122575 - weihanglo:update-cargo, r=weihanglobors-0/+0
Update cargo 6 commits in 7065f0ef4aa267a7455e1c478b5ccacb7baea59c..2fe739fcf16c5bf8c2064ab9d357f4a0e6c8539b 2024-03-12 13:25:15 +0000 to 2024-03-15 21:39:18 +0000 - feat: Add 'open-namespaces' feature (rust-lang/cargo#13591) - refactor: Expose source/spans to Manifest for emitting lints (rust-lang/cargo#13593) - feat(tree): Control `--charset` via auto-detecting config value (rust-lang/cargo#13337) - refactor(toml): Flatten manifest parsing (rust-lang/cargo#13589) - fix: strip feature dep when dep is dev dep (rust-lang/cargo#13518) - fix(ci): bump check error when PR is behind master (rust-lang/cargo#13581) r? ghost
2024-03-15Update cargoWeihang Lo-0/+0
2024-03-15Rollup merge of #122563 - Kobzol:ci-pr-caching, r=Mark-SimulacrumMatthias Krüger-12/+29
CI: cache PR CI Docker builds An attempt to restore Docker caching for PR CI workflows that share the Docker image with an auto/try workflow. This was broken by my previous [PR](https://github.com/rust-lang/rust/pull/119290) that changed how we cache the Docker builds. [Before](https://github.com/rust-lang/rust/pull/122545): ![image](https://github.com/rust-lang/rust/assets/4539057/05e0d347-af64-4e85-bc99-0e4ac07192ec) After: ![image](https://github.com/rust-lang/rust/assets/4539057/2f657d60-b242-45eb-ac61-d8f71787edda) r? ``@ghost``
2024-03-15Rollup merge of #122495 - Manishearth:rustdoc-👻👻👻, r=GuillaumeGomezMatthias Krüger-58/+68
Visually mark 👻hidden👻 items with document-hidden-items Fixes #122485 This adds a 👻 in the item list (much like the :lock: used for private items), and also shows `#[doc(hidden)]` in the code view, where `pub(crate)` etc gets shown for private items. This does not do anything for enum variants, if people have ideas. I think we can just show the attribute.
2024-03-15CI: cache PR CI Docker buildsJakub Beránek-12/+29
2024-03-15Update LLVM submodulehrmny-0/+0
2024-03-15Rollup merge of #122530 - klensy:as_str, r=fee1-deadGuillaume Gomez-3/+4
less symbol interner locks This reduces instructions under 1% (in rustdoc run), but essentially free.
2024-03-15Rollup merge of #122513 - petrochenkov:somehir4, r=fmeaseGuillaume Gomez-40/+28
hir: Remove `opt_local_def_id_to_hir_id` and `opt_hir_node_by_def_id` Also replace a few `hir_node()` calls with `hir_node_by_def_id()`. Follow up to https://github.com/rust-lang/rust/pull/120943.
2024-03-15Rollup merge of #122496 - GuillaumeGomez:reduce-gcc-build-logs, ↵Guillaume Gomez-8/+15
r=Mark-Simulacrum Greatly reduce GCC build logs Fixes https://github.com/rust-lang/rust-log-analyzer/issues/80. Based on [makefile documentation](https://www.gnu.org/software/make/manual/html_node/Options-Summary.html#index-_002d_002dquiet-1) and [configure documentation](https://www.gnu.org/software/autoconf/manual/autoconf-2.68/html_node/configure-Invocation.html). cc `@RalfJung` `@antoyo`
2024-03-15Rollup merge of #114651 - tmfink:rustdoc-rustc-wrapper, r=GuillaumeGomezGuillaume Gomez-2/+58
rustdoc: add `--test-builder-wrapper` arg to support wrappers such as RUSTC_WRAPPER when building doctests Currently, `rustdoc` builds test crates with `rustc` directly instead of using [`RUSTC_WRAPPER`](https://doc.rust-lang.org/cargo/reference/config.html#buildrustc-wrapper) (if any is set). This causes build issues in build systems that use `cargo` but tweak linking flags by setting the `RUSTC_WRAPPER` environment variable. This change is not meant to be final--it's only a minimal proof of concept. Please advise on the best way to proceed. Open questions: - [x] Does supporting the `rustc` wrappers make sense? - yes, `cargo-miri` for example needs a "hack" to workaround the issue - [X] What environment variable(s) should be read for the rustc wrapper? Should `rustdoc` [use the same names as `cargo`](https://doc.rust-lang.org/cargo/reference/config.html#buildrustc-wrapper)? - None, since `rustdoc` takes arguments - [X] What name should be used for a `rustdoc` CLI option? - `--test-builder-wrapper` - [X] Should a separate workspace wrapper (like `RUSTC_WORKSPACE_WRAPPER`) be supported? - `--test-builder-wrapper` can be passed multiple times to get multiple wrappers passed - [X] How/where should this be documented? It's not obvious to all users that `cargo doc` actually causes `rustdoc` to compile tests with rust - Added doc to `src/doc/rustdoc/src/command-line-arguments.md` per `@GuillaumeGomez`
2024-03-15Build GCC with as many threads as availableGuillaume Gomez-3/+3
2024-03-15Greatly reduce GCC build logsGuillaume Gomez-7/+14
2024-03-15doc: add --test-builder/--test-builder-wrapperTravis Finkenauer-0/+29
2024-03-15rustdoc: create rustc command with an iteratorTravis Finkenauer-4/+6
This avoids unnecessary allocation with a temporary Vec.
2024-03-15rustdoc: fix test's saved stdoutTravis Finkenauer-2/+2
Also reword "test-builder-wrapper" argument help.
2024-03-15rustdoc: add `--test-builder-wrapper` argumentTravis Finkenauer-2/+27
Instead of executing the test builder directly, the test builder wrapper will be called with test builder as the first argument and subsequent arguments. This is similar to cargo's RUSTC_WRAPPER argument. The `--test-builder-wrapper` argument can be passed multiple times to allow "nesting" of wrappers.
2024-03-15less symbols interner locksklensy-3/+4
2024-03-15fmtRalf Jung-2/+1
2024-03-15Merge from rustcRalf Jung-197/+404
2024-03-15Preparing for merge from rustcRalf Jung-1/+1
2024-03-14Remove `feature(unchecked_math)` from miriScott McMurray-8/+0
2024-03-15Auto merge of #122511 - matthiaskrgr:rollup-swzilin, r=matthiaskrgrbors-53/+53
Rollup of 10 pull requests Successful merges: - #117118 ([AIX] Remove AixLinker's debuginfo() implementation) - #121650 (change std::process to drop supplementary groups based on CAP_SETGID) - #121764 (Make incremental sessions identity no longer depend on the crate names provided by source code) - #122212 (Copy byval argument to alloca if alignment is insufficient) - #122322 (coverage: Initial support for branch coverage instrumentation) - #122373 (Fix the conflict problem between the diagnostics fixes of lint `unnecessary_qualification` and `unused_imports`) - #122479 (Implement `Duration::as_millis_{f64,f32}`) - #122487 (Rename `StmtKind::Local` variant into `StmtKind::Let`) - #122498 (Update version of cc crate) - #122503 (Make `SubdiagMessageOp` well-formed) r? `@ghost` `@rustbot` modify labels: rollup
2024-03-14doc(bootstrap): add top-level doc-comment to utils/tarball.rsBryant Le-0/+7
2024-03-15Document `adt_const_params` feature in Unstable BookAurora-0/+35
2024-03-14Apply the same shell quoting trick we use in the URL toBen Kimock-1/+1
2024-03-14hir: Remove `opt_local_def_id_to_hir_id` and `opt_hir_node_by_def_id`Vadim Petrochenkov-40/+28
Also replace a few `hir_node()` calls with `hir_node_by_def_id()`
2024-03-14Rollup merge of #122487 - GuillaumeGomez:rename-stmtkind-local, r=oli-obkMatthias Krüger-51/+51
Rename `StmtKind::Local` variant into `StmtKind::Let` It comes from this [discussion](https://rust-lang.zulipchat.com/#narrow/stream/131828-t-compiler/topic/Improve.20naming.20of.20.60ExprKind.3A.3ALet.60.3F). Starting point was: > I often end up looking at [ExprKind::Let](https://doc.rust-lang.org/nightly/nightly-rustc/rustc_hir/enum.ExprKind.html#variant.Let) instead of Local because of the name. I think renaming it (both the `ExprKind` variant and the Let struct) to `LetPattern` or LetPat could improve the situation as I'm not sure I'm not the only one encountering this issue. And then it evolved into: > It's already `Expr::Let` instead of `StmtKind::Local`. Counterproposal: rename `StmtKind::Local` to `StmtKind::Let`. The goal here is to clear this confusion. r? `@oli-obk`
2024-03-14Rollup merge of #122322 - Zalathar:branch, r=oli-obkMatthias Krüger-2/+2
coverage: Initial support for branch coverage instrumentation (This is a review-ready version of the changes that were drafted in #118305.) This PR adds support for branch coverage instrumentation, gated behind the unstable flag value `-Zcoverage-options=branch`. (Coverage instrumentation must also be enabled with `-Cinstrument-coverage`.) During THIR-to-MIR lowering (MIR building), if branch coverage is enabled, we collect additional information about branch conditions and their corresponding then/else blocks. We inject special marker statements into those blocks, so that the `InstrumentCoverage` MIR pass can reliably identify them even after the initially-built MIR has been simplified and renumbered. The rest of the changes are mostly just plumbing needed to gather up the information that was collected during MIR building, and include it in the coverage metadata that we embed in the final binary. Note that `llvm-cov show` doesn't print branch coverage information in its source views by default; that needs to be explicitly enabled with `--show-branches=count` or similar. --- The current implementation doesn't have any support for instrumenting `if let` or let-chains. I think it's still useful without that, and adding it would be non-trivial, so I'm happy to leave that for future work.
2024-03-14Auto merge of #119849 - lcnr:eagerly-instantiate-binders, r=compiler-errorsbors-1/+0
more eagerly instantiate binders The old solver sometimes incorrectly used `sub`, change it to explicitly instantiate binders and use `eq` instead. While doing so I also moved the instantiation before the normalize calls. This caused some observable changes, will explain these inline. This PR therefore requires a crater run and an FCP. r? types
2024-03-14Add feature gates for `f16` and `f128`Trevor Gross-0/+18
Includes related tests and documentation pages. Michael Goulet: Don't issue feature error in resolver for f16/f128 unless finalize Co-authored-by: Michael Goulet <michael@errs.io>
2024-03-14Fix `StdNonZeroNumberProvider` for `gdb`.Markus Reiter-1/+8
2024-03-14Add comment about `NonZero` printing as character literal.Markus Reiter-0/+2
2024-03-14Remove LLDB persistent results in `compiletest`.Markus Reiter-9/+0
2024-03-14Deduplicate `lldb_commands`.Markus Reiter-33/+9
2024-03-14Fix `StdNonZeroNumberSummaryProvider`.Markus Reiter-21/+24
2024-03-14Try fixing `debuginfo` test.Markus Reiter-4/+7
2024-03-14one must imagine tidy happylcnr-1/+0
2024-03-14Auto merge of #3379 - RalfJung:time-with-isolation, r=saethlinbors-10/+14
explain time-with-isolation test better Fixes https://github.com/rust-lang/miri/issues/3377 `@saethlin` do you think this is better?
2024-03-14Rollup merge of #122490 - Amanieu:ohos-tier2-instructions, r=GuillaumeGomezMatthias Krüger-24/+27
Update build instructions for OpenHarmony The platform page now recommends using rustup since the target is now tier 2.
2024-03-14Rollup merge of #122397 - oli-obk:machine-read-hook2, r=RalfJungMatthias Krüger-1/+1
Various cleanups around the const eval query providers r? `@RalfJung` after this, working on running validation before interning starts with swapping the order of two lines of code
2024-03-14Rollup merge of #122368 - pavedroad:master, r=oli-obkMatthias Krüger-1/+1
chore: remove repetitive words
2024-03-14Rollup merge of #122247 - notriddle:notriddle/search-unbox-limit, ↵Matthias Krüger-31/+107
r=GuillaumeGomez rustdoc-search: depth limit `T<U>` -> `U` unboxing Profiler output: https://notriddle.com/rustdoc-html-demo-9/search-unbox-limit/ (the only significant change is that one of the `rust` tests went from 378416ms to 16ms). This is a performance enhancement aimed at a problem I found while using type-driven search on the Rust compiler. It is caused by [`Interner`], a trait with 41 associated types, many of which recurse back to `Self` again. This caused search.js to struggle. It eventually terminates, after about 10 minutes of turning my PC into a space header, but it's doing `41!` unifications and that's too slow. [`Interner`]: https://doc.rust-lang.org/nightly/nightly-rustc/rustc_middle/ty/trait.Interner.html
2024-03-14explain time-with-isolation test betterRalf Jung-10/+14
2024-03-14fix polarityManish Goregaokar-2/+2
2024-03-14inlineManish Goregaokar-5/+9
2024-03-14Make compactManish Goregaokar-10/+10
2024-03-14print doc(hidden)Manish Goregaokar-5/+14