Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix the issue where the first measurement in a microbenchmark is
slightly slower, which is especially noticeable with quick benchmarks. See the measurements (column A) from the TrivialKotlinBenchmark#nothing microbenchmark from 100 runs before and after this change in https://docs.google.com/spreadsheets/d/1W6oxK_rM0KGzZBLxpax05766-hYyV2EYLw49dIs2uPo/edit?usp=sharing&resourcekey=0-3rhUgg9eSBekHXF8mOznng. At head, every first measurement of a run (rows 1, 51, 101, 151, etc) are in the range of ~5.5-6ns, while the median is 3.6ns. With this change (the benchmark-first-measurement tab), this issue disappears. The standard deviation at head is 0.42, while with this change it reduces to 0.19. Test: Existing tests. Change-Id: Id6f1dac88d19665e9fa80d8e60144f38089f4cc2
- Loading branch information