Rayon looks great for algorithm parallelization of collections, and Faster is great for vectorization (SIMD) on the x86 platform for collections like Vec<f32>
. I've tried to combine them and the iterators don't seem to like each other. Is there a way to make use of these two libraries for algorithms which would benefit from both vectorization and parallelization? Like this one from the Faster example:
let lots_of_3s = (&[-123.456f32; 128][..]).iter()
.map(|v| {
9.0 * v.abs().sqrt().sqrt().recip().ceil().sqrt() - 4.0 - 2.0
})
.collect::<Vec<f32>>();