Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sticky: vendor go-rbtree, drop external dep
The go-rbtree dep was only used for the sticky package, and we used ~half the code: we used none of the powerful iteration, which was created and used only in an early version of this code. Dropping this has potentially very minor speedups and theoretically a few less allocations. As expected, this doesn't really show in any benchmarks: name old time/op new time/op delta Large-12 3.86ms ±16% 3.89ms ±18% ~ (p=0.971 n=10+10) LargeWithExisting-12 8.96ms ± 5% 8.56ms ± 6% -4.46% (p=0.023 n=10+10) LargeImbalanced-12 4.64ms ±14% 4.58ms ±11% ~ (p=0.481 n=10+10) LargeWithExistingImbalanced-12 8.78ms ±10% 8.74ms ±10% ~ (p=0.796 n=10+10) Java/large-12 178ms ± 1% 177ms ± 1% -0.66% (p=0.023 n=10+10) Java/large_imbalance-12 215ms ± 4% 215ms ± 4% ~ (p=0.739 n=10+10) Java/medium-12 10.5ms ± 5% 11.3ms ±22% ~ (p=0.315 n=8+10) Java/medium_imbalance-12 13.3ms ± 9% 13.4ms ± 8% ~ (p=0.730 n=9+9) Java/small-12 8.45ms ± 5% 8.98ms ±22% ~ (p=0.573 n=8+10) Java/small_imbalance-12 10.9ms ± 9% 10.5ms ±11% ~ (p=0.113 n=9+10) name old alloc/op new alloc/op delta Large-12 1.87MB ± 0% 1.87MB ± 0% ~ (p=0.352 n=9+9) LargeWithExisting-12 1.97MB ± 0% 1.97MB ± 0% ~ (p=0.971 n=10+10) LargeImbalanced-12 2.07MB ± 1% 2.07MB ± 1% ~ (p=0.853 n=10+10) LargeWithExistingImbalanced-12 2.01MB ± 0% 2.01MB ± 0% ~ (p=0.063 n=10+10) Java/large-12 125MB ± 0% 125MB ± 0% ~ (p=0.306 n=10+9) Java/large_imbalance-12 129MB ± 0% 129MB ± 0% ~ (p=0.398 n=9+9) Java/medium-12 7.69MB ± 0% 7.69MB ± 0% ~ (p=0.985 n=10+10) Java/medium_imbalance-12 7.97MB ± 0% 7.97MB ± 0% -0.00% (p=0.000 n=10+9) Java/small-12 6.11MB ± 0% 6.11MB ± 0% ~ (p=0.095 n=10+9) Java/small_imbalance-12 6.34MB ± 0% 6.34MB ± 0% ~ (p=0.739 n=10+10) name old allocs/op new allocs/op delta Large-12 335 ± 0% 335 ± 0% ~ (all equal) LargeWithExisting-12 9.35k ± 1% 9.33k ± 1% ~ (p=0.100 n=10+10) LargeImbalanced-12 787 ± 3% 794 ± 2% ~ (p=0.193 n=8+8) LargeWithExistingImbalanced-12 9.30k ± 1% 9.29k ± 1% ~ (p=0.470 n=10+10) Java/large-12 6.04k ± 0% 6.04k ± 0% ~ (p=0.294 n=10+8) Java/large_imbalance-12 7.42k ± 0% 7.43k ± 0% ~ (p=0.201 n=9+9) Java/medium-12 3.03k ± 0% 3.03k ± 0% ~ (all equal) Java/medium_imbalance-12 3.15k ± 0% 3.14k ± 0% -0.11% (p=0.002 n=10+10) Java/small-12 2.46k ± 0% 2.46k ± 0% ~ (all equal) Java/small_imbalance-12 2.55k ± 1% 2.55k ± 1% ~ (p=0.670 n=10+10)
- Loading branch information