about summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorLines
2024-09-09Rollup merge of #129473 - Urgau:fix-llvm-if-unchanged, r=onur-ozkanJubilee-2/+9
use `download-ci-llvm=true` in the default compiler config https://github.com/rust-lang/rust/commit/1ca2708e77ac735adc3824501667694b4f9c1303 made it so that the `src/llvm-project` submodule has to be checkout for `download-ci-llvm = "if-unchanged"` to know if the submodule has been changed, but that is not required, if the submodule hasn't been checkout it cannot have been modified. ~~This PR restore the previous behavior by only updating the submodule if it has already been checkout.~~ This PR makes `download-ci-llvm = true` check if CI llvm is available and make it the default for the compiler profile, as to prevent unnecessarily checking out `src/llvm-project` with `"if-unchanged"`. r? `````@onur-ozkan`````
2024-09-10Auto merge of #129778 - RalfJung:interp-lossy-typed-copy, r=saethlinbors-12/+503
interpret: make typed copies lossy wrt provenance and padding A "typed copy" in Rust can be a lossy process: when copying at type `usize` (or any other non-pointer type), if the original memory had any provenance, that provenance is lost. When copying at pointer type, if the original memory had partial provenance (i.e., not the same provenance for all bytes), that provenance is lost. When copying any type with padding, the contents of padding are lost. This PR equips our validity-checking pass with the ability to reset provenance and padding according to those rules. Can be reviewed commit-by-commit. The first three commits are just preparation without any functional change. Fixes https://github.com/rust-lang/miri/issues/845 Fixes https://github.com/rust-lang/miri/issues/2182
2024-09-09Auto merge of #129789 - notriddle:notriddle/inline-stmt-local, r=GuillaumeGomezbors-197/+215
rustdoc: use strategic boxing to shrink `clean::Item` * `inline_stmt_id` is never a cross-crate DefId, so save space by not storing it. * Instead of two inner boxes for `Item`, use one.
2024-09-09Auto merge of #130165 - matthiaskrgr:rollup-fsnmz3t, r=matthiaskrgrbors-2/+33
Rollup of 9 pull requests Successful merges: - #129929 (`rustc_mir_transform` cleanups, round 2) - #130022 (Dataflow/borrowck lifetime cleanups) - #130064 (fix ICE in CMSE type validation) - #130067 (Remove redundant check in `symlink_hard_link` test) - #130131 (Print a helpful message if any tests were skipped for being up-to-date) - #130137 (Fix ICE caused by missing span in a region error) - #130153 (use verbose flag as a default value for `rust.verbose-tests`) - #130154 (Stabilize `char::MIN`) - #130158 (Update books) r? `@ghost` `@rustbot` modify labels: rollup
2024-09-09Rollup merge of #130158 - rustbot:docs-update, r=ehussMatthias Krüger-0/+0
Update books ## rust-lang/edition-guide 1 commits in eeba2cb9c37ab74118a4fb5e5233f7397e4a91f8..b3ca7ade0f87d7e3fb538776defc5b2cc4188172 2024-09-03 22:59:56 UTC to 2024-09-03 22:59:56 UTC - Rename `static_mut_refs` file to plural ## rust-embedded/book 1 commits in ff5d61d56f11e1986bfa9652c6aff7731576c37d..dbae36bf3f8410aa4313b3bad42e374735d48a9d 2024-09-04 20:49:11 UTC to 2024-09-04 20:49:11 UTC - Fix small error in c bindings (rust-embedded/book#377) ## rust-lang/reference 6 commits in 0668397076da350c404dadcf07b6cbc433ad3743..687faf9958c52116d003b41dfd29cc1cf44f5311 2024-09-03 20:21:23 UTC to 2024-08-29 01:11:29 UTC - `asm!`: clarify that `nomem` / `readonly` can access private memory (rust-lang/reference#1598) - Switch warning blocks to use admonitions (rust-lang/reference#1595) - dont use stdcall on x86_64 where it is not a valid ABI (rust-lang/reference#1600) - Add capturing and precise capturing rules (rust-lang/reference#1577) - Add a prefix to rule HTML IDs (rust-lang/reference#1593) - Add a description of rule identifiers (rust-lang/reference#1594) ## rust-lang/rust-by-example 2 commits in 859786c5bc99301bbc22fc631a5c2b341860da08..c79ec345f08a1e94494cdc8c999709a90203fd88 2024-09-08 13:24:48 UTC to 2024-09-08 13:24:08 UTC - Fix typo in conversion/from_into (rust-lang/rust-by-example#1882) - Corrected x values for example rectangle (rust-lang/rust-by-example#1884) ## rust-lang/rustc-dev-guide 9 commits in fa928a6d19e1666d8d811dfe3fd35cdad3b4e459..0ed9229f5b6f7824b333beabd7e3d5ba4b9bd971 2024-09-09 10:58:45 UTC to 2024-08-31 13:02:08 UTC - fix some comments (rust-lang/rustc-dev-guide#2059) - Fix a link and create an implied internal link (rust-lang/rustc-dev-guide#2051) - link to additional LLVM update PRs (rust-lang/rustc-dev-guide#2055) - fix/improve rdg contributing howto (rust-lang/rustc-dev-guide#2056) - fixed the typo (rust-lang/rustc-dev-guide#2058) - fix typo maker -> marker (thanks `@lholten)` (rust-lang/rustc-dev-guide#2057) - improve query system documentation (rust-lang/rustc-dev-guide#2041) - add section on overlap checks (rust-lang/rustc-dev-guide#2042) - clarify the role of rustc_const_unstable (rust-lang/rustc-dev-guide#2045)
2024-09-09Rollup merge of #130153 - onur-ozkan:verbose-to-verbose-tests, r=KobzolMatthias Krüger-0/+12
use verbose flag as a default value for `rust.verbose-tests` See the [Zulip thread](https://rust-lang.zulipchat.com/#narrow/stream/326414-t-infra.2Fbootstrap/topic/Run.20tests.20in.20x.2Epy.20with.20.22pretty.22.20test.20rendering.3F) for more context.
2024-09-09Rollup merge of #130131 - Zalathar:up-to-date, r=KobzolMatthias Krüger-2/+21
Print a helpful message if any tests were skipped for being up-to-date When running tests without the `--force-rerun` flag, compiletest will automatically skip any tests that (in its judgement) don't need to be run again since the last time they were run. This is normally very useful, but can occasionally be confusing, especially in edge-cases where up-to-date checking is not completely accurate (or the test is flaky). This PR makes bootstrap count the number of tests that were ignored for being up-to-date (via a hard-coded check on the ignore reason), and prints a helpful message when that number is nonzero. --- Sample output: ```text test result: ok. 4 passed; 0 failed; 17578 ignored; 0 measured; 0 filtered out; finished in 463.79ms help: ignored 17295 up-to-date tests; use `--force-rerun` to prevent this Build completed successfully in 0:00:07 ```
2024-09-09handle `GitConfig` for `tools/suggest-tests`onur-ozkan-0/+2
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2024-09-09bump download-ci-llvm-stamponur-ozkan-1/+1
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2024-09-09replace `get_closest_merge_base_commit` with `get_closest_merge_commit`onur-ozkan-53/+15
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2024-09-09implement `build_helper::git::get_closest_merge_commit`onur-ozkan-6/+34
Compare to `get_git_merge_base`, this doesn't require configuring the upstream remote. Signed-off-by: onur-ozkan <work@onurozkan.dev>
2024-09-09add `git_merge_commit_email` into `GitConfig`onur-ozkan-0/+2
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2024-09-09sync: store extra sync primitive data in a Box<dyn Any> so the type can be ↵Ralf Jung-66/+59
kept local
2024-09-09sync methods: pass around places, not pointer-typed operandsRalf Jung-95/+69
2024-09-09Update booksrustbot-0/+0
2024-09-09Auto merge of #3871 - Mandragorian:detect_rwlock_move, r=RalfJungbors-5/+68
detect when pthread_rwlock_t is moved For some implementations of pthreads, the address of pthread_rwlock_t (or its fields) is used to identify the lock. That means that if the contents of a pthread_rwlock_t are moved in memory, effectively a new lock object is created, which is completely independted from the original. Thus we want to detect when when such objects are moved and show an error. see also #3749 for more context
2024-09-10feat: generate names for tuple-struct in add-missing-match-armsroife-24/+106
2024-09-10refactor: introduce NameGenerator in suggest_nameroife-81/+192
2024-09-09Auto merge of #128939 - bjorn3:windows_cg_clif_component, r=albertlarsan68bors-12/+7
Distribute rustc_codegen_cranelift for Windows With support for raw-dylib recently added to cg_clif, and inline assembly support working on Windows for quite a while now, all blockers for distributing cg_clif on Windows that I mentioned in https://github.com/rust-lang/rust/pull/81746#issuecomment-1774099637 are fixed now.
2024-09-09use verbose flag as a default value for `rust.verbose-tests`onur-ozkan-0/+12
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2024-09-09Add missing backtick in comment (#6317)cui fliter-1/+1
Signed-off-by: cuishuang <imcusg@gmail.com>
2024-09-09feat: use shorthand when pretty-print record patroife-6/+79
2024-09-09Auto merge of #3872 - trivikr:actions-checkout-v4, r=RalfJungbors-2/+2
ci: bump actions/checkout to v4 Required for using Node.js 20.x in CI * Changelog for actions/checkout@v4 https://github.com/actions/checkout/blob/main/CHANGELOG.md?rgh-link-date=2024-09-04T18%3A38%3A10Z#v400 * GitHub Blog post https://github.blog/changelog/2024-03-07-github-actions-all-actions-will-run-on-node20-instead-of-node16-by-default/ Refs: https://github.com/rust-lang/rust/pull/130124#issuecomment-2336871149
2024-09-09fix UB in a testRalf Jung-2/+35
also add an explicit test for the fact that a Option<WidePtr> has padding when it is None
2024-09-09use fd_num for file descriptors, so we can use fd for file descriptionRalf Jung-92/+83
2024-09-09Auto merge of #18041 - roife:fix-issue-17631, r=Veykrilbors-1/+95
feat: better name suggestions for fn fix #17631. Better name suggestions for fn-calls / method-calls in the form of `from()`, `from_xxx()`, `into()`, etc.
2024-09-09feat: better name suggestions for fnroife-1/+95
2024-09-09ci: bump actions/checkout to v4Trivikram Kamat-2/+2
2024-09-09fix: add parenthesis for or-patternroife-1/+18
2024-09-09fix: use `pretty_print_pat` for params in fnroife-5/+123
2024-09-09feat: add prettifier for Patroife-0/+31
2024-09-09feat: Allow hir-def prettifier formatting into one-lineroife-15/+55
2024-09-09union padding computation: add fast-path for ZSTRalf Jung-0/+15
Also avoid even tracking empty ranges, and add fast-path for arrays of scalars
2024-09-09Use small runner for msvc-ext2 jobChris Denton-1/+5
2024-09-09Fix default/minimum deployment target for Aarch64 simulator targetsMads Marquart-2/+2
The minimum that `rustc` encoded did not match the version in Clang, and that meant that that when linking, we ended up bumping the version. Specifically, this sets the correct deployment target of the following simulator and Mac Catalyst targets: - `aarch64-apple-ios-sim` from 10.0 to 14.0 - `aarch64-apple-tvos-sim` from 10.0 to 14.0 - `aarch64-apple-watchos-sim` from 5.0 to 7.0 - `aarch64-apple-ios-macabi` from 13.1 to 14.0 I have chosen to not document the simulator target versions in the platform support docs, as it is fundamentally uninteresting; the normal targets (e.g. `aarch64-apple-ios`, `aarch64-apple-tvos`) still have the same deployment target as before, and that's what developers should actually target.
2024-09-09Auto merge of #130135 - Kobzol:bootstrap-check-linker, r=onur-ozkanbors-3/+3
Do not skip linker configuration for `check` builds This essentially reverts a part of https://github.com/rust-lang/rust/pull/128871, to fix https://github.com/rust-lang/rust/issues/130108. This is mostly a hotfix until we can figure out a better way to both avoid rebuilds and avoid configuring the linker for `x check`. Skipping linker for check builds was causing unexpected rebuilds. Fixes: https://github.com/rust-lang/rust/issues/130108
2024-09-09fix some comments (#2059)cui fliter-7/+7
Signed-off-by: cuishuang <imcusg@gmail.com>
2024-09-09bootstrap/Makefile.in: miri: add missing BOOTSTRAP ARGSRalf Jung-2/+6
also don't unnecessarily set BOOTSTRAP_SKIP_TARGET_SANITY while we are at it
2024-09-09Auto merge of #130133 - workingjubilee:rollup-t5o827k, r=workingjubileebors-468/+729
Rollup of 14 pull requests Successful merges: - #119229 (Update mingw-w64 + GNU toolchain) - #128345 (added support for GNU/Hurd on x86_64) - #128667 (rustdoc: normalise type/field names) - #129876 (Use sysroot crates maximally in `rustc_codegen_gcc`.) - #130034 ( Fix enabling wasm-component-ld to match other tools ) - #130048 (run-make-support: Add llvm-pdbutil) - #130068 (Test codegen when setting deployment target) - #130070 (Rename variant `AddrOfRegion` of `RegionVariableOrigin` to `BorrowRegion`) - #130087 (remove 'const' from 'Option::iter') - #130090 (make Result::copied unstably const) - #130092 (Fixes typo in wasm32-wasip2 doc comment) - #130107 (const: make ptr.is_null() stop execution on ambiguity) - #130115 (Remove needless returns detected by clippy in libraries) - #130130 (Miri subtree update) r? `@ghost` `@rustbot` modify labels: rollup
2024-09-09Remove unnecessary symbols and add missing symbolscuishuang-3/+5
Signed-off-by: cuishuang <imcusg@gmail.com>
2024-09-09Do not skip linker configuration for `check` buildsJakub Beránek-3/+3
It was causing unexpected rebuilds.
2024-09-09Rollup merge of #130130 - RalfJung:miri-sync, r=RalfJungJubilee-287/+523
Miri subtree update r? `@ghost`
2024-09-09Rollup merge of #130068 - madsmtm:deployment-target-test, r=jieyouxuJubilee-2/+19
Test codegen when setting deployment target Test our codegen in different scenarios when setting the deployment target. There are many places here where this is still incorrect, these will be fixed in https://github.com/rust-lang/rust/pull/129342, https://github.com/rust-lang/rust/pull/129367 and https://github.com/rust-lang/rust/pull/129369. See https://github.com/rust-lang/rust/issues/129432 for the bigger picture. Tested locally using: ```console ./x test tests/run-make/apple-deployment-target --target="aarch64-apple-darwin,aarch64-apple-ios,aarch64-apple-ios-macabi,aarch64-apple-ios-sim,aarch64-apple-tvos,aarch64-apple-tvos-sim,aarch64-apple-visionos,aarch64-apple-visionos-sim,aarch64-apple-watchos,aarch64-apple-watchos-sim,arm64_32-apple-watchos,armv7s-apple-ios,i386-apple-ios,x86_64-apple-darwin,x86_64-apple-ios,x86_64-apple-ios-macabi,x86_64-apple-tvos,x86_64-apple-watchos-sim,x86_64h-apple-darwin" ``` The only Apple targets that aren't tested by the above command are: - `arm64e-apple-darwin`, failed to build, see https://github.com/rust-lang/cc-rs/issues/1205. - `armv7k-apple-watchos`, failed to link, see https://github.com/rust-lang/rust/issues/130071. - `arm64e-apple-ios`, failed to link, see https://github.com/rust-lang/rust/issues/130085. - `i686-apple-darwin`, requires a bit of setup and an older machine, see [the docs](https://doc.rust-lang.org/nightly/rustc/platform-support/i686-apple-darwin.html). - `i386-apple-ios` requires you to set `IPHONEOS_DEPLOYMENT_TARGET=10.0` for the test helpers to work, will be fixed by https://github.com/rust-lang/cc-rs/issues/1030. But all of this is as it was before this PR. Fixes https://github.com/rust-lang/rust/issues/47825, since we now have a test that compiles a `dylib` for `aarch64-apple-ios`. Split out from https://github.com/rust-lang/rust/pull/129342, see that for a little bit of the review that this has gone through already. r? petrochenkov ```@rustbot``` label O-apple
2024-09-09Rollup merge of #130048 - nebulark:runmake_llvm_pdbutil, r=jieyouxuJubilee-0/+24
run-make-support: Add llvm-pdbutil Add llvm-pdbutil to run-make-support, so we can write better unit tests for PDB specific features. r? ````@jieyouxu```` ````@rustbot```` label: +O-windows
2024-09-09Rollup merge of #130034 - alexcrichton:fix-some-wasm-component-ld-comments, ↵Jubilee-44/+19
r=onur-ozkan Fix enabling wasm-component-ld to match other tools It was [pointed out recently][comment] that enabling `wasm-component-ld` as a host tool is different from other host tools. This commit refactors the logic to match by deduplicating selection of when to build other tools and then using the same logic for `wasm-component-ld`. While here I also fixed a typo pointed out in https://github.com/rust-lang/rust/pull/126967#pullrequestreview-2285267534 [comment]: https://github.com/rust-lang/rust/pull/127866#issuecomment-2333434720
2024-09-09Rollup merge of #128667 - its-the-shrimp:rustdoc_json_types_rename, ↵Jubilee-130/+137
r=aDotInTheVoid rustdoc: normalise type/field names Updates #100961 - `Import` -> `Use`, to better reflect the terminology of Rust & its syntax - `TypeBinding` -> `AssocItemConstraint`, to sync up with `clean` - `FnDecl` -> `FunctionSignature`, because that's what it is - `Header` -> `FunctionHeader`, because `Header` is a very word that's very heavily loaded with different meanings - `ItemEnum::AssocType`: `default` -> `type`, because those items appear in `impl` blocks as well, where they're _not_ the "default" - `ItemEnum::AssocConst`: `default` -> `value`, see the previous point - `ForeignType` -> `ExternType`, because "foreign" is not the right word there - boolean fields' names made to consistently be a phrase that can be a yes/no answer, e.g. `async` -> `is_async` The docs of `ItemEnum::AssocType::type_` & of `ItemEnum::AssocConst::value` are also updated to be up to date with the clarification of the name of the fields
2024-09-09Rollup merge of #128345 - sthibaul:hurd-amd64, r=UrgauJubilee-3/+5
added support for GNU/Hurd on x86_64
2024-09-09Rollup merge of #119229 - mati865:update-mingw-toolchain, ↵Jubilee-2/+2
r=jieyouxu,petrochenkov Update mingw-w64 + GNU toolchain The list of packaged tools and their versions is available at: https://github.com/niXman/mingw-builds-binaries/releases/tag/14.1.0-rt_v12-rev0 Fixes: https://github.com/rust-lang/rust/issues/112368
2024-09-09Print a helpful message if any tests were skipped for being up-to-dateZalathar-0/+16
2024-09-09Add an explicit ignore message for "up-to-date" testsZalathar-2/+5
When running tests without the `--force-rerun` flag, compiletest will automatically skip any tests that (in its judgement) don't need to be run again since the last time they were run. This patch adds an explicit reason to those skipped tests, which is visible when running with `rust.verbose-tests = true` in `config.toml`.