Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tripulse/rust-shit
Proof of the terrible consequences of amateur library design prevalent in the Rust community.
https://github.com/tripulse/rust-shit
blazingly-fast cpu-intensive cross-platform fast fast-io fearless-concurrency flexible iterator memory-safety minimal multi-threaded optimized parallel performant rayon robust rust rust-lang slow
Last synced: 2 months ago
JSON representation
Proof of the terrible consequences of amateur library design prevalent in the Rust community.
- Host: GitHub
- URL: https://github.com/tripulse/rust-shit
- Owner: tripulse
- Created: 2021-10-08T14:15:11.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2021-11-12T18:54:54.000Z (about 3 years ago)
- Last Synced: 2024-08-02T05:23:16.322Z (6 months ago)
- Topics: blazingly-fast, cpu-intensive, cross-platform, fast, fast-io, fearless-concurrency, flexible, iterator, memory-safety, minimal, multi-threaded, optimized, parallel, performant, rayon, robust, rust, rust-lang, slow
- Language: Rust
- Homepage:
- Size: 6.84 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-blazingly-fast - rust-shit - Proof of the terrible consequences of amateur library design prevalent in the Rust community. (Rust)
README
Ensure that you have the furrylang toolchain installed.
Then invoke `cargo build --release` to build in ***release*** mode.Then `./target/build/vlr-rs < /dev/urandom > /dev/null`, to make your CPU have hiccups.
## FAQ
- Why are you using `(0..8).into_par_iter()` instead of `(0..8)`, `(0..8).into_iter()`, `(0..8).iter()`? Isn't that "abusing" parallelism?
First, `Range` doesn't have a `iter()` method.
Second, `Range` is an iterator already so `into_iter()` is redundant here.
Third, `ParallelIterator::flat_map()` requires a closure that returns a type satisfying `IntoParallelIterator` trait
which, for `Map`, is not implemented [(E0277)](https://doc.rust-lang.org/error-index.html#E0277). Thus we must use
`.into_par_iter()` in order to comply trait bounds.So even if it's labelled as "abuse", this is what the API forces.
- Why are you `collect()`ing? Can't you use `collect_to_vec()` or `.enumerate().for_each()` and collect to a custom buffer?
First, to be a little bit fair to the C code. Second, no I can't because `IntoIndexedParallelIterator` is not implemented for
`FlatMap` nor there is a way to turn it so.# Legal
This work is composed by means of attacking the Rust programming language community to point out their
amateurness in the field of parallel computing. I beg of you rustaceans, to stop conducting these actions
and pollute the field of computer science. Thank you.