Rayon: Data Parallelism for Fun and Profit
summary
Library lets Rust code go parallel by a one-line change and a Prelude import: change iter to par_iter. Implementation uses a work-stealing thread pool and a fork-join primitive called join; parallel iterators split work, use par_iter_mut for disjoint mutation, and require reduce (not fold) for associative combines. Rust’s ownership model prevents undefined data races but shared counters need atomics or mutexes. Materials at speakerdeck link accompany the talk.
AI-written summary · about
chapters (9)
- 0:00Start
- 0:46Data Parallelism
- 3:01Data Race
- 4:37Structure of Rayon
- 5:14Parallel Iterators
- 6:43Shared State
- 10:11Atomic Types
- 11:14Sequentially Consistent Ordering
- 18:26Divide and Conquer
related talks
59mParallel Programming in Rust: Techniques for Blazing Speed
20mThe status of parallel rustc
53mRust: Reach Further!
27mParadigms of Rust for the Go Developer
02h 02mCloud Native Rust Workshop: Let's go parallel with Rust
16mEmpowering Fearless Data Engineering
19mPure Borrow: Linear Haskell Meets Rust-Style Borrowing
40mRust’s approach of getting things right
