Hacker News

Vectorized and performance-portable Quicksort

Screen20Shot202022-06-0120at201.08.5320PM

Thursday, June 2, 2022 Today we’re sharing open source code that can sort arrays of numbers about ten times as fast as the C++ std::sort, and outperforms state of the art architecture-specific algorithms, while being portable across all modern CPU architectures. Below we discuss how we achieved this.First, some background. There is a recent trend towards columnar databases that consecutively store all values from a particular column, as opposed to storing all fields of a record or “row” before those of the next record. This can be faster to filter or sort, which are key building blocks for SQL queries; thus we focus on this data layout.Given that sorting has been heavily studied, how can we possibly find a 10x speedup? The…

Continue reading at Hacker News opensource.googleblog.com
Advertisement