I am working on a small research project at the university, about parallelizing L-system generation.
The 'fun' part of this will of course be to implement a couple of algorithms to do this in Rust.
And then these should be compared to each-other by benchmarking.
So far I've seen the wonderful library Criterion which seems to have many of the bells and whistles that I require.
There is only one thing that I have not yet figured out:
I want to also test an algorithm implementation against 'itself' with slightly altered constants. For instance, for 'small' collections I want to perform work on a single thread, whereas when a collection is larger than a threshold size, work should be split across multiple threads.
But how big should this threshold be? 128 elements? 1024 elements? smaller? bigger? That's one of the things I want to figure out by benchmarking.
However, how to set this up? I know Criterion treats the code used in the benchmarks as separate crates, but is there a way to compile my crate multiple times with different compile-time settings (like above 'threshold')?
Or is there another approach that I should use instead of Criterion for this?