GopherCon 2023: Bryan Boreham - Blazing Fast Merge with Loser Trees

Published: 24 March 2024
on channel: Gopher Academy
1,386
48

Both sorting and merging efficiently can be hard problems. Merging ordered sequences is a little bit easier, but still hard. Thankfully many hard problems in computer science have been well-studied. A good strategy for k-way merging is called Tournament Tree, or Loser Tree. Go didn’t have an implementation of that, so I made one.

In this talk, we will look at:

Fundamentals and problems of k-way merges
Why Loser Tree is a good theoretical solution
How Go generics enable an efficient implementation
How profiling and benchmarks were used to tune the implementation and interface
How to apply this in practice, exemplified through Prometheus, Pyroscope, and Grafana Loki

Attendees of this talk will gain awareness of a new Open-Source package they could use and insight into the design of an interface using generics.


Watch video GopherCon 2023: Bryan Boreham - Blazing Fast Merge with Loser Trees online without registration, duration hours minute second in high quality. This video was added by user Gopher Academy 24 March 2024, don't forget to share it with your friends and acquaintances, it has been viewed on our site 1,386 once and liked it 48 people.