mirror of https://github.com/prometheus/prometheus
More efficient Merge implementation. (#486)
Avoid a tree of merge objects, which can result in what I suspect is n^2 calls to Seek when using Without. With 100k metrics, and a regex of ^$ in BenchmarkHeadPostingForMatchers: Before: BenchmarkHeadPostingForMatchers-8 1 51633185216 ns/op 29745528 B/op 200357 allocs/op After: BenchmarkHeadPostingForMatchers-8 10 108924996 ns/op 25715025 B/op 101748 allocs/op Signed-off-by: Brian Brazil <brian.brazil@robustperception.io>pull/5805/head
parent
b2d7bbd6b1
commit
296f943ec4
Loading…
Reference in new issue