-
Notifications
You must be signed in to change notification settings - Fork 18.8k
Description
I would like to report the results of non-standard benchmark (non google/benchmark style) along side existing benchmarks, and do so following the proposed Go benchmark data format. For example, the pbench package reports percentiles in addition to the standard results.
I was unable to implement this benchmark without using reflection to access some unexported fields, and there was no mechanism for using the same io.Writer for the output. A preferable solution would be a new method on B that, provided a name & benchmark-result argument, formats and writes the results in the standard format.
Additionally, adding a ReportAllocs field to BenchmarkResults would be useful for when a benchmark is run with -benchmem but a non-standard benchmark does not support malloc statistics.