Sort vs. Hash Revisited: Fast Join Implementation on Modern Multi-Core CPUs

被引:158
|
作者
Kim, Changkyu [1 ]
Sedlar, Eric [2 ]
Chhugani, Jatin [1 ]
Kaldewey, Tim [2 ]
Nguyen, Anthony D. [1 ]
Di Bias, Andrea [2 ]
Lee, Victor W. [1 ]
Satish, Nadathur [1 ]
Dubey, Pradeep [1 ]
机构
[1] Intel Corp, Throughput Comp Lab, Santa Clara, CA 95054 USA
[2] Oracle Corp, Special Projects Grp, Redwood Shores, CA 94065 USA
来源
PROCEEDINGS OF THE VLDB ENDOWMENT | 2009年 / 2卷 / 02期
关键词
D O I
10.14778/1687553.1687564
中图分类号
TP [自动化技术、计算机技术];
学科分类号
0812 ;
摘要
Join is an important database operation. As computer architectures evolve, the best join algorithm may change hand. This paper reexamines two popular join algorithms - hash join and sort-merge join - to determine if the latest computer architecture trends shift the tide that has favored hash join for many years. For a fair comparison, we implemented the most optimized parallel version of both algorithms on the latest Intel Core i7 platform. Both implementations scale well with the number of cores in the system and take advantages of latest processor features for performance. Our hash-based implementation achieves more than 100M tuples per second which is 17X faster than the best reported performance on CPUs and 8X faster than that reported for GPUs. Moreover, the performance of our hash join implementation is consistent over a wide range of input data sizes from 64K to 128M tuples and is not affected by data skew. We compare this implementation to our highly optimized sort-based implementation that achieves 47M to 80M tuples per second. We developed analytical models to study how both algorithms would scale with upcoming processor architecture trends. Our analysis projects that current architectural trends of wider SIMD, more cores, and smaller memory bandwidth per core imply better scalability potential for sort-merge join. Consequently, sort- merge join is likely to outperform hash join on upcoming chip multiprocessors. In summary, we offer multicoreimplementations of hash join and sort-merge join which consistently outperform all previously reported results. We further conclude that the tide that favors the hash join algorithm has not changed yet, but the change is just around the comer.
引用
收藏
页码:1378 / 1389
页数:12
相关论文
共 32 条
  • [31] An Efficient Implementation of Fast Direct Method of Moments for Half-Space Green's Function on Multi-Core Platform
    Wang, Shumin
    Shao, Yu
    Shang, Shuo
    ELECTROMAGNETICS, 2015, 35 (01) : 1 - 9
  • [32] Tuning sizes, morphologies, and magnetic properties of mono- vs. multi-core iron oxide nanoparticles through controlled addition of water in the polyol synthesis
    Hemery, Gauvin
    Keyes, Anthony
    Garayo, Eneko
    Rodrigo, Irati
    Angel Garcia, Jose
    Plazaola, Fernando
    Garanger, Elisabeth
    Sandre, Olivier
    ABSTRACTS OF PAPERS OF THE AMERICAN CHEMICAL SOCIETY, 2017, 254