Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
benchmarks/gc_latency: add new microbenchmark for tricky mutator late…
…ncy issues When run with -bench, emits latency measurements in benchmark format. Includes -trace option for debugging latency issues (omit -bench for location of worst delay). go run . -help Usage of /<yuck>/gc_latency: -bench output in Go benchmark format -fluff insert 'fluff' into allocation runs to break up sweeps -how string how the buffer is allocated = {stack,heap,global} (default "stack") -trace string name of trace file to create -OR- runs as a go benchmark: go test -bench=B -count=10 . -- -fluff -how=stack goos: darwin goarch: amd64 pkg: golang.org/x/benchmarks/gc_latency cpu: Intel(R) Core(TM) i5-1038NG7 CPU @ 2.00GHz BenchmarkGCLatency-8 1 3722432744 ns/op 560.0 avg-ns 400.0 median-ns 1461 p29-ns 25774 p39-ns 38630 p49-ns 110696 p59-ns 4753393 p69-ns 5538766 worst-ns BenchmarkGCLatency-8 1 4067024228 ns/op 622.0 avg-ns 407.0 median-ns 1648 p29-ns 29543 p39-ns 49744 p49-ns 122664 p59-ns 6239471 p69-ns 6593770 worst-ns BenchmarkGCLatency-8 1 5113548640 ns/op 670.0 avg-ns 410.0 median-ns 2028 p29-ns 28188 p39-ns 66678 p49-ns 1448743 p59-ns 7695377 p69-ns 12281974 worst-ns BenchmarkGCLatency-8 1 3975527414 ns/op 606.0 avg-ns 406.0 median-ns 1578 p29-ns 28443 p39-ns 43476 p49-ns 113114 p59-ns 6413033 p69-ns 7211445 worst-ns BenchmarkGCLatency-8 1 4174308310 ns/op 633.0 avg-ns 409.0 median-ns 1720 p29-ns 29063 p39-ns 54298 p49-ns 373535 p59-ns 6489633 p69-ns 8041030 worst-ns BenchmarkGCLatency-8 1 3980984757 ns/op 609.0 avg-ns 406.0 median-ns 1555 p29-ns 28855 p39-ns 45865 p49-ns 120082 p59-ns 6046351 p69-ns 6346751 worst-ns BenchmarkGCLatency-8 1 4138732421 ns/op 601.0 avg-ns 410.0 median-ns 1550 p29-ns 27874 p39-ns 40879 p49-ns 155143 p59-ns 5705793 p69-ns 8028793 worst-ns BenchmarkGCLatency-8 1 5552645990 ns/op 849.0 avg-ns 411.0 median-ns 1962 p29-ns 29602 p39-ns 185457 p49-ns 6228738 p59-ns 19579494 p69-ns 43328862 worst-ns BenchmarkGCLatency-8 1 4339053770 ns/op 637.0 avg-ns 405.0 median-ns 1674 p29-ns 27410 p39-ns 50768 p49-ns 505246 p59-ns 6891708 p69-ns 88489177 worst-ns BenchmarkGCLatency-8 1 4715056872 ns/op 719.0 avg-ns 410.0 median-ns 1827 p29-ns 28776 p39-ns 70652 p49-ns 3236747 p59-ns 14152105 p69-ns 20386545 worst-ns PASS ok golang.org/x/benchmarks/gc_latency 52.349s as a fake main package benchmark: go run . -bench goos: darwin goarch: amd64 BenchmarkAverageLatency 1 574ns BenchmarkMedianLatency 1 412ns Benchmark99Latency 1 1791ns Benchmark999Latency 1 25843ns Benchmark9999Latency 1 35585ns Benchmark99999Latency 1 109314ns BenchmarkWorstLatency 1 6169500ns Updates golang/go#27732. Change-Id: I19b9060f24cda1547b8d75f762316dd5271e32c6
- Loading branch information