composewell / streamly

High performance, concurrent functional programming abstractions
https://streamly.composewell.com
Other
859 stars 65 forks source link

Add microbenchmarks for all ops #31

Open harendra-kumar opened 6 years ago

harendra-kumar commented 6 years ago

We can either copy the benchmarking framework from the streaming-benchmarks package or just use that package to add more benchmarks that cover all the operations. Sometimes we do not realize that a small stupid mistake brings performance down by multifold. If we measure everything we can catch it immediately. Once we have the benchmarking streamlined, adding a new op to the benchmark should just be mechanical and a few lines change.

harendra-kumar commented 6 years ago

The framework has been added via a445ef9873056025af871e11cd6c5e1a9da2b07d and several subsequent commits. But we need to add more ops so that we are measuring all ops.

harendra-kumar commented 5 years ago

We have most of the benchmarks, we just need to add the missing ones. At the same time we should also consider putting the benchmarks in modules named after and corresponding to the exposed library modules and arranging the benchmarks in the same order so that users can find corresponding benchmarks easily. We should also publish the results of the benchmarks (time and space) in a results file in the docs directory.

harendra-kumar commented 2 years ago

We can use the same mechanism as listed in #159 to detect unbenchmarked functions. We can run the benchmarks via coverage and then check the coverage data to find functions that are never executed.