Open vlovich opened 10 months ago
I haven't had time to think much about custom counters (planned), so I'm curious how you think Ratio
should be displayed?
I know how Bencher::output_counter
could be implemented, so that could be done relatively soon. Currently I'm prioritizing #18, async
, and runtime arguments (as opposed to consts
).
An example of displaying it would be something like
56.14 ms
1.781 Mitem/s
0.86 Hit performance
I have no strong feelings on the matter though.
I'm happy to help put up a PR if you'd like any help (& if you have a specific way you want it implemented just let me know).
I was benchmarking a cache library and would like to have the output contain a result of the cache hit rate so that I can understand the benchmark performance across multiple dimensions. I'm thinking something like:
It's a little bit complicated since hits & misses borrowing is not going to work like that without unsafe / RefCell / atomics. An alternative approach could be for
.bench
to return something:This is all a bit hand-wavy as I don't have the exact details in mind about the API (open to suggestions), but curious if there's any interest in me adding something like this.