Expand description
Native parallel module for data-parallel operations.
Exports: parallel.map, parallel.filter, parallel.for_each, parallel.chunks, parallel.reduce, parallel.num_threads
Uses Rayon for thread-pool based data parallelism.
The key constraint is that Shape closures (ValueWord) are not Send,
so we use invoke_callable on the main thread but process pure-data
operations (chunking, collecting) in parallel where possible.
For parallel.map and parallel.filter, the callback is invoked via
invoke_callable on the calling thread, but the data is partitioned
and reassembled using Rayon when no callback is involved.
Functionsยง
- create_
parallel_ module - Create the
parallelmodule.