abstract
- Core operations in database systems are based on sorting, e.g., creating a new b-tree index, merge joins, or grouped aggregations. The required comparisons can be costly due to many or large columns. In order to reuse previous comparison effort, it can be encoded in form of offset-value codes. While hash values can guarantee that two keys are not equal, offset-value codes can also guarantee equality of key and indicate their sort order, making them usable in sorting algorithms. Modern CPUs provide specialized functional units that enable data parallel execution within a single core. In this paper, we report on our initial experiences and measurements for comparisons using SIMD instructions. Our techniques are portable to many architectures based on architecture-agnostic vector types and instructions. Our results demonstrate that hardware-accelerated sorting and merging are available on any CPU with SIMD instructions, i.e., practically any modern CPU.