From affe2c4376a77aedbca077fd0ca0b3e898c8e214 Mon Sep 17 00:00:00 2001 From: Robert Serrano Kobylyansky Date: Mon, 4 Aug 2025 13:08:29 +0100 Subject: [PATCH 1/5] Update installation.md The `--enable-offload` and `--enable--enzyme` arguments don't seem to work. Changing them to `--enable-llvm-offload` and `--enable-llvm-enzyme` resulted in the `boostrap.toml` file generating succesfully. --- src/doc/rustc-dev-guide/src/offload/installation.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/doc/rustc-dev-guide/src/offload/installation.md b/src/doc/rustc-dev-guide/src/offload/installation.md index 1e792de3c8cea..b376e962ff634 100644 --- a/src/doc/rustc-dev-guide/src/offload/installation.md +++ b/src/doc/rustc-dev-guide/src/offload/installation.md @@ -8,7 +8,7 @@ First you need to clone and configure the Rust repository: ```bash git clone git@github.com:rust-lang/rust cd rust -./configure --enable-llvm-link-shared --release-channel=nightly --enable-llvm-assertions --enable-offload --enable-enzyme --enable-clang --enable-lld --enable-option-checking --enable-ninja --disable-docs +./configure --enable-llvm-link-shared --release-channel=nightly --enable-llvm-assertions --enable-llvm-offload --enable-llvm-enzyme --enable-clang --enable-lld --enable-option-checking --enable-ninja --disable-docs ``` Afterwards you can build rustc using: From c3ee4033229ce7e594263c763ac94bf00709ff3e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jana=20D=C3=B6nszelmann?= Date: Wed, 6 Aug 2025 13:57:12 +0200 Subject: [PATCH 2/5] add note on how to build wasi --- src/doc/rustc-dev-guide/src/tests/running.md | 23 +++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/src/doc/rustc-dev-guide/src/tests/running.md b/src/doc/rustc-dev-guide/src/tests/running.md index f6e313062cda8..317b65f98cd3c 100644 --- a/src/doc/rustc-dev-guide/src/tests/running.md +++ b/src/doc/rustc-dev-guide/src/tests/running.md @@ -342,7 +342,6 @@ coordinate running tests (see [src/bootstrap/src/core/build_steps/test.rs]). > **TODO** > > - Is there any support for using an iOS emulator? -> - It's also unclear to me how the wasm or asm.js tests are run. [armhf-gnu]: https://github.com/rust-lang/rust/tree/master/src/ci/docker/host-x86_64/armhf-gnu/Dockerfile [QEMU]: https://www.qemu.org/ @@ -350,6 +349,28 @@ coordinate running tests (see [src/bootstrap/src/core/build_steps/test.rs]). [remote-test-server]: https://github.com/rust-lang/rust/tree/master/src/tools/remote-test-server [src/bootstrap/src/core/build_steps/test.rs]: https://github.com/rust-lang/rust/blob/master/src/bootstrap/src/core/build_steps/test.rs +## Testing tests on wasi (wasm32-wasip1) + +Some tests are specific to wasm targets. +To run theste tests, you have to pass `--target wasm32-wasip1` to `x test`. +Additionally, you need the wasi sdk. +Follow the install instructions from the [wasi sdk repository] to get a sysroot on your computer. +On the [wasm32-wasip1 target support page] a minimum version is specified that your sdk must be able to build. +Some cmake commands that take a while and give a lot of very concerning c++ warnings... +Then, in `bootstrap.toml`, point to the sysroot like so: + +``` +[target.wasm32-wasip1] +wasi-root = "/build/sysroot/install/share/wasi-sysroot" +``` + +In my case I git-cloned it next to my rust folder, so it was `../wasi-sdk/build/....` +Now, tests should just run, you don't have to set up anything else. + +[wasi sdk repository]: https://github.com/WebAssembly/wasi-sdk +[wasm32-wasip1 target support page]: https://github.com/rust-lang/rust/blob/master/src/doc/rustc/src/platform-support/wasm32-wasip1.md#building-the-target. + + ## Running rustc_codegen_gcc tests First thing to know is that it only supports linux x86_64 at the moment. We will From ef3708bf63d2f8b37cb2a2c1a498531d04bd9761 Mon Sep 17 00:00:00 2001 From: lolbinarycat Date: Wed, 6 Aug 2025 13:31:52 -0500 Subject: [PATCH 3/5] =?UTF-8?q?Link=20from=20"Overview=20of=20the=20compil?= =?UTF-8?q?er=20=C2=A7=20Queries"=20to=20the=20Queries=20chapter?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit There's already a link in the other direction, so this seems fairly logical. --- src/doc/rustc-dev-guide/src/overview.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/doc/rustc-dev-guide/src/overview.md b/src/doc/rustc-dev-guide/src/overview.md index 12b76828b5c3b..02ba676139366 100644 --- a/src/doc/rustc-dev-guide/src/overview.md +++ b/src/doc/rustc-dev-guide/src/overview.md @@ -321,6 +321,10 @@ the name `'tcx`, which means that something is tied to the lifetime of the [`TyCtxt`]: https://doc.rust-lang.org/nightly/nightly-rustc/rustc_middle/ty/struct.TyCtxt.html +For more information about queries in the compiler, see [the queries chapter][queries]. + +[queries]: https://rustc-dev-guide.rust-lang.org/query.html + ### `ty::Ty` Types are really important in Rust, and they form the core of a lot of compiler From 162b908eb6f0988ecbd3b3b9f01d364c44722860 Mon Sep 17 00:00:00 2001 From: lolbinarycat Date: Wed, 6 Aug 2025 15:01:41 -0500 Subject: [PATCH 4/5] Make link relative an link to md not html --- src/doc/rustc-dev-guide/src/overview.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/doc/rustc-dev-guide/src/overview.md b/src/doc/rustc-dev-guide/src/overview.md index 02ba676139366..378d8c4453f89 100644 --- a/src/doc/rustc-dev-guide/src/overview.md +++ b/src/doc/rustc-dev-guide/src/overview.md @@ -323,7 +323,7 @@ the name `'tcx`, which means that something is tied to the lifetime of the For more information about queries in the compiler, see [the queries chapter][queries]. -[queries]: https://rustc-dev-guide.rust-lang.org/query.html +[queries]: ./query.md ### `ty::Ty` From 4f96b2aa5e333fc1cad8b5987bfc2d18821d6d4d Mon Sep 17 00:00:00 2001 From: The rustc-josh-sync Cronjob Bot Date: Thu, 7 Aug 2025 04:18:12 +0000 Subject: [PATCH 5/5] Prepare for merging from rust-lang/rust This updates the rust-version file to 6bcdcc73bd11568fd85f5a38b58e1eda054ad1cd. --- src/doc/rustc-dev-guide/rust-version | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/doc/rustc-dev-guide/rust-version b/src/doc/rustc-dev-guide/rust-version index e9f1626f1fdd4..6ec700b9b4dc1 100644 --- a/src/doc/rustc-dev-guide/rust-version +++ b/src/doc/rustc-dev-guide/rust-version @@ -1 +1 @@ -383b9c447b61641e1f1a3850253944a897a60827 +6bcdcc73bd11568fd85f5a38b58e1eda054ad1cd