Skip to content

Commit babba4a

Browse files
committed
Remove example of manually setting RUSTFLAGS
1 parent 8488795 commit babba4a

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

src/doc/src/guide/build-performance.md

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -71,16 +71,9 @@ Trade-offs:
7171

7272
### Enable the experimental parallel frontend
7373

74-
Recommendation: Add `-Zthreads=n` to the `RUSTFLAGS` environment variable, for example:
75-
76-
```console
77-
$ RUSTFLAGS="-Zthreads=8" cargo +nightly build
78-
```
79-
80-
You can configure `RUSTFLAGS` using [Cargo config](../reference/config.md#buildrustflags), so that you do not have to pass the flag on every cargo invocation manually:
74+
Recommendation: Add `-Zthreads=n` to the `RUSTFLAGS` environment variable, for example by adding the following to `.cargo/config.toml`:
8175

8276
```toml
83-
# .cargo/config.toml
8477
[build]
8578
rustflags = "-Zthreads=8"
8679
```
@@ -93,3 +86,4 @@ Trade-offs:
9386

9487
[parallel-frontend-blog]: https://blog.rust-lang.org/2023/11/09/parallel-rustc/
9588
[parallel-frontend-issue]: https://github.com/rust-lang/rust/issues/113349
89+

0 commit comments

Comments
 (0)