In the "Installing Rust" section, you write:
Once loaded, you should be able to use cargo
as usual.
But the previous section and your post here suggest that this is meant significantly for an audience who doesn't know what “usual” is — so it might be worth adding a hyperlink to Hello, Cargo! so that people in that position can get onto the usual introductory path.
Note that the module does not let you change the Rust version and channel via rustup
. You can switch channels (i.e., from stable
to nightly
) using a rust-toolchain.toml
file in your project or explicitly adding +nightly
to your cargo
calls.
As someone who does know how Rust tooling works, this is an almost self-contradictory claim because rust-toolchain.toml
and +nightly
are rustup
features. Perhaps you mean “… change the Rust version and channel via rustup override
”? Specifying that would help users know exactly what to expect.
… (i.e. using the target-cpu=native
build flag) …
… (i.e., data races are a compile-time bug in Rust) …
These should be “e.g.” instead of “i.e.”.
CPU Parallelism … In particular, we recommend that you take a look at the rayon
and crossbeam
libraries.
I think it may be also worth mentioning that you can achieve a lot of parallelism using solely std
tools. std::thread::scope
can be used if you already know how to break your problem into threads and don’t need rayon
’s more powerful and DWIM features, and std::sync::mpsc
is a fine choice of channel if you don’t need the additional features of crossbeam
.
(rayon
can be a good introduction to Rust parallelism because it's so easy to use — but it has subtleties, like how you can accidentally deadlock by blocking in a Rayon task, and quite a large API surface with lots of traits.)
The Rust compiler has support for SIMD instructions, both architecture-specific (on stable
) and portable (currently restricted to nightly
).
The “architecture-specific” link is many versions old.
I think it would also be worth mentioning that the Rust compiler is capable of autovectorization, so it is not necessary to use explicit SIMD for simple cases.
See the Rust Cookbook and Blessed, …
The name of this site is “Blessed.rs”, not “Blessed”.
This may be more of a pet peeve than good advice, but if I were writing this page, I’d replace most occurrences of “crate” with “library”.
- Technically, all Rust libraries are crates but not all crates are libraries.
- Using already-known language may help people get oriented faster or be put off less by Rust’s strangenesses.
Much of the Rust community would probably disagree with me here, though.